Merge pull request #120283 from Ericson2314/netbsd-fewer-vars

netbsd: Remove some env vars that are probably not needed.

authored by John Ericson and committed by GitHub 96b2cb44 5640a6dc

+6 -11
+4 -9
pkgs/os-specific/bsd/netbsd/default.nix
··· 63 63 ]; 64 64 buildInputs = with self; compatIfNeeded; 65 65 66 - OBJCOPY = if stdenv.isDarwin then "true" else "objcopy"; 67 - HOST_SH = "${buildPackages.bash}/bin/sh"; 66 + HOST_SH = stdenv'.shell; 68 67 69 68 MACHINE_ARCH = { 70 69 i686 = "i386"; ··· 78 77 }.${stdenv'.hostPlatform.parsed.cpu.name} 79 78 or stdenv'.hostPlatform.parsed.cpu.name; 80 79 81 - AR = "${stdenv'.cc.targetPrefix or ""}ar"; 82 - CC = "${stdenv'.cc.targetPrefix or ""}cc"; 83 - CPP = "${stdenv'.cc.targetPrefix or ""}cpp"; 84 - CXX = "${stdenv'.cc.targetPrefix or ""}c++"; 85 - LD = "${stdenv'.cc.targetPrefix or ""}ld"; 86 - STRIP = "${stdenv'.cc.targetPrefix or ""}strip"; 87 - 88 80 BSD_PATH = attrs.path; 89 81 90 82 strictDeps = true; ··· 94 86 platforms = platforms.unix; 95 87 license = licenses.bsd2; 96 88 }; 89 + } // lib.optionalAttrs stdenv'.hasCC { 90 + # TODO should CC wrapper set this? 91 + CPP = "${stdenv'.cc.targetPrefix}cpp"; 97 92 } // lib.optionalAttrs stdenv'.isDarwin { 98 93 MKRELRO = "no"; 99 94 } // lib.optionalAttrs (stdenv'.cc.isClang or false) {
+1 -1
pkgs/stdenv/generic/make-derivation.nix
··· 104 104 ++ depsHostHost ++ depsHostHostPropagated 105 105 ++ buildInputs ++ propagatedBuildInputs 106 106 ++ depsTargetTarget ++ depsTargetTargetPropagated) == 0; 107 - dontAddHostSuffix = attrs ? outputHash && !noNonNativeDeps || (stdenv.noCC or false); 107 + dontAddHostSuffix = attrs ? outputHash && !noNonNativeDeps || !stdenv.hasCC; 108 108 supportedHardeningFlags = [ "fortify" "stackprotector" "pie" "pic" "strictoverflow" "format" "relro" "bindnow" ]; 109 109 # Musl-based platforms will keep "pie", other platforms will not. 110 110 defaultHardeningFlags = if stdenv.hostPlatform.isMusl &&
+1 -1
pkgs/top-level/all-packages.nix
··· 30 30 # just the plain stdenv. 31 31 stdenv_32bit = lowPrio (if stdenv.hostPlatform.is32bit then stdenv else multiStdenv); 32 32 33 - stdenvNoCC = stdenv.override { cc = null; extraAttrs.noCC = true; }; 33 + stdenvNoCC = stdenv.override { cc = null; hasCC = false; }; 34 34 35 35 mkStdenvNoLibs = stdenv: let 36 36 bintools = stdenv.cc.bintools.override {