New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[build] Adjust install name for Differentiation and Concurrency #34216
[build] Adjust install name for Differentiation and Concurrency #34216
Conversation
This way we match the way we build other Swift libraries, to allow the dylib to have an absolute install name and at the same time be found when used as part of a local toolchain (e.g. apple#31183)
@swift-ci please smoke test |
@swift-ci please build toolchain |
For the sake of completeness -- I'm not touching |
Linux Toolchain (Ubuntu 16.04) Install command |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The right way to load the stdlib & runtime libraries from the toolchain is to set DYLD_LIBRARY_PATH when executing the generated binary. This is how we run tests against the just-built libraries and this is how downloadable toolchain snapshots are currently configured in Xcode -- see #33178)
@@ -29,5 +30,4 @@ add_swift_target_library(swift_Concurrency ${SWIFT_STDLIB_LIBRARY_BUILD_TYPES} I | |||
${SWIFT_STANDARD_LIBRARY_SWIFT_FLAGS} | |||
-parse-stdlib | |||
LINK_FLAGS "${SWIFT_RUNTIME_SWIFT_LINK_FLAGS}" | |||
DARWIN_INSTALL_NAME_DIR "@rpath" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Note: this change is right -- the install_name should be left with the default /usr/lib/swift/ prefix, matching the other stdlib libraries.
@swift-ci please smoke test |
@swift-ci please build toolchain |
Linux Toolchain (Ubuntu 16.04) Install command |
@swift-ci please smoke test |
macOS Toolchain Install command |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM! 👍
@swift-ci please smoke test Linux |
1 similar comment
@swift-ci please smoke test Linux |
Tested that the generated toolchain restores the intended behaviour
|
This effectively reverts #31183 -- we need to match the install name convention of the other stdlib libraries.
From the review feedback: