aboutsummaryrefslogtreecommitdiff
path: root/cmake
diff options
context:
space:
mode:
authorfuzzard <fuzzard@kodi.tv>2020-10-25 17:45:05 +1000
committerfuzzard <fuzzard@kodi.tv>2021-05-17 14:29:19 +1000
commit98e6d6752f7f422544da7133f669111fab9d1b3e (patch)
treeec4dac05744a985eca6da5f31b87f94e23e99d92 /cmake
parentbeedef3225d196094e61efe2ae0a5dbbfcea72e1 (diff)
[osx] xcode target for building binary addons
This brings in the same mechanism to add binary addon targets to xcode project as was introduced to Darwin_embedded platforms in the following PR https://github.com/xbmc/xbmc/pull/17554
Diffstat (limited to 'cmake')
-rw-r--r--cmake/scripts/osx/Install.cmake15
1 files changed, 15 insertions, 0 deletions
diff --git a/cmake/scripts/osx/Install.cmake b/cmake/scripts/osx/Install.cmake
index 629bc09cd3..61a46c1278 100644
--- a/cmake/scripts/osx/Install.cmake
+++ b/cmake/scripts/osx/Install.cmake
@@ -6,6 +6,21 @@ configure_file(${CMAKE_SOURCE_DIR}/xbmc/platform/darwin/osx/Info.plist.in
${CMAKE_BINARY_DIR}/xbmc/platform/darwin/osx/Info.plist @ONLY)
execute_process(COMMAND perl -p -i -e "s/r####/${APP_SCMID}/" ${CMAKE_BINARY_DIR}/xbmc/platform/darwin/osx/Info.plist)
+# Create xcode target that allows to build binary-addons.
+if(CMAKE_GENERATOR MATCHES "Xcode")
+ if(ADDONS_TO_BUILD)
+ set(_addons "ADDONS=${ADDONS_TO_BUILD}")
+ endif()
+ add_custom_target(binary-addons
+ COMMAND $(MAKE) -C ${CMAKE_SOURCE_DIR}/tools/depends/target/binary-addons clean
+ COMMAND $(MAKE) -C ${CMAKE_SOURCE_DIR}/tools/depends/target/binary-addons VERBOSE=1 V=99
+ INSTALL_PREFIX="${CMAKE_BINARY_DIR}/addons" CROSS_COMPILING=yes ${_addons})
+ if(ENABLE_XCODE_ADDONBUILD)
+ add_dependencies(${APP_NAME_LC} binary-addons)
+ endif()
+ unset(_addons)
+endif()
+
add_custom_target(bundle
COMMAND ${CMAKE_COMMAND} -E copy $<TARGET_FILE:${APP_NAME_LC}> ${PACKAGE_OUTPUT_DIR}/${APP_NAME}
COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_BINARY_DIR}/${CORE_BUILD_DIR}/DllPaths_generated.h