diff options
author | Erik Kundiman <erik@megapahit.org> | 2024-07-07 12:05:00 +0800 |
---|---|---|
committer | Erik Kundiman <erik@megapahit.org> | 2024-07-07 12:05:00 +0800 |
commit | faa8e3bc698ed3eb2ff21d08b8a3d093ab12ff6c (patch) | |
tree | b362d0ee661670d1e9d03508411e97346e3df7ed | |
parent | dedf76e3f1eaebd053f193e92d6ffa3824a92c95 (diff) |
Link CEF & chmod a+x Dullahan execs after install
otherwise fixup_bundle would try to fix DullahanHelper executables
when otool -L somehow can't find files that contain spaces in their
names. By postponing the chmod until after fixup_bundle is called,
fixup_bundle will ignore the DullahanHelper apps since they contain
no executables yet by that time.
Apart from that, trying to link to CEF would fail before installation
cause SLPlugin's Frameworks directory wouldn't exist yet.
-rw-r--r-- | indra/newview/FixBundle.cmake.in | 12 | ||||
-rw-r--r-- | indra/newview/ViewerInstall.cmake | 28 |
2 files changed, 18 insertions, 22 deletions
diff --git a/indra/newview/FixBundle.cmake.in b/indra/newview/FixBundle.cmake.in index 73806642e4..08da5f5c0a 100644 --- a/indra/newview/FixBundle.cmake.in +++ b/indra/newview/FixBundle.cmake.in @@ -5,3 +5,15 @@ set(dirs ) fixup_bundle(${viewer_BINARY_DIR}/${VIEWER_CHANNEL}.app "" "${dirs}") + +file(CREATE_LINK + "../../../../Frameworks/Chromium Embedded Framework.framework" + "${viewer_BINARY_DIR}/${VIEWER_CHANNEL}.app/Contents/Resources/SLPlugin.app/Contents/Frameworks/Chromium Embedded Framework.framework" SYMBOLIC) + +file(CHMOD + "${viewer_BINARY_DIR}/${VIEWER_CHANNEL}.app/Contents/Resources/SLPlugin.app/Contents/Frameworks/DullahanHelper.app/Contents/MacOS/DullahanHelper" + "${viewer_BINARY_DIR}/${VIEWER_CHANNEL}.app/Contents/Resources/SLPlugin.app/Contents/Frameworks/DullahanHelper (GPU).app/Contents/MacOS/DullahanHelper (GPU)" + "${viewer_BINARY_DIR}/${VIEWER_CHANNEL}.app/Contents/Resources/SLPlugin.app/Contents/Frameworks/DullahanHelper (Plugin).app/Contents/MacOS/DullahanHelper (Plugin)" + "${viewer_BINARY_DIR}/${VIEWER_CHANNEL}.app/Contents/Resources/SLPlugin.app/Contents/Frameworks/DullahanHelper (Renderer).app/Contents/MacOS/DullahanHelper (Renderer)" + PERMISSIONS OWNER_EXECUTE GROUP_EXECUTE WORLD_EXECUTE + ) diff --git a/indra/newview/ViewerInstall.cmake b/indra/newview/ViewerInstall.cmake index 8d91e2fc58..b6f5569061 100644 --- a/indra/newview/ViewerInstall.cmake +++ b/indra/newview/ViewerInstall.cmake @@ -46,18 +46,11 @@ if (DARWIN) DESTINATION Resources/app_settings ) - configure_file( - ${CMAKE_CURRENT_SOURCE_DIR}/FixBundle.cmake.in - ${CMAKE_CURRENT_BINARY_DIR}/FixBundle.cmake - ) - install(SCRIPT ${CMAKE_CURRENT_BINARY_DIR}/FixBundle.cmake) - install(DIRECTORY "${AUTOBUILD_INSTALL_DIR}/lib/release/Chromium Embedded Framework.framework" DESTINATION Frameworks ) - file(CREATE_LINK "../../../../Frameworks/Chromium Embedded Framework.framework" "${viewer_BINARY_DIR}/${VIEWER_CHANNEL}.app/Contents/Resources/SLPlugin.app/Contents/Frameworks/Chromium Embedded Framework.framework" SYMBOLIC) install(DIRECTORY "${AUTOBUILD_INSTALL_DIR}/lib/release/DullahanHelper.app" "${AUTOBUILD_INSTALL_DIR}/lib/release/DullahanHelper (GPU).app" @@ -65,22 +58,13 @@ if (DARWIN) "${AUTOBUILD_INSTALL_DIR}/lib/release/DullahanHelper (Renderer).app" DESTINATION Resources/SLPlugin.app/Contents/Frameworks ) - install(PROGRAMS - "${AUTOBUILD_INSTALL_DIR}/lib/release/DullahanHelper.app/Contents/MacOS/DullahanHelper" - DESTINATION "${viewer_BINARY_DIR}/${VIEWER_CHANNEL}.app/Contents/Resources/SLPlugin.app/Contents/Frameworks/DullahanHelper.app/Contents/MacOS" - ) - install(PROGRAMS - "${AUTOBUILD_INSTALL_DIR}/lib/release/DullahanHelper (GPU).app/Contents/MacOS/DullahanHelper (GPU)" - DESTINATION "${viewer_BINARY_DIR}/${VIEWER_CHANNEL}.app/Contents/Resources/SLPlugin.app/Contents/Frameworks/DullahanHelper (GPU).app/Contents/MacOS" - ) - install(PROGRAMS - "${AUTOBUILD_INSTALL_DIR}/lib/release/DullahanHelper (Plugin).app/Contents/MacOS/DullahanHelper (Plugin)" - DESTINATION "${viewer_BINARY_DIR}/${VIEWER_CHANNEL}.app/Contents/Resources/SLPlugin.app/Contents/Frameworks/DullahanHelper (Plugin).app/Contents/MacOS" - ) - install(PROGRAMS - "${AUTOBUILD_INSTALL_DIR}/lib/release/DullahanHelper (Renderer).app/Contents/MacOS/DullahanHelper (Renderer)" - DESTINATION "${viewer_BINARY_DIR}/${VIEWER_CHANNEL}.app/Contents/Resources/SLPlugin.app/Contents/Frameworks/DullahanHelper (Renderer).app/Contents/MacOS" + + configure_file( + ${CMAKE_CURRENT_SOURCE_DIR}/FixBundle.cmake.in + ${CMAKE_CURRENT_BINARY_DIR}/FixBundle.cmake ) + install(SCRIPT ${CMAKE_CURRENT_BINARY_DIR}/FixBundle.cmake) + else (DARWIN) install(PROGRAMS ${CMAKE_CURRENT_BINARY_DIR}/${VIEWER_BINARY_NAME} |