gcc: use standard builder instead of custom builder.sh#237856
Conversation
trofi
left a comment
There was a problem hiding this comment.
Looks good.
diffoscope does not show any material changes before/after at least for gcc.cc.
|
Having said that |
This comment was marked as resolved.
This comment was marked as resolved.
This comment was marked as resolved.
This comment was marked as resolved.
This comment was marked as resolved.
This comment was marked as resolved.
This commit is left unsquashed to make review of the subsequent commits easier.
This commit performs two search-and-replace operations:
- replace all `${` with `''${`
- replace `''` with `""` in shell scripts
This commit is left unsquashed to make review of the subsequent
commits easier.
This commit adds arguments to `builder.nix`, making it a callable function, and splits up the single massive shell script into separate attributes for each phase. It also drops the first two lines and the last line because these are part of the default builder. All script lines which were not part of a phase function have been moved into `preUnpack` since this is the first phase that runs. Subsequent commits will move parts of this to more sensible locations.
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
|
Okay, I found the problem with Since last review I have:
So I think e02be1883fb2f1eacde8b193400c2168fce20737 is the only commit that needs additional review. @ofborg build wineWowPackages.waylandFull.stdenv.cc.cc |
|
Building:
|
|
wineWowPackages.waylandFull.stdenv.cc.cc on x86_64-linux — Success |
|
Looks like #241980 was lost (and maybe more?) |
Fixed, thanks for noticing. |
|
@ofborg build perlPackages.XMLLibXML |
|
Rebased to fix merge conflict. |
| # It seems there is a bug in GCC 5 | ||
| #"CFLAGS=$EXTRA_FLAGS $EXTRA_LDFLAGS" | ||
| #"CXXFLAGS=$EXTRA_FLAGS $EXTRA_LDFLAGS" |
There was a problem hiding this comment.
This has been commented since it's introduction in 2017 d4595b3#diff-7e60bf21d59f0d31c6d1a2c867692b9bcbad6dc8d8611e06e2e7bb91a9e07877R116-R118
Please review the commits in this PR separately, ignoring whitespace.
If you read them that way, most of them are trivial. You can skip the first six commits, which are from this PR (merged to
masterbut has not yet reachedstaging):Description of changes
This PR causes our gcc expressions (all 10 of them) to use the standard builder instead of their own custom
builder.sh.This PR deliberately does the minimum amount possible to achieve that, because it is likely to merge-conflict with almost any other PR which touches any version of GCC. Most of the commits in this PR are simple, repeatable operations (like search and replace) to try to make it easier to rebase them past any conflicts.
Most of the benefits of this PR will be realized in future PRs (see the last few commits of #238069)
Future Benefits
gcc/builder.shcauses a mass rebuild of every package on every platform. This is crazy.staging.builder.sh; see the gymnastics with "extra fixup phases" I had to add tolibgcc.nix. Those will go away.And, ultimately the big long-term benefit:
gccexpression should look like ourboostandnixexpressions, usinglib.versionswhen it is necessary to set minimum versions for things like patch applicability or configure flags.Things done
gcc48,gcc49,gcc6,gcc7,gcc8,gcc9,gcc10,gcc11,gcc12,gcc13x86_64-linux): in progresssandbox = 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/)