stdenv: fix custom hardening settings when using __structuredAttrs = true;
(#353142)
This commit is contained in:
commit
a3071731e9
@ -413,7 +413,7 @@ else let
|
||||
enableParallelChecking = attrs.enableParallelChecking or true;
|
||||
enableParallelInstalling = attrs.enableParallelInstalling or true;
|
||||
} // optionalAttrs (hardeningDisable != [] || hardeningEnable != [] || stdenv.hostPlatform.isMusl) {
|
||||
NIX_HARDENING_ENABLE = enabledHardeningOptions;
|
||||
NIX_HARDENING_ENABLE = builtins.concatStringsSep " " enabledHardeningOptions;
|
||||
} // optionalAttrs (stdenv.hostPlatform.isx86_64 && stdenv.hostPlatform ? gcc.arch) {
|
||||
requiredSystemFeatures = attrs.requiredSystemFeatures or [] ++ [ "gccarch-${stdenv.hostPlatform.gcc.arch}" ];
|
||||
} // optionalAttrs (stdenv.buildPlatform.isDarwin) (
|
||||
|
@ -178,6 +178,13 @@ in nameDrvAfterAttrName ({
|
||||
ignorePie = false;
|
||||
});
|
||||
|
||||
pieExplicitEnabledStructuredAttrs = brokenIf stdenv.hostPlatform.isStatic (checkTestBin (f2exampleWithStdEnv stdenv {
|
||||
hardeningEnable = [ "pie" ];
|
||||
__structuredAttrs = true;
|
||||
}) {
|
||||
ignorePie = false;
|
||||
});
|
||||
|
||||
relROExplicitEnabled = checkTestBin (f2exampleWithStdEnv stdenv {
|
||||
hardeningEnable = [ "relro" ];
|
||||
}) {
|
||||
|
Loading…
Reference in New Issue
Block a user