Skip to content

[CMake] Fix macro install rpath #793

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
Jul 29, 2024

Conversation

jmschonfeld
Copy link
Contributor

This updates the macro library's rpath to reference the correct locations for the host and stldib libraries that it depends upon. This matches the rpath values for the existing macro libraries:

# readelf -d /usr/lib/swift/host/plugins/libSwiftMacros.so | grep RUNPATH
 0x000000000000001d (RUNPATH)            Library runpath: [$ORIGIN/../../../swift/linux:$ORIGIN/..]

I confirmed that using a locally built libFoundationMacros.so with this change successfully finds the required libraries rather than erroring out with compiler plugin '/usr/lib/swift/host/plugins/libFoundationMacros.so' could not be loaded; libswift_StringProcessing.so: cannot open shared object file: No such file or directory like before

@jmschonfeld
Copy link
Contributor Author

@swift-ci please test

@jmschonfeld jmschonfeld force-pushed the cmake/fix-macro-rpath branch from 7583081 to fc2871f Compare July 29, 2024 16:42
@jmschonfeld
Copy link
Contributor Author

@swift-ci please test

@jmschonfeld
Copy link
Contributor Author

Full swift toolchain build passed with this change (and passed the rpath packaging tests too)

@jmschonfeld jmschonfeld merged commit 8a44479 into swiftlang:main Jul 29, 2024
3 checks passed
@jmschonfeld jmschonfeld deleted the cmake/fix-macro-rpath branch July 29, 2024 23:15
jmschonfeld added a commit to jmschonfeld/swift-foundation that referenced this pull request Jul 29, 2024
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