-
-
Notifications
You must be signed in to change notification settings - Fork 14.1k
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
{bintools-wrapper,cc-wrapper}: factor out Darwin SDK logic, allow paths relative to the Darwin SDK #351315
Conversation
This reduces code duplication, makes the SDK variables available earlier in the wrappers, and makes the behaviour between the two wrappers more consistent.
I’ve confirmed that |
`-L` and `-I` are interpreted relative to the `$SDKROOT` by the Darwin toolchain, so we have to avoid filtering out such paths in the purity filter hacks in order to not break e.g. the .NET Core build system. It’s also just the correct thing to do for the platform.
a468519
to
e047c69
Compare
Building |
I hate to be the one to tell you this, but FWIW I have built like a thousand derivations with this change to test .NET (which also goes through Swift). |
broken by #349585 the fix is in staging #349589 tho #349585 could get backed out on master and merged to staging so the cc tests work at the end of the release cycle. |
Oh, cool. I’ll test the merge then. |
FWIW we’re meant to have one more |
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.
tests.cc-wrapper.default
passes on linux
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.
I’ll defer to the testing done here. Regarding the Darwin flags changes, those LGTM. They’re essentially identical between cc-wrapper and bintools-wrapper, so it makes sense to consolidate them to wrapper-common
.
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.
This looks great and builds on Linux.
It still fails because I will open a PR to fix that, but I just undid the tests changes locally for now, and they pass successfully 🎉 Merging on the strength of that, I hope that is okay. |
This pull request has been mentioned on NixOS Discourse. There might be relevant details there: https://discourse.nixos.org/t/title-the-darwin-sdks-have-been-updated/55295/1 |
This pull request has been mentioned on NixOS Discourse. There might be relevant details there: https://discourse.nixos.org/t/the-darwin-sdks-have-been-updated/55295/26 |
-L
and-I
are interpreted relative to the$SDKROOT
by the Darwin toolchain, so we have to avoid filtering out such paths in the purity filter hacks in order to not break e.g. the .NET Core build system. It’s also just the correct thing to do for the platform.Things done
nix.conf
? (See Nix manual)sandbox = relaxed
sandbox = true
nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD"
. Note: all changes have to be committed, also see nixpkgs-review usage./result/bin/
)Add a 👍 reaction to pull requests you find important.