{cc,bintools}-wrapper: also replace . in config

Some configs will have dots for version numbers. To normalize we can
just use _ again.

authored by

Matthew Bauer and committed by
Matthew Bauer
96ce1e03 82f3cd63

+2 -6
+1 -3
pkgs/build-support/bintools-wrapper/default.nix
··· 43 43 # The wrapper scripts use 'cat' and 'grep', so we may need coreutils. 44 44 coreutils_bin = if nativeTools then "" else getBin coreutils; 45 45 46 - dashlessTarget = stdenv.lib.replaceStrings ["-"] ["_"] targetPlatform.config; 47 - 48 46 # See description in cc-wrapper. 49 - infixSalt = dashlessTarget; 47 + infixSalt = replaceStrings ["-" "."] ["_" "_"] targetPlatform.config; 50 48 51 49 # The dynamic linker has different names on different platforms. This is a 52 50 # shell glob that ought to match it.
+1 -3
pkgs/build-support/cc-wrapper/default.nix
··· 45 45 default_cxx_stdlib_compile = optionalString (targetPlatform.isLinux && !(cc.isGNU or false) && !nativeTools && cc ? gcc) 46 46 "-isystem $(echo -n ${cc.gcc}/include/c++/*) -isystem $(echo -n ${cc.gcc}/include/c++/*)/$(${cc.gcc}/bin/gcc -dumpmachine)"; 47 47 48 - dashlessTarget = stdenv.lib.replaceStrings ["-"] ["_"] targetPlatform.config; 49 - 50 48 # The "infix salt" is a arbitrary string added in the middle of env vars 51 49 # defined by cc-wrapper's hooks so that multiple cc-wrappers can be used 52 50 # without interfering. For the moment, it is defined as the target triple, 53 51 # adjusted to be a valid bash identifier. This should be considered an 54 52 # unstable implementation detail, however. 55 - infixSalt = dashlessTarget; 53 + infixSalt = replaceStrings ["-" "."] ["_" "_"] targetPlatform.config; 56 54 57 55 expand-response-params = 58 56 if buildPackages.stdenv.cc or null != null && buildPackages.stdenv.cc != "/dev/null"