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