···1+This patch fixes interaction with Libtool.
2+See <http://thread.gmane.org/gmane.comp.gcc.patches/258777>, for details.
3+4+--- a/gcc/fortran/gfortranspec.cc
5++++ b/gcc/fortran/gfortranspec.cc
6+@@ -461,8 +461,15 @@ For more information about these matters, see the file named COPYING\n\n"));
7+ {
8+ fprintf (stderr, _("Driving:"));
9+ for (i = 0; i < g77_newargc; i++)
10++ {
11++ if (g77_new_decoded_options[i].opt_index == OPT_l)
12++ /* Make sure no white space is inserted after `-l'. */
13++ fprintf (stderr, " -l%s",
14++ g77_new_decoded_options[i].canonical_option[1]);
15++ else
16+ fprintf (stderr, " %s",
17+ g77_new_decoded_options[i].orig_option_with_args_text);
18++ }
19+ fprintf (stderr, "\n");
20+ }
···12522 gcc9Stdenv = overrideCC gccStdenv buildPackages.gcc9;
12523 gcc10Stdenv = overrideCC gccStdenv buildPackages.gcc10;
12524 gcc11Stdenv = overrideCC gccStdenv buildPackages.gcc11;
01252512526 # This is not intended for use in nixpkgs but for providing a faster-running
12527 # compiler to nixpkgs users by building gcc with reproducibility-breaking
···12717 isl = if !stdenv.isDarwin then isl_0_20 else null;
12718 }));
1271912720- gcc_latest = gcc11;
0000000000001272112722 # Use the same GCC version as the one from stdenv by default
12723 gfortran = wrapCC (gcc.cc.override {
···12792 profiledCompiler = false;
12793 });
127940000000012795 libgccjit = gcc.cc.override {
12796 name = "libgccjit";
12797 langFortran = false;
···12879 && stdenv.buildPlatform == stdenv.hostPlatform
12880 then buildPackages.gnat6
12881 else buildPackages.gnat11;
000000000000000012882 });
1288312884 gnatboot = wrapCC (callPackage ../development/compilers/gnatboot { });
···12522 gcc9Stdenv = overrideCC gccStdenv buildPackages.gcc9;
12523 gcc10Stdenv = overrideCC gccStdenv buildPackages.gcc10;
12524 gcc11Stdenv = overrideCC gccStdenv buildPackages.gcc11;
12525+ gcc12Stdenv = overrideCC gccStdenv buildPackages.gcc12;
1252612527 # This is not intended for use in nixpkgs but for providing a faster-running
12528 # compiler to nixpkgs users by building gcc with reproducibility-breaking
···12718 isl = if !stdenv.isDarwin then isl_0_20 else null;
12719 }));
1272012721+ gcc12 = lowPrio (wrapCC (callPackage ../development/compilers/gcc/12 {
12722+ inherit noSysDirs;
12723+12724+ reproducibleBuild = true;
12725+ profiledCompiler = false;
12726+12727+ libcCross = if stdenv.targetPlatform != stdenv.buildPlatform then libcCross else null;
12728+ threadsCross = if stdenv.targetPlatform != stdenv.buildPlatform then threadsCross else null;
12729+12730+ isl = if !stdenv.isDarwin then isl_0_20 else null;
12731+ }));
12732+12733+ gcc_latest = gcc12;
1273412735 # Use the same GCC version as the one from stdenv by default
12736 gfortran = wrapCC (gcc.cc.override {
···12805 profiledCompiler = false;
12806 });
1280712808+ gfortran12 = wrapCC (gcc12.cc.override {
12809+ name = "gfortran";
12810+ langFortran = true;
12811+ langCC = false;
12812+ langC = false;
12813+ profiledCompiler = false;
12814+ });
12815+12816 libgccjit = gcc.cc.override {
12817 name = "libgccjit";
12818 langFortran = false;
···12900 && stdenv.buildPlatform == stdenv.hostPlatform
12901 then buildPackages.gnat6
12902 else buildPackages.gnat11;
12903+ });
12904+12905+ gnat12 = wrapCC (gcc12.cc.override {
12906+ name = "gnat";
12907+ langC = true;
12908+ langCC = false;
12909+ langAda = true;
12910+ profiledCompiler = false;
12911+ # As per upstream instructions building a cross compiler
12912+ # should be done with a (native) compiler of the same version.
12913+ # If we are cross-compiling GNAT, we may as well do the same.
12914+ gnatboot =
12915+ if stdenv.hostPlatform == stdenv.targetPlatform
12916+ && stdenv.buildPlatform == stdenv.hostPlatform
12917+ then buildPackages.gnat6
12918+ else buildPackages.gnat12;
12919 });
1292012921 gnatboot = wrapCC (callPackage ../development/compilers/gnatboot { });