diff --git a/cmake/macros/InstallBesideConsole.cmake b/cmake/macros/InstallBesideConsole.cmake index 8514a89aa2..f23b037221 100644 --- a/cmake/macros/InstallBesideConsole.cmake +++ b/cmake/macros/InstallBesideConsole.cmake @@ -14,9 +14,8 @@ macro(install_beside_console) if (APPLE) set(SHELL_APP_CONTENTS "Components.app/Contents") set(COMPONENT_DESTINATION "${SHELL_APP_CONTENTS}/MacOS") - else () - set(COMPONENT_DESTINATION .) + set(COMPONENT_DESTINATION ${CONSOLE_INSTALL_PATH}) endif () install( @@ -25,6 +24,21 @@ macro(install_beside_console) COMPONENT ${SERVER_COMPONENT} ) + if (TARGET_NAME STREQUAL domain-server) + if (APPLE) + set(RESOURCES_DESTINATION ${CONSOLE_INSTALL_PATH}/Contents/MacOS) + else () + set(RESOURCES_DESTINATION ${CONSOLE_INSTALL_PATH}) + endif () + + # install the resources folder for the domain-server where its executable will be + install( + DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/resources + DESTINATION ${RESOURCES_DESTINATION} + USE_SOURCE_PERMISSIONS + ) + endif () + if (APPLE) # during the install phase, call fixup to drop the shared libraries for these components in the right place set(EXECUTABLE_NEEDING_FIXUP "\${CMAKE_INSTALL_PREFIX}/${COMPONENT_DESTINATION}/${TARGET_NAME}") @@ -34,7 +48,7 @@ macro(install_beside_console) " COMPONENT ${SERVER_COMPONENT}) # once installed copy the contents of the shell Components.app to the console application - set(CONSOLE_INSTALL_PATH "Applications/High Fidelity/Server Console.app") + set(INSTALLED_CONSOLE_CONTENTS "\${CMAKE_INSTALL_PREFIX}/${CONSOLE_INSTALL_PATH}/Contents") set(INSTALLED_SHELL_CONTENTS "\${CMAKE_INSTALL_PREFIX}/${SHELL_APP_CONTENTS}") diff --git a/cmake/macros/SetPackagingParameters.cmake b/cmake/macros/SetPackagingParameters.cmake index 37e7d3bf3c..f68a69e688 100644 --- a/cmake/macros/SetPackagingParameters.cmake +++ b/cmake/macros/SetPackagingParameters.cmake @@ -13,6 +13,12 @@ macro(SET_PACKAGING_PARAMETERS) + if (APPLE) + set(CONSOLE_INSTALL_PATH "Applications/High Fidelity/Server Console.app") + else () + set(CONSOLE_INSTALL_PATH ".") + endif() + if (DEFINED ENV{JOB_ID}) set(DEPLOY_PACKAGE TRUE) set(BUILD_SEQ $ENV{JOB_ID})