* Add an option to GCC to build a profiled compiler (which is about

5-10% faster).

svn path=/nixpkgs/trunk/; revision=1108
This commit is contained in:
Eelco Dolstra 2004-07-01 12:17:53 +00:00
parent 56fd464a72
commit d92fa0bf37
3 changed files with 8 additions and 2 deletions

View File

@ -67,6 +67,10 @@ preConfigure() {
preConfigure=preConfigure preConfigure=preConfigure
makeFlags="bootstrap" if test -z "$profiledCompiler"; then
makeFlags="bootstrap"
else
makeFlags="profiledbootstrap"
fi
genericBuild genericBuild

View File

@ -1,5 +1,6 @@
{ stdenv, fetchurl, patch, noSysDirs { stdenv, fetchurl, patch, noSysDirs
, langC ? true, langCC ? true, langF77 ? false , langC ? true, langCC ? true, langF77 ? false
, profiledCompiler ? false
}: }:
assert langC; assert langC;
@ -14,5 +15,5 @@ stdenv.mkDerivation {
# !!! apply only if noSysDirs is set # !!! apply only if noSysDirs is set
patches = [./no-sys-dirs.patch]; patches = [./no-sys-dirs.patch];
buildInputs = [patch]; buildInputs = [patch];
inherit noSysDirs langC langCC langF77; inherit noSysDirs langC langCC langF77 profiledCompiler;
} }

View File

@ -213,6 +213,7 @@ rec {
gcc = (import ../development/compilers/gcc-3.4) { gcc = (import ../development/compilers/gcc-3.4) {
inherit fetchurl stdenv noSysDirs; inherit fetchurl stdenv noSysDirs;
patch = gnupatch; patch = gnupatch;
profiledCompiler = true;
}; };
binutils = stdenv.gcc.binutils; binutils = stdenv.gcc.binutils;
glibc = stdenv.gcc.glibc; glibc = stdenv.gcc.glibc;