You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The path /home/buildnode/jenkins/workspace/oss-swift-package-linux-ubuntu-18_04/build/buildbot_linux/swift-linux-x86_64/lib/swift/linux gets added by swiftc -emit-library as it always calls the linker with -rpath.
The path /usr/lib/swift/linux seems to be added in via swift/cmake/modules/AddSwift.cmake: INSTALL_RPATH "$ORIGIN:/usr/lib/swift/linux")
Both of these absolute paths seem incorrect to include especially the jenkins one, which also causes problems with the tests that run against the installation as they will always work even if the RUNPATH is missing $ORIGIN, as there is an absolute path to the build directory containing libraries.
I think there are two solutions to this:
Add a -no-add-rpath option to swiftc, although adding more options is probably best avoided if possible.
2. Install chrpath on the CI servers and modify the RUNPATH after the library is built:
Additional Detail from JIRA
md5: 21c2b3e5a48fda65f3eba90ceff90722
duplicates:
relates to:
Issue Description:
From the
swift-DEVELOPMENT-SNAPSHOT-2018-11-16-a-ubuntu18.04
snapshot:The path
/home/buildnode/jenkins/workspace/oss-swift-package-linux-ubuntu-18_04/build/buildbot_linux/swift-linux-x86_64/lib/swift/linux
gets added byswiftc -emit-library
as it always calls the linker with-rpath
.The path
/usr/lib/swift/linux
seems to be added in viaswift/cmake/modules/AddSwift.cmake: INSTALL_RPATH "$ORIGIN:/usr/lib/swift/linux")
Both of these absolute paths seem incorrect to include especially the jenkins one, which also causes problems with the tests that run against the installation as they will always work even if the
RUNPATH
is missing$ORIGIN,
as there is an absolute path to the build directory containing libraries.I think there are two solutions to this:
-no-add-rpath
option toswiftc
, although adding more options is probably best avoided if possible.2. Install
chrpath
on the CI servers and modify theRUNPATH
after the library is built:The text was updated successfully, but these errors were encountered: