-
Notifications
You must be signed in to change notification settings - Fork 10.5k
Look for runtime library modules in the SDK, too #23175
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
Look for runtime library modules in the SDK, too #23175
Conversation
|
e68c834
to
019f8ba
Compare
@swift-ci please test |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This will require a matching change in lldb:
|
Matches changes in swiftlang/swift#23175.
Please test with following pull request: @swift-ci test |
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.
Looks pretty good, only minor comments.
Replaces SearchPathOptions::RuntimeLibraryImportPath with an equivalent std::vector of paths. Also reimplements SearchPathOptions::SkipRuntimeLibraryImportPaths to cause the list of runtime library import paths to be empty, rather than exiting early from SerializedModuleLoader::findModule().
019f8ba
to
09f87d3
Compare
Please test with following pull request: @swift-ci test |
09f87d3
to
ba09af0
Compare
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
Please test with following pull request: @swift-ci please smoke test |
ba09af0
to
9b56c6c
Compare
The new test caused a different error message on Linux than it did on macOS. Tweaked the test to use an empty SDK instead of an SDK with an unloadable standard library; that ought to give the same message on both platforms. |
Please test with following pull request: @swift-ci please smoke test |
Er, but that's no longer testing that we prefer the SDK over the toolchain. |
Why doesn't Github have 🤦♂️ as a reaction? |
With this change, swiftc will still look for standard library and overlay modules in ../lib/swift (relative to the compiler), but if it doesn’t find them there, it will now look in usr/lib/swift in the SDK.
9b56c6c
to
c177674
Compare
@jrose-apple I don't think there's a way to distinguish between "standard library is invalid" and "standard library is missing" on non-Darwin platforms, so I'll go back to the old test design and make it conditional on objc_interop. I filed SR-10097 to improve the errors. I need to get this tested and merged so it can be cherry-picked, but if you're not happy with where this is at, I can do some follow-up work in another PR. |
Please test with following pull request: @swift-ci please smoke test |
…eryone Look for runtime library modules in the SDK, too
The folder doesn't do that? |
In swiftlang#23175, we started looking in the SDK for swiftmodules, but we want to look for the dylibs there too. Fixes <rdar://problem/52059706>.
In #23175, we started looking in the SDK for swiftmodules, but we want to look for the dylibs there too. Fixes <rdar://problem/52059706>.
Cherry-picks swiftlang#25740: > In swiftlang#23175, we started looking in the SDK for swiftmodules, but we want to look for the dylibs there too. Fixes <rdar://problem/52059706>.
Once module stability arrives, we'll want to load modules (and particularly parsable interfaces) from the SDK instead of the toolchain. This PR starts to stage that change in.
Resolves rdar://problem/46132288.