Fix Android strip not being run without Geode CLI

This commit is contained in:
Cvolton 2023-12-13 01:01:58 +01:00
parent d9b913b06c
commit ffed1df4fc

View file

@ -51,6 +51,17 @@ function(setup_geode_mod proname)
# Link Geode to the mod
target_link_libraries(${proname} geode-sdk)
if (ANDROID)
if (CMAKE_BUILD_TYPE STREQUAL "Release")
add_custom_command(
TARGET "${PROJECT_NAME}" POST_BUILD
DEPENDS "${PROJECT_NAME}"
COMMAND $<$<CONFIG:release>:${CMAKE_STRIP}>
ARGS -S $<TARGET_FILE:${PROJECT_NAME}>
)
endif()
endif()
if (GEODE_DISABLE_CLI_CALLS)
message("Skipping setting up geode mod ${proname}")
return()
@ -207,17 +218,6 @@ function(setup_geode_mod proname)
set_target_properties(${proname} PROPERTIES PREFIX "")
set_target_properties(${proname} PROPERTIES OUTPUT_NAME ${MOD_ID})
if (ANDROID)
if (CMAKE_BUILD_TYPE STREQUAL "Release")
add_custom_command(
TARGET "${PROJECT_NAME}" POST_BUILD
DEPENDS "${PROJECT_NAME}"
COMMAND $<$<CONFIG:release>:${CMAKE_STRIP}>
ARGS -S $<TARGET_FILE:${PROJECT_NAME}>
)
endif()
endif()
endfunction()
function(create_geode_file proname)