diff --git a/pkgs/build-support/bintools-wrapper/default.nix b/pkgs/build-support/bintools-wrapper/default.nix index 4a6457350102..868bc8cdae1f 100644 --- a/pkgs/build-support/bintools-wrapper/default.nix +++ b/pkgs/build-support/bintools-wrapper/default.nix @@ -108,7 +108,8 @@ let coreutils_bin = optionalString (!nativeTools) (getBin coreutils); # See description in cc-wrapper. - suffixSalt = replaceStrings ["-" "."] ["_" "_"] targetPlatform.config; + suffixSalt = replaceStrings ["-" "."] ["_" "_"] targetPlatform.config + + lib.optionalString (targetPlatform.isDarwin && targetPlatform.isStatic) "_static"; # The dynamic linker has different names on different platforms. This is a # shell glob that ought to match it. diff --git a/pkgs/build-support/cc-wrapper/default.nix b/pkgs/build-support/cc-wrapper/default.nix index ed55e37cb76a..34b23acc80e3 100644 --- a/pkgs/build-support/cc-wrapper/default.nix +++ b/pkgs/build-support/cc-wrapper/default.nix @@ -115,7 +115,8 @@ let # without interfering. For the moment, it is defined as the target triple, # adjusted to be a valid bash identifier. This should be considered an # unstable implementation detail, however. - suffixSalt = replaceStrings ["-" "."] ["_" "_"] targetPlatform.config; + suffixSalt = replaceStrings ["-" "."] ["_" "_"] targetPlatform.config + + lib.optionalString (targetPlatform.isDarwin && targetPlatform.isStatic) "_static"; useGccForLibs = useCcForLibs && libcxx == null