-
Notifications
You must be signed in to change notification settings - Fork 10.5k
[test] Enable Serialization/runtime-import-from-sdk on non-Darwin platforms #81842
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
base: main
Are you sure you want to change the base?
Conversation
@swift-ci smoke test |
@swift-ci smoke test |
64cd337
to
1e6641a
Compare
@swift-ci smoke test |
@swift-ci smoke test |
…tforms Also, remove Swift runtime modules from Serialization/module_defining_interface,_client that are unused.
@swift-ci smoke test |
@beccadax, I've been looking into some issues with cross-compiling for Unix platforms through specifying an explicit By adding the correct platform-suffixed path, where the compiler looks for the runtime modules on non-Darwin platforms, and tweaking some formatting, I got this test to pass the CI on linux and Windows too. 😃 The two other tests added runtime modules to a mock SDK, but were never used because of the rule about the resource-dir taking precedence, so I removed those lines without a problem. This small pull is ready for review, can finally enable it for non-Darwin. |
I'd also like to add another pull to change these two rules checked in this test, which currently boil down to the following:
While these rules may have made sense six years ago when cross-compilation with an explicitly specified Here are the alternate rules I propose:
The general principles of my rule changes are to always use the explicitly specified flag paths first, and only look in one path, no fallbacks. The latter is to avoid the risk of the runtime modules being pulled from one path while the runtime libraries are pulled from a completely different path, ie mixing and matching Swift SDK files from different locations and causing version conflicts. I have implemented my updated rule 1. in #79621 and can expand it to clean up rule 2., if given the go-ahead. Another consideration is the planned new cross-compilation model, which makes @beccadax, @etcwilde, @compnerd, and @kateinoigakukun , let me know what you think of these updated rules I propose, since you all have extensive experience with these cross-compilation flags. I'm fairly certain the updated rules will work well with non-Darwin platforms, but I have no experience with building for Darwin platforms, though my pull #79621 passing the macOS CI suggests my updated rule 1. will be fine. As seen in that small pull, we can add temporary warnings and fallbacks initially before tightening up these rules as I propose over time. |
Also, remove Swift runtime modules from Serialization/module_defining_interface,_client that are unused.
This seems to vary by platform today, so see what the CI finds...