From 682a90c011c3cfbf89ce7af06db92d999161056a Mon Sep 17 00:00:00 2001 From: Stefan Reinauer Date: Tue, 9 Jun 2015 14:59:58 -0700 Subject: buildgcc: enable biarch support for x86_64-elf With this change, the x86_64-elf-gcc can compile i386-elf binaries by specifying -m32. The patch against GCC is needed to enable building the 32bit libraries when building x86_64-elf-gcc Change-Id: Ic86a009eccfdf3e33a398bcdcc13b15c8dfc0d31 Signed-off-by: Stefan Reinauer Reviewed-on: http://review.coreboot.org/10497 Tested-by: build bot (Jenkins) Reviewed-by: Patrick Georgi --- util/crossgcc/buildgcc | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) (limited to 'util/crossgcc/buildgcc') diff --git a/util/crossgcc/buildgcc b/util/crossgcc/buildgcc index c27d62cd7f..0ab0a530e4 100755 --- a/util/crossgcc/buildgcc +++ b/util/crossgcc/buildgcc @@ -22,8 +22,8 @@ cd $(dirname $0) -CROSSGCC_DATE="June 9th, 2015" -CROSSGCC_VERSION="1.30" +CROSSGCC_DATE="June 17th, 2015" +CROSSGCC_VERSION="1.31" # default settings PACKAGE=GCC @@ -380,10 +380,13 @@ build_LIBELF() { } build_BINUTILS() { - # Now build binutils + if [ $TARGETARCH == "x86_64-elf" ]; then + ADDITIONALTARGET=",i386-elf" + fi CC="$CC" ../binutils-${BINUTILS_VERSION}/configure --prefix=$TARGETDIR \ - --target=${TARGETARCH} --disable-werror --disable-nls \ - --enable-lto --enable-gold --enable-plugins CFLAGS="$HOSTCFLAGS" || touch .failed + --target=${TARGETARCH} --enable-targets=${TARGETARCH}${ADDITIONALTARGET} \ + --disable-werror --disable-nls --enable-lto --enable-gold \ + --enable-plugins --enable-multilibs CFLAGS="$HOSTCFLAGS" || touch .failed $MAKE $JOBS || touch .failed $MAKE install DESTDIR=$DESTDIR || touch .failed } -- cgit v1.2.3