Skip to content

[bootstrap] Add the runtime library paths to [DY]LD_LIBRARY_PATHS… #2806

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

Merged
merged 1 commit into from
Aug 24, 2020

Conversation

mikeash
Copy link
Contributor

@mikeash mikeash commented Jul 8, 2020

…so we use the just-built libswiftCore instead of the OS's copy.

…we use the just-built libswiftCore instead of the OS's copy.
@mikeash
Copy link
Contributor Author

mikeash commented Jul 8, 2020

@neonichu I hit a problem where SwiftPM failed when building with build-script --swift-inspect --infer due to loading the OS's libswiftCore.dylib instead of the one we just built. This fixes it by adding the appropriate paths to [DY]LD_LIBRARY_PATHS. Is this the right fix for this issue?

@neonichu
Copy link
Contributor

This makes sense to me.

It looks like we're already using the runtime library paths as a source for rpaths here: https://github.com/apple/swift-package-manager/blob/839a5b668a3ffebce5c673214a7a96a01520af3a/Utilities/bootstrap#L659, but obviously that won't change the link time behaviour.

I will double check locally how the paths look like and whether it would make sense to move the more complex logic that is used for computing rpaths to also compute linker search paths.

@neonichu
Copy link
Contributor

@swift-ci please smoke test

@neonichu neonichu merged commit 3e07f3a into swiftlang:master Aug 24, 2020
skarred14 pushed a commit to val-verde/swift-package-manager that referenced this pull request Aug 26, 2020
…we use the just-built libswiftCore instead of the OS's copy. (swiftlang#2806)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants