diff options
author | John Ericson <John.Ericson@Obsidian.Systems> | 2018-05-11 14:33:12 -0400 |
---|---|---|
committer | John Ericson <John.Ericson@Obsidian.Systems> | 2018-05-11 14:36:08 -0400 |
commit | ee4b56edd364922c6a20a8d7b21a5a72497b4bc2 (patch) | |
tree | 42bd2a09efe21aa446e411201d4974d39f8a8a4f /pkgs/development/libraries/glibc | |
parent | 73833ee4465369c9eead8e00ce699053e010de2f (diff) | |
parent | 62ee7b7b4713c90048ec7063ca4f4cd7677eeb53 (diff) |
Merge remote-tracking branch 'upstream/master' into staging
Diffstat (limited to 'pkgs/development/libraries/glibc')
-rw-r--r-- | pkgs/development/libraries/glibc/common.nix | 17 |
1 files changed, 7 insertions, 10 deletions
diff --git a/pkgs/development/libraries/glibc/common.nix b/pkgs/development/libraries/glibc/common.nix index af006bdb4cf44..5c504d0d8e25f 100644 --- a/pkgs/development/libraries/glibc/common.nix +++ b/pkgs/development/libraries/glibc/common.nix @@ -39,7 +39,6 @@ let version = "2.27"; patchSuffix = ""; sha256 = "0wpwq7gsm7sd6ysidv0z575ckqdg13cr2njyfgrbgh4f65adwwji"; - cross = if buildPlatform != hostPlatform then hostPlatform else null; in assert withLinuxHeaders -> linuxHeaders != null; @@ -49,9 +48,6 @@ stdenv.mkDerivation ({ inherit version installLocales; linuxHeaders = if withLinuxHeaders then linuxHeaders else null; - # The host/target system. - crossConfig = if cross != null then cross.config else null; - inherit (stdenv) is64bit; enableParallelBuilding = true; @@ -123,11 +119,12 @@ stdenv.mkDerivation ({ else "--disable-profile") ] ++ lib.optionals withLinuxHeaders [ "--enable-kernel=3.2.0" # can't get below with glibc >= 2.26 - ] ++ lib.optionals (cross != null) [ - (if cross ? float && cross.float == "soft" then "--without-fp" else "--with-fp") - ] ++ lib.optionals (cross != null) [ + ] ++ lib.optionals (hostPlatform != buildPlatform) [ + (if hostPlatform.platform.gcc.float or (hostPlatform.parsed.abi.float or "hard") == "soft" + then "--without-fp" + else "--with-fp") "--with-__thread" - ] ++ lib.optionals (cross == null && stdenv.isAarch32) [ + ] ++ lib.optionals (hostPlatform == buildPlatform && hostPlatform.isAarch32) [ "--host=arm-linux-gnueabi" "--build=arm-linux-gnueabi" @@ -179,7 +176,7 @@ stdenv.mkDerivation ({ } - '' + lib.optionalString (cross != null) '' + '' + lib.optionalString (hostPlatform != buildPlatform) '' sed -i s/-lgcc_eh//g "../$sourceRoot/Makeconfig" cat > config.cache << "EOF" @@ -213,7 +210,7 @@ stdenv.mkDerivation ({ } // meta; } -// lib.optionalAttrs (cross != null) { +// lib.optionalAttrs (hostPlatform != buildPlatform) { preInstall = null; # clobber the native hook dontStrip = true; |