mirror of
https://github.com/geode-sdk/geode.git
synced 2024-11-22 15:37:53 -05:00
fix platform-specific dependencies through Cli 3.2.0
This commit is contained in:
parent
65ed0d479f
commit
98f82ff00e
2 changed files with 15 additions and 1 deletions
|
@ -119,7 +119,16 @@ function(setup_geode_mod proname)
|
|||
endif()
|
||||
|
||||
# Check dependencies using CLI
|
||||
if (${GEODE_CLI_VERSION} VERSION_GREATER_EQUAL "2.0.0")
|
||||
if (${GEODE_CLI_VERSION} VERSION_GREATER_EQUAL "3.2.0")
|
||||
execute_process(
|
||||
COMMAND ${GEODE_CLI} project check ${CMAKE_CURRENT_BINARY_DIR}
|
||||
--externals ${GEODE_MODS_BEING_BUILT} ${DONT_UPDATE_INDEX_ARG}
|
||||
--platform ${GEODE_TARGET_PLATFORM_SHORT}
|
||||
WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}
|
||||
COMMAND_ERROR_IS_FATAL ANY
|
||||
)
|
||||
elseif (${GEODE_CLI_VERSION} VERSION_GREATER_EQUAL "2.0.0")
|
||||
message(WARNING "If you use platform-specific dependencies, upgrade Geode CLI to version 3.2.0 or greater!")
|
||||
execute_process(
|
||||
COMMAND ${GEODE_CLI} project check ${CMAKE_CURRENT_BINARY_DIR}
|
||||
--externals ${GEODE_MODS_BEING_BUILT} ${DONT_UPDATE_INDEX_ARG}
|
||||
|
|
|
@ -14,6 +14,7 @@ if (GEODE_TARGET_PLATFORM STREQUAL "iOS")
|
|||
set(GEODE_OUTPUT_NAME "Geode.ios")
|
||||
set(GEODE_PLATFORM_BINARY "Geode.ios.dylib")
|
||||
set(GEODE_MOD_BINARY_SUFFIX ".ios.dylib" CACHE STRING "" FORCE)
|
||||
set(GEODE_TARGET_PLATFORM_SHORT "ios" PARENT_SCOPE)
|
||||
elseif (GEODE_TARGET_PLATFORM STREQUAL "MacOS")
|
||||
set_target_properties(${PROJECT_NAME} PROPERTIES
|
||||
SYSTEM_NAME MacOS
|
||||
|
@ -49,6 +50,7 @@ elseif (GEODE_TARGET_PLATFORM STREQUAL "MacOS")
|
|||
set(GEODE_OUTPUT_NAME "Geode")
|
||||
set(GEODE_PLATFORM_BINARY "Geode.dylib")
|
||||
set(GEODE_MOD_BINARY_SUFFIX ".dylib" CACHE STRING "" FORCE)
|
||||
set(GEODE_TARGET_PLATFORM_SHORT "mac" PARENT_SCOPE)
|
||||
elseif (GEODE_TARGET_PLATFORM STREQUAL "Win64")
|
||||
set_target_properties(${PROJECT_NAME} PROPERTIES
|
||||
SYSTEM_NAME Win64
|
||||
|
@ -77,6 +79,7 @@ elseif (GEODE_TARGET_PLATFORM STREQUAL "Win64")
|
|||
set(GEODE_OUTPUT_NAME "Geode")
|
||||
set(GEODE_PLATFORM_BINARY "Geode.lib")
|
||||
set(GEODE_MOD_BINARY_SUFFIX ".dll" CACHE STRING "" FORCE)
|
||||
set(GEODE_TARGET_PLATFORM_SHORT "win" PARENT_SCOPE)
|
||||
elseif (GEODE_TARGET_PLATFORM STREQUAL "Android32")
|
||||
set_target_properties(${PROJECT_NAME} PROPERTIES
|
||||
SYSTEM_NAME Android
|
||||
|
@ -101,6 +104,7 @@ elseif (GEODE_TARGET_PLATFORM STREQUAL "Android32")
|
|||
set(GEODE_OUTPUT_NAME "Geode.android32")
|
||||
set(GEODE_PLATFORM_BINARY "Geode.android32.so")
|
||||
set(GEODE_MOD_BINARY_SUFFIX ".android32.so" CACHE STRING "" FORCE)
|
||||
set(GEODE_TARGET_PLATFORM_SHORT "android32" PARENT_SCOPE)
|
||||
elseif (GEODE_TARGET_PLATFORM STREQUAL "Android64")
|
||||
set_target_properties(${PROJECT_NAME} PROPERTIES
|
||||
SYSTEM_NAME Android
|
||||
|
@ -130,6 +134,7 @@ elseif (GEODE_TARGET_PLATFORM STREQUAL "Android64")
|
|||
set(GEODE_OUTPUT_NAME "Geode.android64")
|
||||
set(GEODE_PLATFORM_BINARY "Geode.android64.so")
|
||||
set(GEODE_MOD_BINARY_SUFFIX ".android64.so" CACHE STRING "" FORCE)
|
||||
set(GEODE_TARGET_PLATFORM_SHORT "android64" PARENT_SCOPE)
|
||||
else()
|
||||
message(FATAL_ERROR "Unknown platform ${GEODE_TARGET_PLATFORM}")
|
||||
endif()
|
||||
|
|
Loading…
Reference in a new issue