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
misc pkgs: various cross fixes in preparation for darwin->linux #46857
misc pkgs: various cross fixes in preparation for darwin->linux #46857
Conversation
@@ -176,7 +174,7 @@ rec { | |||
// { | |||
# A hack to make `nix-env -qa` and `nix search` ignore broken packages. | |||
# TODO(@oxij): remove this assert when something like NixOS/nix#1771 gets merged into nix. | |||
name = assert validity.handled; name + lib.optionalString | |||
name = assert (validity.handled && separateDebugInfo -> stdenv.hostPlatform.isLinux); name + lib.optionalString |
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 think we can just leave this off. It's awkward to put it here.
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.
But then I'd be removing the assertion altogether? if check-meta
checked things besides meta
that would clean this up, but that's a larger refactor.
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.
It just doesn't seem like a reason for a package to be "broken". Maybe replace separateDebugInfo
references above with separateDebugInfo && stdenv.hostPlatform.isLinux
?
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.
But then I'm still changing the interface? Also asking for separateDebugInfo
and not getting it could be confusing, and finally re-tightening the interface after its so loosened is a breaking change.
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.
2a28bc6 is the origin of the assert, BTW.
Success on x86_64-linux (full log) Attempted: gcc Partial log (click to expand)
|
Success on aarch64-linux (full log) Attempted: gcc Partial log (click to expand)
|
Success on x86_64-darwin (full log) Attempted: gcc Partial log (click to expand)
|
…r assertions This is needed to access attributes of derivations on platforms where they cannot be built.
Want to make sure these are the same per host platform, without duplication.
Only the regular GCC is built with a libc dependency.
This isn't a MUSL thing, but just needed for cross compilation to x86. No one had tried this when all cross compilation was to linux + glibc, hence why no one noticed this until recently.
5ad18f5
to
2091133
Compare
Success on x86_64-linux (full log) Attempted: gcc Partial log (click to expand)
|
Success on x86_64-darwin (full log) Attempted: gcc Partial log (click to expand)
|
Success on aarch64-linux (full log) Attempted: gcc Partial log (click to expand)
|
/cc @Ericson2314 PR was #46857 This line broke MacOS cross compilation. paxctl cannot be built on macOS. Maybe it can be fixed, but no reason to break things unnecessarily. Regardless, you definitely need to be more careful about backporting. I think it’s fine to move fast and break things on master but with release-18.09 we should be more careful. Something like more automated testing for cross compilation would also be helpful (hopefully even making it block).
/cc @Ericson2314 PR was #46857 This line broke MacOS cross compilation. paxctl cannot be built on macOS. Maybe it can be fixed, but no reason to break things unnecessarily. Regardless, you definitely need to be more careful about backporting. I think it’s fine to move fast and break things on master but with release-18.09 we should be more careful. Something like more automated testing for cross compilation would also be helpful (hopefully even making it block). (cherry picked from commit f9c4075)
Motivation for this change
Non-staging, and non-darwin-specific parts of #46534.
By commit:
gnu-config
scripts.Backport: #46858 46858.
Things done
sandbox
innix.conf
on non-NixOS)nix-shell -p nox --run "nox-review wip"
./result/bin/
)nix path-info -S
before and after)