gcc: revert "do not install sys-include headers for cross-compilers."#245550
Merged
1 commit merged intoNixOS:stagingfrom Jul 28, 2023
Merged
gcc: revert "do not install sys-include headers for cross-compilers."#2455501 commit merged intoNixOS:stagingfrom
1 commit merged intoNixOS:stagingfrom
Conversation
The change reverts commit 7df4387 A few reasons to revert the commit: 1. The change was not enough to restore `-idirafter` override semantic to match unwrapped compiler. 2. The change broke override semantics for cross-compilers 3. The change made override semantics different between cross-compiler and native compiler All of three have some overlap between, but I think it's important to call all of them out. The main fallout is the uboot builds, reported by cynerd. Used the following test to check the override recovery: $ nix shell github:NixOS/nixpkgs/release-22.05#pkgsCross.aarch64-multiplatform.stdenv.cc $$ cat stdio.h # empty $$ printf "#include <stdio.h>" | aarch64-unknown-linux-gnu-gcc -E - -o - -idirafter . >/dev/null; echo $? 0 It failed before the change and succeded after.
This was referenced Jul 26, 2023
Contributor
Author
|
Validated the fix helped for a smaller test: |
Contributor
Author
|
And also tested on @Cynerd 's config as: The change recovered the build. |
ghost
approved these changes
Jul 26, 2023
There was a problem hiding this comment.
This is a very good idea. Especially because the conditional can't be known at eval-time, so this if-then-fi can't be lifted into Nix code.
I will merge this as soon as my rebuilds complete.
Building on:
-
x86_64-linux -
powerpc64le-linux -
aarch64-linux(cross fromx86_64-linux) -
mips64el-linuxmixedn32/64(cross fromx86_64-linux)
Also built:
-
pkgs.tests.cross.sanity(almost finished)
Contributor
Author
|
Caused bootstrap failure on |
This turned out to be due to parallel stripping, rather than |
12 tasks
This pull request was closed.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The change reverts commit 7df4387
A few reasons to revert the commit:
-idirafteroverride semantic to match unwrapped compiler.All of three have some overlap between, but I think it's important to call all of them out.
The main fallout is the uboot builds, reported by cynerd.
Used the following test to check the override recovery:
It failed before the change and succeded after.
Description of changes
Things done
sandbox = trueset innix.conf? (See Nix manual)nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD". Note: all changes have to be committed, also see nixpkgs-review usage./result/bin/)