summaryrefslogtreecommitdiff
path: root/CMakeLists.txt
diff options
context:
space:
mode:
authorSam Lantinga <slouken@libsdl.org>2018-09-28 21:19:27 -0700
committerSam Lantinga <slouken@libsdl.org>2018-09-28 21:19:27 -0700
commitadeec3f1ca973e70f79de07895df7fd7fdf3f0de (patch)
tree78f718c7c6571ab77e4d3c590fa20187273cc3d7 /CMakeLists.txt
parentbfe46b22f88c2dbb15df2a35b73df55cda3158f1 (diff)
Mark a subsystem as dummy, not disabled, if it was intended to be compiled in.
From Tom Black: I'm having problems initializing the sensor module. I'm compiling with a standard ./configure && make && sudo make install, and the module says it's enabled, but SDL_Init(SDL_INIT_EVERYTHING) is failing with SDL_GetError() returning "SDL not built with sensor support".
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r--CMakeLists.txt14
1 files changed, 7 insertions, 7 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index c213bc455e..302ba2c9e3 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -1565,7 +1565,7 @@ endif()
# This leads to missing internal references on building, since the
# src/X/*.c does not get included.
if(NOT HAVE_SDL_JOYSTICK)
- set(SDL_JOYSTICK_DISABLED 1)
+ set(SDL_JOYSTICK_DUMMY 1)
if(SDL_JOYSTICK AND NOT APPLE) # results in unresolved symbols on OSX
file(GLOB JOYSTICK_SOURCES ${SDL2_SOURCE_DIR}/src/joystick/dummy/*.c)
@@ -1573,10 +1573,15 @@ if(NOT HAVE_SDL_JOYSTICK)
endif()
endif()
if(NOT HAVE_SDL_HAPTIC)
- set(SDL_HAPTIC_DISABLED 1)
+ set(SDL_HAPTIC_DUMMY 1)
file(GLOB HAPTIC_SOURCES ${SDL2_SOURCE_DIR}/src/haptic/dummy/*.c)
set(SOURCE_FILES ${SOURCE_FILES} ${HAPTIC_SOURCES})
endif()
+if(NOT HAVE_SDL_SENSORS)
+ set(SDL_SENSOR_DUMMY 1)
+ file(GLOB SENSORS_SOURCES ${SDL2_SOURCE_DIR}/src/sensor/dummy/*.c)
+ set(SOURCE_FILES ${SOURCE_FILES} ${SENSORS_SOURCES})
+endif()
if(NOT HAVE_SDL_LOADSO)
set(SDL_LOADSO_DISABLED 1)
file(GLOB LOADSO_SOURCES ${SDL2_SOURCE_DIR}/src/loadso/dummy/*.c)
@@ -1587,11 +1592,6 @@ if(NOT HAVE_SDL_FILESYSTEM)
file(GLOB FILESYSTEM_SOURCES ${SDL2_SOURCE_DIR}/src/filesystem/dummy/*.c)
set(SOURCE_FILES ${SOURCE_FILES} ${FILESYSTEM_SOURCES})
endif()
-if(NOT HAVE_SDL_SENSORS)
- set(SDL_SENSOR_DISABLED 1)
- file(GLOB SENSORS_SOURCES ${SDL2_SOURCE_DIR}/src/sensor/dummy/*.c)
- set(SOURCE_FILES ${SOURCE_FILES} ${SENSORS_SOURCES})
-endif()
# We always need to have threads and timers around
if(NOT HAVE_SDL_THREADS)