Skip to content

Commit

Permalink
COMP: Prefer clearing CMAKE_INSTALL_NAME_TOOL on a per-project basis
Browse files Browse the repository at this point in the history
Follow-up of 52b238d (COMP: Ensure full path ID for macOS libraries
installed for fix-up) reverting the systematic clearing of CMAKE_INSTALL_NAME_TOOL.

Due to the possibility of external projects (e.g., LibFFI) enabling languages (e.g., ASM)
that necessitate `install_name_tool` via the "CMakeFindBinUtils" module, we opt to clear
CMAKE_INSTALL_NAME_TOOL on a per-project basis.

(cherry picked from commit 0725f3a)
  • Loading branch information
jcfr committed Apr 5, 2024
1 parent 26f6833 commit 135f569
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 2 deletions.
5 changes: 4 additions & 1 deletion CMake/UseSlicer.cmake.in
Original file line number Diff line number Diff line change
Expand Up @@ -304,7 +304,10 @@ if(APPLE)
set(Slicer_BUNDLE_EXTENSIONS_LOCATION "${Slicer_EXTENSIONS_DIRBASENAME}-${Slicer_REVISION}/${EXTENSION_NAME}/")

set(CMAKE_INSTALL_NAME_TOOL "" CACHE FILEPATH "" FORCE)
mark_as_superbuild(VARS CMAKE_INSTALL_NAME_TOOL:FILEPATH ALL_PROJECTS)
# Due to the possibility of external projects (e.g., LibFFI) enabling languages (e.g., ASM)
# that necessitate `install_name_tool` via the "CMakeFindBinUtils" module, we opt to clear
# CMAKE_INSTALL_NAME_TOOL on a per-project basis.
# mark_as_superbuild(VARS CMAKE_INSTALL_NAME_TOOL:FILEPATH ALL_PROJECTS)

set(CMAKE_MACOSX_RPATH 0 CACHE BOOL "" FORCE)
mark_as_superbuild(VARS CMAKE_MACOSX_RPATH:BOOL ALL_PROJECTS)
Expand Down
5 changes: 4 additions & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,10 @@ if(APPLE)
)

set(CMAKE_INSTALL_NAME_TOOL "" CACHE FILEPATH "" FORCE)
mark_as_superbuild(VARS CMAKE_INSTALL_NAME_TOOL:FILEPATH ALL_PROJECTS)
# Due to the possibility of external projects (e.g., LibFFI) enabling languages (e.g., ASM)
# that necessitate `install_name_tool` via the "CMakeFindBinUtils" module, we opt to clear
# CMAKE_INSTALL_NAME_TOOL on a per-project basis.
# mark_as_superbuild(VARS CMAKE_INSTALL_NAME_TOOL:FILEPATH ALL_PROJECTS)

set(CMAKE_MACOSX_RPATH 0)
mark_as_superbuild(VARS CMAKE_MACOSX_RPATH:BOOL ALL_PROJECTS)
Expand Down

0 comments on commit 135f569

Please sign in to comment.