Commit 1098b62e authored by jcfr's avatar jcfr

ENH: Ensure CMAKE_MACOSX_RPATH is consistently pass to all external projects

By updating UseSlicer.cmake.in, this commit also makes sure the variable
is passed to all external projects in SuperBuild based extensions.

git-svn-id: http://svn.slicer.org/Slicer4/trunk@26977 3bd1e089-480b-0410-8dfb-8563597acbee
parent aa07f6b2
......@@ -296,6 +296,7 @@ if(APPLE)
set(Slicer_BUNDLE_EXTENSIONS_LOCATION "${Slicer_EXTENSIONS_DIRNAME}/${EXTENSION_NAME}/")
set(CMAKE_INSTALL_NAME_TOOL "" CACHE FILEPATH "" FORCE) # XXX Probably not needed anymore
set(CMAKE_MACOSX_RPATH 0 CACHE BOOL "" FORCE)
mark_as_superbuild(VARS CMAKE_MACOSX_RPATH:BOOL ALL_PROJECTS)
endif()
#-----------------------------------------------------------------------------
......
......@@ -36,6 +36,7 @@ if(APPLE)
)
set(CMAKE_MACOSX_RPATH 0)
mark_as_superbuild(VARS CMAKE_MACOSX_RPATH:BOOL ALL_PROJECTS)
endif()
#-----------------------------------------------------------------------------
......
......@@ -35,7 +35,6 @@ if(NOT DEFINED ${proj}_DIR AND NOT ${CMAKE_PROJECT_NAME}_USE_SYSTEM_${proj})
-DCMAKE_CXX_EXTENSIONS:BOOL=${CMAKE_CXX_EXTENSIONS}
-DCMAKE_BUILD_TYPE:STRING=${CMAKE_BUILD_TYPE}
-DBUILD_TESTING:BOOL=OFF
-DCMAKE_MACOSX_RPATH:BOOL=0
-DCMAKE_RUNTIME_OUTPUT_DIRECTORY:PATH=${CMAKE_BINARY_DIR}/${Slicer_THIRDPARTY_BIN_DIR}
-DCMAKE_LIBRARY_OUTPUT_DIRECTORY:PATH=${CMAKE_BINARY_DIR}/${Slicer_THIRDPARTY_LIB_DIR}
-DCMAKE_ARCHIVE_OUTPUT_DIRECTORY:PATH=${CMAKE_ARCHIVE_OUTPUT_DIRECTORY}
......
......@@ -125,8 +125,6 @@ if(NOT DEFINED CTK_DIR AND NOT ${CMAKE_PROJECT_NAME}_USE_SYSTEM_${proj})
-DCTK_LIB_Scripting/Python/Core_PYTHONQT_WRAP_QTWEBKIT:BOOL=${_wrap_qtwebkit}
-DCTK_LIB_Scripting/Python/Widgets:BOOL=${Slicer_USE_PYTHONQT}
-DCTK_ENABLE_Python_Wrapping:BOOL=${Slicer_USE_PYTHONQT}
# macOS
-DCMAKE_MACOSX_RPATH:BOOL=0
INSTALL_COMMAND ""
DEPENDS
${${proj}_DEPENDENCIES}
......
......@@ -62,8 +62,6 @@ if(NOT DEFINED CTKAppLauncherLib_DIR AND NOT ${CMAKE_PROJECT_NAME}_USE_SYSTEM_${
# XXX Revisit this when visibility flags will directly be used in Slicer
-DCTKAppLauncher_VISIBILITY_HIDDEN:BOOL=OFF
${EXTERNAL_PROJECT_OPTIONAL_ARGS}
# macOS
-DCMAKE_MACOSX_RPATH:BOOL=0
INSTALL_COMMAND ""
DEPENDS
${${proj}_DEPENDENCIES}
......
......@@ -95,8 +95,6 @@ if(NOT DEFINED DCMTK_DIR AND NOT ${CMAKE_PROJECT_NAME}_USE_SYSTEM_${proj})
-DDCMTK_ENABLE_BUILTIN_DICTIONARY:BOOL=ON
-DDCMTK_ENABLE_PRIVATE_TAGS:BOOL=ON
${EXTERNAL_PROJECT_OPTIONAL_ARGS}
# macOS
-DCMAKE_MACOSX_RPATH:BOOL=0
INSTALL_COMMAND ""
DEPENDS
${${proj}_DEPENDENCIES}
......
......@@ -109,8 +109,6 @@ if(NOT DEFINED ITK_DIR AND NOT ${CMAKE_PROJECT_NAME}_USE_SYSTEM_${proj})
-DITK_WRAPPING:BOOL=OFF #${BUILD_SHARED_LIBS} ## HACK: QUICK CHANGE
-DITK_WRAP_PYTHON:BOOL=${Slicer_BUILD_ITKPython}
-DExternalData_OBJECT_STORES:PATH=${ExternalData_OBJECT_STORES}
# macOS
-DCMAKE_MACOSX_RPATH:BOOL=0
# VTK
-DModule_ITKVtkGlue:BOOL=ON
-DVTK_DIR:PATH=${VTK_DIR}
......
......@@ -68,8 +68,6 @@ if(NOT DEFINED ${proj}_DIR AND NOT ${CMAKE_PROJECT_NAME}_USE_SYSTEM_${proj})
-DARCHIVE_INSTALL_DIR:PATH=${Slicer_INSTALL_LIB_DIR}
-DINCLUDE_INSTALL_DIR:PATH=${Slicer_INSTALL_INCLUDE_DIR}
${EXTERNAL_PROJECT_OPTIONAL_ARGS}
# macOS
-DCMAKE_MACOSX_RPATH:BOOL=0
INSTALL_COMMAND ""
DEPENDS
${${proj}_DEPENDENCIES}
......
......@@ -84,8 +84,6 @@ if((NOT DEFINED LibArchive_INCLUDE_DIR
-DZLIB_LIBRARY:FILEPATH=${ZLIB_LIBRARY}
-DCMAKE_INSTALL_PREFIX:PATH=<INSTALL_DIR>
${EXTERNAL_PROJECT_OPTIONAL_ARGS}
# macOS
-DCMAKE_MACOSX_RPATH:BOOL=0
DEPENDS
${${proj}_DEPENDENCIES}
)
......
......@@ -59,8 +59,6 @@ if(NOT DEFINED OpenIGTLink_DIR AND NOT ${CMAKE_PROJECT_NAME}_USE_SYSTEM_${proj})
-DBUILD_SHARED_LIBS:BOOL=ON
-DOpenIGTLink_PROTOCOL_VERSION_2:BOOL=ON
-DOpenIGTLink_PROTOCOL_VERSION_3:BOOL=ON
# macOS
-DCMAKE_MACOSX_RPATH:BOOL=0
INSTALL_COMMAND ""
DEPENDS
${${proj}_DEPENDENCIES}
......
......@@ -54,8 +54,6 @@ if(NOT DEFINED ${proj}_DIR AND NOT ${CMAKE_PROJECT_NAME}_USE_SYSTEM_${proj})
-DJsonCpp_LIBRARY:PATH=${JsonCpp_LIBRARY}
-DITK_DIR:PATH=${ITK_DIR}
${EXTERNAL_PROJECT_OPTIONAL_ARGS}
# macOS
-DCMAKE_MACOSX_RPATH:BOOL=0
INSTALL_COMMAND ""
DEPENDS
${${proj}_DEPENDENCIES}
......
......@@ -57,8 +57,6 @@ if(NOT DEFINED ${proj}_DIR AND NOT ${CMAKE_PROJECT_NAME}_USE_SYSTEM_${proj})
-DARCHIVE_INSTALL_DIR:PATH=${Slicer_INSTALL_LIB_DIR}
-DINCLUDE_INSTALL_DIR:PATH=${Slicer_INSTALL_INCLUDE_DIR}
${EXTERNAL_PROJECT_OPTIONAL_ARGS}
# macOS
-DCMAKE_MACOSX_RPATH:BOOL=0
INSTALL_COMMAND ""
DEPENDS
${${proj}_DEPENDENCIES}
......
......@@ -128,8 +128,6 @@ ExternalProject_Execute(${proj} \"install\" \"${PYTHON_EXECUTABLE}\" Packaging/s
-DWRAP_PYTHON:BOOL=ON
-DSimpleITK_BUILD_DISTRIBUTE:BOOL=ON # Shorten version and install path removing -g{GIT-HASH} suffix.
-DExternalData_OBJECT_STORES:PATH=${ExternalData_OBJECT_STORES}
# macOS
-DCMAKE_MACOSX_RPATH:BOOL=0
#
INSTALL_COMMAND ${CMAKE_COMMAND} -P ${_install_script}
#
......
......@@ -110,8 +110,6 @@ if(NOT DEFINED SlicerExecutionModel_DIR AND NOT ${CMAKE_PROJECT_NAME}_USE_SYSTEM
-DSlicerExecutionModel_DEFAULT_CLI_TARGETS_FOLDER_PREFIX:STRING=Module-
${EXTERNAL_PROJECT_OPTIONAL_CMAKE_CACHE_ARGS}
${EXTERNAL_PROJECT_OPTIONAL_CMAKE_ARGS}
# macOS
-DCMAKE_MACOSX_RPATH:BOOL=0
INSTALL_COMMAND ""
DEPENDS
${${proj}_DEPENDENCIES}
......
......@@ -153,8 +153,6 @@ endif()
-DVTK_ENABLE_KITS:BOOL=${VTK_ENABLE_KITS}
-DVTK_RENDERING_BACKEND:STRING=${Slicer_VTK_RENDERING_BACKEND}
${EXTERNAL_PROJECT_OPTIONAL_ARGS}
# macOS
-DCMAKE_MACOSX_RPATH:BOOL=0
INSTALL_COMMAND ""
DEPENDS
${${proj}_DEPENDENCIES}
......
......@@ -55,8 +55,6 @@ if((NOT DEFINED BZIP2_INCLUDE_DIR
-DCMAKE_C_FLAGS:STRING=${ep_common_c_flags}
-DCMAKE_DEBUG_POSTFIX:STRING=
-DCMAKE_INSTALL_PREFIX:PATH=<INSTALL_DIR>
# macOS
-DCMAKE_MACOSX_RPATH:BOOL=0
DEPENDS
${${proj}_DEPENDENCIES}
)
......
......@@ -94,8 +94,6 @@ if((NOT DEFINED CURL_INCLUDE_DIR
-DCURL_DISABLE_TFTP:BOOL=ON
-DHAVE_LIBIDN:BOOL=FALSE
-DCMAKE_USE_OPENSSL:BOOL=${CURL_ENABLE_SSL}
# macOS
-DCMAKE_MACOSX_RPATH:BOOL=0
${EXTERNAL_PROJECT_OPTIONAL_CMAKE_ARGS}
DEPENDS
${${proj}_DEPENDENCIES}
......
......@@ -163,8 +163,6 @@ if((NOT DEFINED PYTHON_INCLUDE_DIR
-DENABLE_SSL:BOOL=${PYTHON_ENABLE_SSL}
-DPatch_EXECUTABLE:FILEPATH=${Patch_EXECUTABLE}
${EXTERNAL_PROJECT_OPTIONAL_CMAKE_CACHE_ARGS}
# macOS
-DCMAKE_MACOSX_RPATH:BOOL=0
${EXTERNAL_PROJECT_OPTIONAL_CMAKE_ARGS}
${_build_command}
${_install_command}
......
......@@ -64,8 +64,6 @@ if(NOT DEFINED qRestAPI_DIR)
-DBUILD_TESTING:BOOL=OFF
-DBUILD_SHARED_LIBS:BOOL=OFF
${ep_cache_args}
# macOS
-DCMAKE_MACOSX_RPATH:BOOL=0
INSTALL_COMMAND ""
DEPENDS
${${proj}_DEPENDENCIES}
......
......@@ -86,8 +86,6 @@ if(NOT DEFINED Teem_DIR AND NOT ${CMAKE_PROJECT_NAME}_USE_SYSTEM_${proj})
-DPNG_PNG_INCLUDE_DIR:PATH=${PNG_INCLUDE_DIR}
-DTeem_PNG_DLLCONF_IPATH:PATH=${VTK_DIR}/Utilities
${EXTERNAL_PROJECT_OPTIONAL_ARGS}
# macOS
-DCMAKE_MACOSX_RPATH:BOOL=0
INSTALL_COMMAND ""
DEPENDS
${${proj}_DEPENDENCIES}
......
......@@ -51,8 +51,6 @@ if(NOT DEFINED zlib_DIR AND NOT ${CMAKE_PROJECT_NAME}_USE_SYSTEM_${proj})
-DCMAKE_C_FLAGS:STRING=${ep_common_c_flags}
-DZLIB_MANGLE_PREFIX:STRING=slicer_zlib_
-DCMAKE_INSTALL_PREFIX:PATH=<INSTALL_DIR>
# macOS
-DCMAKE_MACOSX_RPATH:BOOL=0
DEPENDS
${${proj}_DEPENDENCIES}
)
......
......@@ -35,7 +35,6 @@ if(NOT DEFINED ${proj}_DIR AND NOT ${CMAKE_PROJECT_NAME}_USE_SYSTEM_${proj})
-DCMAKE_CXX_EXTENSIONS:BOOL=${CMAKE_CXX_EXTENSIONS}
-DCMAKE_BUILD_TYPE:STRING=${CMAKE_BUILD_TYPE}
-DBUILD_TESTING:BOOL=OFF
-DCMAKE_MACOSX_RPATH:BOOL=0
-DCMAKE_RUNTIME_OUTPUT_DIRECTORY:PATH=${CMAKE_BINARY_DIR}/${Slicer_THIRDPARTY_BIN_DIR}
-DCMAKE_LIBRARY_OUTPUT_DIRECTORY:PATH=${CMAKE_BINARY_DIR}/${Slicer_THIRDPARTY_LIB_DIR}
-DCMAKE_ARCHIVE_OUTPUT_DIRECTORY:PATH=${CMAKE_ARCHIVE_OUTPUT_DIRECTORY}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment