mirror of
https://github.com/geode-sdk/geode.git
synced 2025-04-13 05:24:33 -04:00
feat(ios): consistent iOS detection in cmake
Signed-off-by: rooot <hey@rooot.gay>
This commit is contained in:
parent
fbc3bae790
commit
f74d3d5b53
2 changed files with 4 additions and 4 deletions
|
@ -1,6 +1,6 @@
|
|||
if (NOT DEFINED GEODE_TARGET_PLATFORM)
|
||||
if(APPLE)
|
||||
if("${CMAKE_SYSTEM_NAME}" STREQUAL "iOS")
|
||||
if("${CMAKE_SYSTEM_NAME}" STREQUAL "iOS" OR IOS)
|
||||
set(GEODE_TARGET_PLATFORM "iOS")
|
||||
else()
|
||||
set(GEODE_TARGET_PLATFORM "MacOS")
|
||||
|
|
|
@ -88,7 +88,7 @@ file(GLOB SOURCES CONFIGURE_DEPENDS
|
|||
)
|
||||
|
||||
# Obj-c sources
|
||||
if (${CMAKE_SYSTEM_NAME} STREQUAL "iOS")
|
||||
if ("${CMAKE_SYSTEM_NAME}" STREQUAL "iOS" OR IOS)
|
||||
file(GLOB OBJC_SOURCES CONFIGURE_DEPENDS
|
||||
src/platform/ios/*.mm
|
||||
src/load.mm
|
||||
|
@ -118,7 +118,7 @@ if (WIN32)
|
|||
)
|
||||
list(APPEND SOURCES ${WIN_SOURCES})
|
||||
|
||||
elseif(${CMAKE_SYSTEM_NAME} STREQUAL "iOS")
|
||||
elseif("${CMAKE_SYSTEM_NAME}" STREQUAL "iOS" OR IOS)
|
||||
file(GLOB IOS_SOURCES CONFIGURE_DEPENDS
|
||||
src/platform/ios/*.cpp
|
||||
src/platform/mac/Cocos2d.cpp # identical on ios, so we just use the mac one
|
||||
|
@ -326,7 +326,7 @@ endif()
|
|||
# Create launcher
|
||||
if (APPLE)
|
||||
|
||||
if(GEODE_TARGET_PLATFORM STREQUAL "iOS")
|
||||
if("${CMAKE_SYSTEM_NAME}" STREQUAL "iOS" OR IOS)
|
||||
# Used for File Picker API
|
||||
find_library(UNIFORM_TYPE_IDENTIFIERS_FRAMEWORK UniformTypeIdentifiers)
|
||||
target_link_libraries(${PROJECT_NAME} ${UNIFORM_TYPE_IDENTIFIERS_FRAMEWORK})
|
||||
|
|
Loading…
Add table
Reference in a new issue