diff options
author | John Ericson <Ericson2314@Yahoo.com> | 2017-05-18 06:55:08 -0400 |
---|---|---|
committer | John Ericson <Ericson2314@Yahoo.com> | 2017-05-20 22:17:28 -0400 |
commit | 25edc476fd9fe1bd8bedf571d218ba4f27fb5a27 (patch) | |
tree | dca0f0e35b395278e4b7963d6124439b9b9c5eaf /pkgs/development/libraries/glibc/default.nix | |
parent | 7e096024d7cf0ea1ca2a0d0d79d33d3f3e4e9965 (diff) | |
download | nixlib-25edc476fd9fe1bd8bedf571d218ba4f27fb5a27.tar nixlib-25edc476fd9fe1bd8bedf571d218ba4f27fb5a27.tar.gz nixlib-25edc476fd9fe1bd8bedf571d218ba4f27fb5a27.tar.bz2 nixlib-25edc476fd9fe1bd8bedf571d218ba4f27fb5a27.tar.lz nixlib-25edc476fd9fe1bd8bedf571d218ba4f27fb5a27.tar.xz nixlib-25edc476fd9fe1bd8bedf571d218ba4f27fb5a27.tar.zst nixlib-25edc476fd9fe1bd8bedf571d218ba4f27fb5a27.zip |
glibc: Simplify derivation further
No native hashes should be changed with this commit default.nix's cross hash should also not be changed
Diffstat (limited to 'pkgs/development/libraries/glibc/default.nix')
-rw-r--r-- | pkgs/development/libraries/glibc/default.nix | 52 |
1 files changed, 6 insertions, 46 deletions
diff --git a/pkgs/development/libraries/glibc/default.nix b/pkgs/development/libraries/glibc/default.nix index 7295e4d62f4f..976dbcde47ff 100644 --- a/pkgs/development/libraries/glibc/default.nix +++ b/pkgs/development/libraries/glibc/default.nix @@ -1,23 +1,16 @@ -{ lib, stdenv, fetchurl +{ stdenv, callPackage +, withLinuxHeaders ? true , installLocales ? true , profilingLibraries ? false -, withGd ? false, gd ? null, libpng ? null -, buildPlatform, hostPlatform -, buildPackages +, withGd ? false }: assert stdenv.cc.isGNU; -let - build = import ./common.nix; - cross = if buildPlatform != hostPlatform then hostPlatform else null; - inherit (buildPackages) linuxHeaders; -in - build cross ({ - name = "glibc" + lib.optionalString withGd "-gd"; +callPackage ./common.nix { inherit stdenv; } { + name = "glibc" + stdenv.lib.optionalString withGd "-gd"; - inherit lib stdenv buildPackages fetchurl linuxHeaders installLocales - profilingLibraries withGd gd libpng; + inherit withLinuxHeaders profilingLibraries installLocales withGd; NIX_NO_SELF_RPATH = true; @@ -106,36 +99,3 @@ in meta.description = "The GNU C Library"; } - - // - - (if cross != null - then { - preConfigure = '' - sed -i s/-lgcc_eh//g "../$sourceRoot/Makeconfig" - - cat > config.cache << "EOF" - libc_cv_forced_unwind=yes - libc_cv_c_cleanup=yes - libc_cv_gnu89_inline=yes - # Only due to a problem in gcc configure scripts: - libc_cv_sparc64_tls=${if cross.withTLS then "yes" else "no"} - EOF - export BUILD_CC=gcc - export CC="$crossConfig-gcc" - export AR="$crossConfig-ar" - export RANLIB="$crossConfig-ranlib" - - dontStrip=1 - ''; - - preInstall = null; # clobber the native hook - - separateDebugInfo = false; # this is currently broken for crossDrv - - # To avoid a dependency on the build system 'bash'. - preFixup = '' - rm $bin/bin/{ldd,tzselect,catchsegv,xtrace} - ''; - } - else {})) |