Skip to content
Permalink
Browse files

cmake: add core/unix sources to the build.

Fixes Bugzilla #3757.
  • Loading branch information
icculus committed Aug 17, 2017
1 parent 00905c9 commit 47beda976792b7e5caef105ebf72e9467e9c04d1
Showing with 7 additions and 2 deletions.
  1. +7 −2 CMakeLists.txt
@@ -948,6 +948,11 @@ elseif(UNIX AND NOT APPLE AND NOT ANDROID)
CheckKMSDRM()
endif()

if(UNIX)
file(GLOB CORE_UNIX_SOURCES ${SDL2_SOURCE_DIR}/src/core/unix/*.c)
set(SOURCE_FILES ${SOURCE_FILES} ${CORE_UNIX_SOURCES})
endif()

if(LINUX)
check_c_source_compiles("
#include <linux/input.h>
@@ -967,8 +972,8 @@ elseif(UNIX AND NOT APPLE AND NOT ANDROID)
ioctl(0, KDGKBENT, &kbe);
}" HAVE_INPUT_KD)

file(GLOB CORE_SOURCES ${SDL2_SOURCE_DIR}/src/core/linux/*.c)
set(SOURCE_FILES ${SOURCE_FILES} ${CORE_SOURCES})
file(GLOB CORE_LINUX_SOURCES ${SDL2_SOURCE_DIR}/src/core/linux/*.c)
set(SOURCE_FILES ${SOURCE_FILES} ${CORE_LINUX_SOURCES})

if(HAVE_INPUT_EVENTS)
set(SDL_INPUT_LINUXEV 1)

0 comments on commit 47beda9

Please sign in to comment.