diff options
author | sternenseemann <0rpkxez4ksa01gb3typccl0i@systemli.org> | 2021-05-17 23:50:16 +0200 |
---|---|---|
committer | sternenseemann <0rpkxez4ksa01gb3typccl0i@systemli.org> | 2021-05-18 00:16:54 +0200 |
commit | 2d176b593b731436b4310a74c226775a16d6dee2 (patch) | |
tree | 319bfe0bd9e3dd1d31eefa0014158bbeef54d237 /pkgs/development/compilers/gcc/6/default.nix | |
parent | 8c6d8191436912231312b7b12f0cefc3fc7fb18a (diff) | |
download | nixpkgs-2d176b593b731436b4310a74c226775a16d6dee2.tar nixpkgs-2d176b593b731436b4310a74c226775a16d6dee2.tar.gz nixpkgs-2d176b593b731436b4310a74c226775a16d6dee2.tar.bz2 nixpkgs-2d176b593b731436b4310a74c226775a16d6dee2.tar.lz nixpkgs-2d176b593b731436b4310a74c226775a16d6dee2.tar.xz nixpkgs-2d176b593b731436b4310a74c226775a16d6dee2.tar.zst nixpkgs-2d176b593b731436b4310a74c226775a16d6dee2.zip |
gcc*: force building a cross compiler if host and target platform differ
gcc's configure system has the nasty habit (for us) of judging for itself if it is building a cross compiler (or cross compiling), but on the limited information of the build, host and target platforms' config which only contains a subset of the information we encode in `stdenv.*Platform`. The practical consequence was that prior to this change building `pkgsLLVM.buildPackages.gcc` actually fails because it refuses to use `--with-headers` with something it believes to not be a cross compiler. As a workaround we force the appropriate variable in the configure script to always be `yes` regardless of its own conditional check. At some point we probably should report this issue in some capacity, so future gcc versions don't force us into workarounds like this and acdc783418538f23cdfb671bc8fd4b1c076979bd.
Diffstat (limited to 'pkgs/development/compilers/gcc/6/default.nix')
-rw-r--r-- | pkgs/development/compilers/gcc/6/default.nix | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/pkgs/development/compilers/gcc/6/default.nix b/pkgs/development/compilers/gcc/6/default.nix index 32a4ad0dd09..069d9c18a62 100644 --- a/pkgs/development/compilers/gcc/6/default.nix +++ b/pkgs/development/compilers/gcc/6/default.nix @@ -232,7 +232,7 @@ stdenv.mkDerivation ({ preConfigure = import ../common/pre-configure.nix { inherit lib; - inherit version hostPlatform gnatboot langJava langAda langGo; + inherit version targetPlatform hostPlatform gnatboot langJava langAda langGo; }; dontDisableStatic = true; |