mirror of
https://github.com/Kitware/CMake.git
synced 2026-01-02 03:39:43 -06:00
Swift: support -rpath on Darwin
Darwin also has the concept of RPATH. Additionally, the flag is identical to that on other Unixish platforms. Simply avoid the `-rpath` handling on Windows. This enables the use of `BUILD_WITH_INSTALL_RPATH` and `INSTALL_RPATH` with Swift targets on Darwin.
This commit is contained in:
committed by
Brad King
parent
a1216139f8
commit
ff6c336127
@@ -24,7 +24,7 @@ elseif(NOT CMAKE_SYSTEM_NAME STREQUAL Windows)
|
||||
set(CMAKE_SHARED_LIBRARY_SONAME_Swift_FLAG "-Xlinker -soname -Xlinker ")
|
||||
endif()
|
||||
|
||||
if(NOT CMAKE_SYSTEM_NAME STREQUAL Windows AND NOT CMAKE_SYSTEM_NAME STREQUAL Darwin)
|
||||
if(NOT CMAKE_SYSTEM_NAME STREQUAL Windows)
|
||||
set(CMAKE_SHARED_LIBRARY_RUNTIME_Swift_FLAG "-Xlinker -rpath -Xlinker ")
|
||||
set(CMAKE_SHARED_LIBRARY_RUNTIME_Swift_FLAG_SEP ":")
|
||||
endif()
|
||||
|
||||
Reference in New Issue
Block a user