mirror of
https://codeberg.org/guix/guix.git
synced 2026-01-25 12:05:19 -06:00
* gnu/packages/swift.scm (swift-bootstrap): New variable. (%swift-bootstrap-source): New variable. (%swift-libdispatch-source): New variable. * gnu/local.mk (dist_patch_DATA): Add swift-5.7.3-sdk-path.patch, swift-5.7.3-sourcekit-rpath.patch, swift-corelibs-libdispatch-5.6.3-lock-cpp.patch, swift-corelibs-libdispatch-5.7.3-modulemap.patch. * gnu/packages/patches/swift-5.7.3-sdk-path.patch: New file. * gnu/packages/patches/swift-5.7.3-sourcekit-rpath.patch: New file. * gnu/packages/patches/swift-corelibs-libdispatch-5.6.3-lock-cpp.patch: New file. * gnu/packages/patches/swift-corelibs-libdispatch-5.7.3-modulemap.patch: New file. Change-Id: Ibcab88d88be0cc9634f297d17174ca99060e4d98
22 lines
934 B
Diff
22 lines
934 B
Diff
Author: Danny Milosavljevic <dannym@friendly-machines.com>
|
|
Date: 2025-10-20
|
|
Subject: Set RPATH for SourceKit
|
|
|
|
Set RPATH for SourceKit shared libraries on Linux when BOOTSTRAPPING_MODE is not set.
|
|
|
|
Without this, libsourcekitdInProc.so has no RPATH and cannot find libdispatch.so
|
|
and libBlocksRuntime.so in lib/swift/linux/.
|
|
|
|
--- a/tools/SourceKit/cmake/modules/AddSwiftSourceKit.cmake
|
|
+++ b/tools/SourceKit/cmake/modules/AddSwiftSourceKit.cmake
|
|
@@ -227,6 +227,10 @@ macro(add_sourcekit_library name)
|
|
|
|
if("${CMAKE_SYSTEM_NAME}" STREQUAL "Darwin")
|
|
set_target_properties(${name} PROPERTIES INSTALL_NAME_DIR "@rpath")
|
|
+ elseif("${CMAKE_SYSTEM_NAME}" STREQUAL "Linux")
|
|
+ if(NOT RPATH_LIST)
|
|
+ set(RPATH_LIST "$ORIGIN/swift/linux")
|
|
+ endif()
|
|
endif()
|
|
set_target_properties(${name} PROPERTIES BUILD_WITH_INSTALL_RPATH TRUE)
|
|
set_target_properties(${name} PROPERTIES INSTALL_RPATH "${RPATH_LIST}")
|