diff options
author | Daiderd Jordan <daiderd@gmail.com> | 2018-01-26 23:40:40 +0100 |
---|---|---|
committer | John Ericson <John.Ericson@Obsidian.Systems> | 2018-10-23 23:20:42 -0400 |
commit | ab6bbdd5cd2a271ac795f1f44a94f77e41edf29f (patch) | |
tree | a6726593f0f08195af1274cb9ad4552bea53acf5 /pkgs/development/libraries/glibc | |
parent | 88cd633ea4dec7b9a247c0fd8ccb95f4982f5bf7 (diff) |
linux-headers: Fix Darwin cross build
Carefully fake cc-version and cc-fullversion to avoid needing a compiler for the kernel itself to build the headers. For some reason, doing `make install_headers` twice, first without INSTALL_HDR_PATH=$out then with, is neccessary to get this to work.
Diffstat (limited to 'pkgs/development/libraries/glibc')
-rw-r--r-- | pkgs/development/libraries/glibc/common.nix | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/pkgs/development/libraries/glibc/common.nix b/pkgs/development/libraries/glibc/common.nix index a7a4c2fbacdb4..b77c450bdec1f 100644 --- a/pkgs/development/libraries/glibc/common.nix +++ b/pkgs/development/libraries/glibc/common.nix @@ -133,7 +133,9 @@ stdenv.mkDerivation ({ depsBuildBuild = [ buildPackages.stdenv.cc ]; nativeBuildInputs = [ bison ]; - buildInputs = lib.optionals withGd [ gd libpng ]; + # TODO make linuxHeaders unconditional next mass rebuild + buildInputs = lib.optional (stdenv.hostPlatform != stdenv.buildPlatform) linuxHeaders + ++ lib.optionals withGd [ gd libpng ]; # Needed to install share/zoneinfo/zone.tab. Set to impure /bin/sh to # prevent a retained dependency on the bootstrap tools in the stdenv-linux |