stdenv: set enableParallelBuilding explicitly if enableParallelBuildingByDefault is set

Without the change we don't propagate `enableParallelBuilding = true`
and leave most builds sequential.

Noticed on `mythtv` package which did not specify parallelism and
`config.enableParallelBuildingByDefault = true` had no effect.
This commit is contained in:
Sergei Trofimovich 2022-12-17 22:21:07 +00:00
parent 887e342eaa
commit 428107f837

View file

@ -418,6 +418,7 @@ else let
outputHashAlgo = attrs.outputHashAlgo or "sha256"; outputHashAlgo = attrs.outputHashAlgo or "sha256";
outputHashMode = attrs.outputHashMode or "recursive"; outputHashMode = attrs.outputHashMode or "recursive";
} // lib.optionalAttrs (enableParallelBuilding) { } // lib.optionalAttrs (enableParallelBuilding) {
inherit enableParallelBuilding;
enableParallelChecking = attrs.enableParallelChecking or true; enableParallelChecking = attrs.enableParallelChecking or true;
} // lib.optionalAttrs (hardeningDisable != [] || hardeningEnable != [] || stdenv.hostPlatform.isMusl) { } // lib.optionalAttrs (hardeningDisable != [] || hardeningEnable != [] || stdenv.hostPlatform.isMusl) {
NIX_HARDENING_ENABLE = enabledHardeningOptions; NIX_HARDENING_ENABLE = enabledHardeningOptions;