summaryrefslogtreecommitdiff
path: root/strata/build-essential/stage2-binutils.morph
diff options
context:
space:
mode:
authorTiago Gomes <tiago.gomes@codethink.co.uk>2015-01-26 16:22:47 +0000
committerTiago Gomes <tiago.gomes@codethink.co.uk>2015-01-26 16:22:47 +0000
commit40cff71921b8e20e6fdefd41560e89067ba21483 (patch)
treee27a743c39a22b9ef0e76824c4a2c008d25c33d1 /strata/build-essential/stage2-binutils.morph
parenteaf31937a6c16adac30e5c8ba71d457336b5df0d (diff)
parent941c6a9653c784962aab1579ff066d7a274e8d84 (diff)
downloaddefinitions-40cff71921b8e20e6fdefd41560e89067ba21483.tar.gz
Merge branch 'baserock/tiagogomes/update-toolchain-v2'
Reviewed by: * Sam Thursfield * Paul Sherwood * Josh Malkinson
Diffstat (limited to 'strata/build-essential/stage2-binutils.morph')
-rw-r--r--strata/build-essential/stage2-binutils.morph11
1 files changed, 4 insertions, 7 deletions
diff --git a/strata/build-essential/stage2-binutils.morph b/strata/build-essential/stage2-binutils.morph
index bc0b18ac..1c64fb29 100644
--- a/strata/build-essential/stage2-binutils.morph
+++ b/strata/build-essential/stage2-binutils.morph
@@ -5,20 +5,17 @@ build-system: autotools
configure-commands:
- |
export STAGE2_SYSROOT="$(dirname $(pwd))"
- export CPPFLAGS="--sysroot=$STAGE2_SYSROOT"
export CXX=false
- export LDFLAGS="-Wl,--sysroot=$STAGE2_SYSROOT"
+ # binutils has its own embedded libtool, which is old and strips out
+ # `--sysroot`. Work around by modifying the compiler command to
+ # include the sysroot flag
+ export CC="$TARGET_STAGE1-gcc --sysroot=$STAGE2_SYSROOT"
./configure --prefix="$PREFIX" --disable-nls --disable-werror \
--build=$(sh config.guess) \
--host=$TARGET_STAGE1 \
--target=$TARGET_STAGE1
build-commands:
-# Nested configure scripts require that we set CPPFLAGS here as well
-# (I don't think we should have to .. . at least in GCC, I think
-# TARGET_CPPFLAGS may be the answer)
- |
export STAGE2_SYSROOT="$(dirname $(pwd))"
- export CPPFLAGS="--sysroot=$STAGE2_SYSROOT"
- export LDFLAGS="-Wl,--sysroot=$STAGE2_SYSROOT"
make