make-derivation: try to fix stdenv.cc == null conditional

sometimes this gets an infinite recursion error
This commit is contained in:
Matthew Bauer 2019-01-28 10:00:10 -05:00
parent e20b65156c
commit 9fd1c170cc
2 changed files with 2 additions and 2 deletions

View File

@ -94,7 +94,7 @@ rec {
++ depsHostHost ++ depsHostHostPropagated ++ depsHostHost ++ depsHostHostPropagated
++ buildInputs ++ propagatedBuildInputs ++ buildInputs ++ propagatedBuildInputs
++ depsTargetTarget ++ depsTargetTargetPropagated) == 0; ++ depsTargetTarget ++ depsTargetTargetPropagated) == 0;
dontAddHostSuffix = attrs ? outputHash && !noNonNativeDeps || stdenv.cc == null; dontAddHostSuffix = attrs ? outputHash && !noNonNativeDeps || (stdenv.noCC or false);
supportedHardeningFlags = [ "fortify" "stackprotector" "pie" "pic" "strictoverflow" "format" "relro" "bindnow" ]; supportedHardeningFlags = [ "fortify" "stackprotector" "pie" "pic" "strictoverflow" "format" "relro" "bindnow" ];
defaultHardeningFlags = if stdenv.hostPlatform.isMusl defaultHardeningFlags = if stdenv.hostPlatform.isMusl
then supportedHardeningFlags then supportedHardeningFlags

View File

@ -33,7 +33,7 @@ in
# just the plain stdenv. # just the plain stdenv.
stdenv_32bit = lowPrio (if stdenv.hostPlatform.is32bit then stdenv else multiStdenv); stdenv_32bit = lowPrio (if stdenv.hostPlatform.is32bit then stdenv else multiStdenv);
stdenvNoCC = stdenv.override { cc = null; }; stdenvNoCC = stdenv.override { cc = null; extraAttrs.noCC = true; };
stdenvNoLibs = let stdenvNoLibs = let
bintools = stdenv.cc.bintools.override { bintools = stdenv.cc.bintools.override {