mirror of https://github.com/encounter/SDL.git
cmake: Weak link with CoreHaptics
Add link to CoreHaptics so we can compile against latest iOS SDKs.
This commit is contained in:
parent
dbedaeceb3
commit
401f485490
|
@ -1742,6 +1742,7 @@ elseif(APPLE)
|
||||||
set(SDL_FRAMEWORK_COREMOTION 1)
|
set(SDL_FRAMEWORK_COREMOTION 1)
|
||||||
endif()
|
endif()
|
||||||
set(SDL_FRAMEWORK_GAMECONTROLLER 1)
|
set(SDL_FRAMEWORK_GAMECONTROLLER 1)
|
||||||
|
set(SDL_FRAMEWORK_COREHAPTICS 1)
|
||||||
set(HAVE_SDL_SENSORS 1)
|
set(HAVE_SDL_SENSORS 1)
|
||||||
else()
|
else()
|
||||||
file(GLOB JOYSTICK_SOURCES ${SDL2_SOURCE_DIR}/src/joystick/darwin/*.c ${SDL2_SOURCE_DIR}/src/joystick/iphoneos/*.m)
|
file(GLOB JOYSTICK_SOURCES ${SDL2_SOURCE_DIR}/src/joystick/darwin/*.c ${SDL2_SOURCE_DIR}/src/joystick/iphoneos/*.m)
|
||||||
|
@ -1966,6 +1967,12 @@ elseif(APPLE)
|
||||||
find_library(UIKIT UIKit)
|
find_library(UIKIT UIKit)
|
||||||
list(APPEND EXTRA_LIBS ${UIKIT})
|
list(APPEND EXTRA_LIBS ${UIKIT})
|
||||||
endif()
|
endif()
|
||||||
|
if(SDL_FRAMEWORK_COREHAPTICS)
|
||||||
|
find_library(COREHAPTICS CoreHaptics)
|
||||||
|
if(COREHAPTICS)
|
||||||
|
list(APPEND EXTRA_LDFLAGS "-Wl,-weak_framework,CoreHaptics")
|
||||||
|
endif()
|
||||||
|
endif()
|
||||||
|
|
||||||
CheckPTHREAD()
|
CheckPTHREAD()
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue