gcc47: moving the bootstrap logic into nix

It was in the builder.sh. Similar to the previous patch
to gcc46.
This commit is contained in:
Lluís Batlle i Rossell 2012-12-27 14:57:32 +00:00
parent e9365882c1
commit d05b33653e
2 changed files with 9 additions and 10 deletions

View File

@ -239,13 +239,4 @@ postInstall() {
eval "$postInstallGhdl"
}
if test -z "$targetConfig" && test -z "$crossConfig"; then
if test -z "$profiledCompiler"; then
buildFlags="bootstrap $buildFlags"
else
buildFlags="profiledbootstrap $buildFlags"
fi
fi
genericBuild

View File

@ -154,6 +154,8 @@ let version = "4.7.2";
"-stage-final";
crossNameAddon = if (cross != null) then "-${cross.config}" + stageNameAddon else "";
bootstrap = cross == null && !stdenv.isArm && !stdenv.isMips;
in
# We need all these X libraries when building AWT with GTK+.
@ -225,7 +227,7 @@ stdenv.mkDerivation ({
''
else null;
inherit noSysDirs profiledCompiler staticCompiler langJava crossStageStatic
inherit noSysDirs staticCompiler langJava crossStageStatic
libcCross crossMingw;
buildNativeInputs = [ texinfo which gettext ]
@ -299,10 +301,15 @@ stdenv.mkDerivation ({
${if langAda then " --enable-libada" else ""}
${if (cross == null && stdenv.isi686) then "--with-arch=i686" else ""}
${if cross != null then crossConfigureFlags else ""}
${if !bootstrap then "--disable-bootstrap" else ""}
";
targetConfig = if (cross != null) then cross.config else null;
buildFlags = if bootstrap then
(if profiledCompiler then "profiledbootstrap" else "bootstrap")
else "";
installTargets =
if stripped
then "install-strip"
@ -362,6 +369,7 @@ stdenv.mkDerivation ({
${xwithAbi}
${xwithFpu}
'';
buildFlags = "";
};