stdenv: linux: inherit nukeReferences through xgcc/stage2/stage3

nukeReferences was rebuilt at every stage where it appeared (xgcc, stage2,
stage3 — 3 redundant builds beyond stage1's initial build). It is used only
at build time (to scrub references from libidn2/libunistring at stage2),
never appears in the final stdenv's runtime closure, and its outputs are
not propagated into other final-closure derivations.

Adding it to the inherit list at xgcc, stage2, and stage3 collapses the
chain to a single stage1 build. Stage4 still produces its own nukeReferences
through the regular package set; that one is unused by the final stdenv.

Build-only dependency, so this is safe with respect to the
`disallowedRequisites` check on the final stdenv-linux.
This commit is contained in:
Aliaksandr 2026-05-14 06:59:50 +03:00
commit 4df3376569
No known key found for this signature in database
GPG key ID: CACB28BA93CE71A2

View file

@ -343,6 +343,7 @@ in
gnum4
perl
patchelf
nukeReferences
;
${localSystem.libc} = prevStage.${localSystem.libc};
gmp = super.gmp.override { cxx = false; };
@ -457,6 +458,7 @@ in
bison
texinfo
which
nukeReferences
;
# Avoids infinite recursion, as this is in the build-time dependencies of libc.
@ -565,6 +567,7 @@ in
libidn2
libunistring
libxcrypt
nukeReferences
;
# We build a special copy of libgmp which doesn't use libstdc++, because
# xgcc++'s libstdc++ references the bootstrap-files (which is what