From d515f6a3e32426be6e355c005fb60987b94f2ea3 Mon Sep 17 00:00:00 2001 From: Sam Thursfield Date: Wed, 13 Mar 2013 15:39:43 +0000 Subject: Prevent build from using g++ from host machine Stage 1 does not build a C++ compiler, but autoconf configure scripts will happily use g++ from the host system instead. Force CXX=false to make sure that it doesn't try to build any C++ code. --- stage2-binutils.morph | 2 +- stage2-binutils.morph.yaml | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/stage2-binutils.morph b/stage2-binutils.morph index c38a37bb40..32351e1787 100644 --- a/stage2-binutils.morph +++ b/stage2-binutils.morph @@ -4,7 +4,7 @@ "build-system": "autotools", "configure-commands": [ "stage2-eglibc-fix-specs", - "export STAGE2_SYSROOT=\"$(dirname $(pwd))\"\nexport CPPFLAGS=\"--sysroot=$STAGE2_SYSROOT\"\nexport LDFLAGS=\"-Wl,--sysroot=$STAGE2_SYSROOT\"\n./configure --prefix=\"$PREFIX\" --disable-nls --disable-werror \\\n --build=$BUILD --host=$TARGET_STAGE1 --target=$TARGET_STAGE1 \\\n --with-lib-path=\"$PREFIX/lib\"\n" + "export STAGE2_SYSROOT=\"$(dirname $(pwd))\"\nexport CPPFLAGS=\"--sysroot=$STAGE2_SYSROOT\"\nexport CXX=false\nexport LDFLAGS=\"-Wl,--sysroot=$STAGE2_SYSROOT\"\n./configure --prefix=\"$PREFIX\" --disable-nls --disable-werror \\\n --build=$BUILD --host=$TARGET_STAGE1 --target=$TARGET_STAGE1 \\\n --with-lib-path=\"$PREFIX/lib\"\n" ], "build-commands": [ "export STAGE2_SYSROOT=\"$(dirname $(pwd))\"\nexport CPPFLAGS=\"--sysroot=$STAGE2_SYSROOT\"\nexport LDFLAGS=\"-Wl,--sysroot=$STAGE2_SYSROOT\"\nmake\n" diff --git a/stage2-binutils.morph.yaml b/stage2-binutils.morph.yaml index e3d56bc563..f0d8809875 100644 --- a/stage2-binutils.morph.yaml +++ b/stage2-binutils.morph.yaml @@ -8,6 +8,7 @@ configure-commands: - | export STAGE2_SYSROOT="$(dirname $(pwd))" export CPPFLAGS="--sysroot=$STAGE2_SYSROOT" + export CXX=false export LDFLAGS="-Wl,--sysroot=$STAGE2_SYSROOT" ./configure --prefix="$PREFIX" --disable-nls --disable-werror \ --build=$BUILD --host=$TARGET_STAGE1 --target=$TARGET_STAGE1 \ -- cgit v1.2.1