2005-04-22 14:14:55 +02:00
|
|
|
{ stdenv, fetchurl, noSysDirs
|
2009-04-09 17:24:33 +02:00
|
|
|
, langC ? true, langCC ? true, langFortran ? false
|
2005-04-22 14:14:55 +02:00
|
|
|
, profiledCompiler ? false
|
2008-02-21 16:34:56 +01:00
|
|
|
, gmp ? null , mpfr ? null
|
|
|
|
, texinfo ? null
|
2009-04-09 17:24:33 +02:00
|
|
|
, name ? "gcc"
|
2005-04-22 14:14:55 +02:00
|
|
|
}:
|
|
|
|
|
|
|
|
assert langC;
|
|
|
|
|
2007-08-07 14:05:10 +02:00
|
|
|
with import ../../../lib;
|
|
|
|
|
2005-04-22 14:14:55 +02:00
|
|
|
stdenv.mkDerivation {
|
2009-04-09 17:24:33 +02:00
|
|
|
name = "${name}-4.0.4";
|
|
|
|
|
2005-04-22 14:14:55 +02:00
|
|
|
builder = ./builder.sh;
|
2009-04-09 17:24:33 +02:00
|
|
|
|
2005-04-22 14:14:55 +02:00
|
|
|
src = fetchurl {
|
2007-08-07 14:05:10 +02:00
|
|
|
url = ftp://ftp.nluug.nl/mirror/languages/gcc/releases/gcc-4.0.4/gcc-4.0.4.tar.bz2;
|
|
|
|
sha256 = "0izwr8d69ld3a1yr8z94s7y7k861wi613mplys2c0bvdr58y1zgk";
|
2005-04-22 14:14:55 +02:00
|
|
|
};
|
2007-08-07 14:05:10 +02:00
|
|
|
|
|
|
|
patches =
|
|
|
|
optional noSysDirs [./no-sys-dirs.patch];
|
|
|
|
|
2009-04-09 17:24:33 +02:00
|
|
|
inherit noSysDirs langC langCC langFortran profiledCompiler;
|
2006-03-10 17:12:46 +01:00
|
|
|
|
2008-02-21 18:34:03 +01:00
|
|
|
buildInputs = [gmp mpfr texinfo];
|
2007-10-28 21:19:43 +01:00
|
|
|
|
2007-08-07 14:05:10 +02:00
|
|
|
configureFlags = "
|
|
|
|
--disable-multilib
|
|
|
|
--disable-libstdcxx-pch
|
|
|
|
--disable-libmudflap
|
|
|
|
--with-system-zlib
|
|
|
|
--enable-languages=${
|
|
|
|
concatStrings (intersperse ","
|
2009-04-09 17:24:33 +02:00
|
|
|
( optional langC "c"
|
|
|
|
++ optional langCC "c++"
|
|
|
|
++ optional langFortran "f95"
|
2007-08-07 14:05:10 +02:00
|
|
|
)
|
|
|
|
)
|
|
|
|
}
|
|
|
|
${if stdenv.isi686 then "--with-arch=i686" else ""}
|
|
|
|
";
|
|
|
|
|
2006-03-10 17:12:46 +01:00
|
|
|
meta = {
|
|
|
|
homepage = "http://gcc.gnu.org/";
|
|
|
|
license = "GPL/LGPL";
|
|
|
|
description = "GNU Compiler Collection, 4.0.x";
|
|
|
|
};
|
2005-04-22 14:14:55 +02:00
|
|
|
}
|