diff options
author | Matthew Bauer <mjbauer95@gmail.com> | 2016-09-06 13:54:13 -0500 |
---|---|---|
committer | Matthew Bauer <mjbauer95@gmail.com> | 2016-09-15 17:56:50 -0500 |
commit | cf004ae56ee8261c9e5070e83ee14fc21f8e58d6 (patch) | |
tree | 9406bf642ac545b40cdf70bdca67c16d119f4901 /pkgs/development/compilers/gcc | |
parent | f2e753a90c3f7a9e715216501b9b0f95e766701f (diff) | |
download | nixlib-cf004ae56ee8261c9e5070e83ee14fc21f8e58d6.tar nixlib-cf004ae56ee8261c9e5070e83ee14fc21f8e58d6.tar.gz nixlib-cf004ae56ee8261c9e5070e83ee14fc21f8e58d6.tar.bz2 nixlib-cf004ae56ee8261c9e5070e83ee14fc21f8e58d6.tar.lz nixlib-cf004ae56ee8261c9e5070e83ee14fc21f8e58d6.tar.xz nixlib-cf004ae56ee8261c9e5070e83ee14fc21f8e58d6.tar.zst nixlib-cf004ae56ee8261c9e5070e83ee14fc21f8e58d6.zip |
gcc: add --with-native-system-header-dir for clang
gcc needs to be able find system headers. Without this, gcc fails to build because /usr/include is not available. Note: stdenv.libc should be available for all stdenv's, I think.
Diffstat (limited to 'pkgs/development/compilers/gcc')
-rw-r--r-- | pkgs/development/compilers/gcc/4.8/default.nix | 4 | ||||
-rw-r--r-- | pkgs/development/compilers/gcc/4.9/default.nix | 4 | ||||
-rw-r--r-- | pkgs/development/compilers/gcc/5/default.nix | 4 | ||||
-rw-r--r-- | pkgs/development/compilers/gcc/6/default.nix | 4 |
4 files changed, 8 insertions, 8 deletions
diff --git a/pkgs/development/compilers/gcc/4.8/default.nix b/pkgs/development/compilers/gcc/4.8/default.nix index cf06fe9567e6..1b9e4bf666cf 100644 --- a/pkgs/development/compilers/gcc/4.8/default.nix +++ b/pkgs/development/compilers/gcc/4.8/default.nix @@ -357,8 +357,8 @@ stdenv.mkDerivation ({ ) ) } - ${if (stdenv ? glibc && cross == null) - then " --with-native-system-header-dir=${stdenv.glibc.dev}/include" + ${if cross == null + then " --with-native-system-header-dir=${getDev stdenv.libc}/include" else ""} ${if langAda then " --enable-libada" else ""} ${if cross == null && stdenv.isi686 then "--with-arch=i686" else ""} diff --git a/pkgs/development/compilers/gcc/4.9/default.nix b/pkgs/development/compilers/gcc/4.9/default.nix index a746b7e12b33..71edda0937f8 100644 --- a/pkgs/development/compilers/gcc/4.9/default.nix +++ b/pkgs/development/compilers/gcc/4.9/default.nix @@ -364,8 +364,8 @@ stdenv.mkDerivation ({ ) ) } - ${if (stdenv ? glibc && cross == null) - then " --with-native-system-header-dir=${stdenv.glibc.dev}/include" + ${if cross == null + then " --with-native-system-header-dir=${getDev stdenv.libc}/include" else ""} ${if langAda then " --enable-libada" else ""} ${if cross == null && stdenv.isi686 then "--with-arch=i686" else ""} diff --git a/pkgs/development/compilers/gcc/5/default.nix b/pkgs/development/compilers/gcc/5/default.nix index 6f8a32a7bfc0..e84c677408c3 100644 --- a/pkgs/development/compilers/gcc/5/default.nix +++ b/pkgs/development/compilers/gcc/5/default.nix @@ -362,8 +362,8 @@ stdenv.mkDerivation ({ ) ) } - ${if (stdenv ? glibc && cross == null) - then " --with-native-system-header-dir=${stdenv.glibc.dev}/include" + ${if cross == null + then " --with-native-system-header-dir=${getDev stdenv.libc}/include" else ""} ${if langAda then " --enable-libada" else ""} ${if cross == null && stdenv.isi686 then "--with-arch=i686" else ""} diff --git a/pkgs/development/compilers/gcc/6/default.nix b/pkgs/development/compilers/gcc/6/default.nix index 57172a2d9db9..b33437ee868c 100644 --- a/pkgs/development/compilers/gcc/6/default.nix +++ b/pkgs/development/compilers/gcc/6/default.nix @@ -360,8 +360,8 @@ stdenv.mkDerivation ({ ) ) } - ${if (stdenv ? glibc && cross == null) - then " --with-native-system-header-dir=${stdenv.glibc.dev}/include" + ${if cross == null + then " --with-native-system-header-dir=${getDev stdenv.libc}/include" else ""} ${if langAda then " --enable-libada" else ""} ${if cross == null && stdenv.isi686 then "--with-arch=i686" else ""} |