Attention is currently required from: Felix Singer, Martin L Roth.

Patrick Georgi has uploaded this change for review.

View Change

Ensure that compiler options for the target don't affect bootstrap

GCC_OPTIONS is only used for target specific options right now,
so rename to TARGET_GCC_OPTIONS and only use them in the
non-bootstrap build.

Adapt BINUTILS_OPTIONS for consistency, even though it doesn't
have the same problem.

Change-Id: I5e4f54b758dd7daf4e69101c19dfa1212fa64cf6
Signed-off-by: Patrick Georgi <patrick@georgi.software>
---
M util/crossgcc/buildgcc
1 file changed, 4 insertions(+), 3 deletions(-)

git pull ssh://review.coreboot.org:29418/coreboot refs/changes/29/80229/1
diff --git a/util/crossgcc/buildgcc b/util/crossgcc/buildgcc
index 23a5caf..b294da5 100755
--- a/util/crossgcc/buildgcc
+++ b/util/crossgcc/buildgcc
@@ -722,7 +722,7 @@
--enable-multilib \
--disable-docs \
--disable-texinfo \
- ${BINUTILS_OPTIONS} \
+ ${TARGET_BINUTILS_OPTIONS} \
CFLAGS="$HOSTCFLAGS" \
CXXFLAGS="$HOSTCFLAGS" || touch .failed
# shellcheck disable=SC2086
@@ -811,6 +811,7 @@
--disable-libcc1 \
--disable-decimal-float \
${GCC_OPTIONS} \
+ ${TARGET_GCC_OPTIONS} \
--enable-languages="${LANGUAGES}" \
--with-system-zlib \
--with-gmp="$DESTDIR$TARGETDIR" \
@@ -995,8 +996,8 @@
i386-elf) ;;
i386-mingw32) ;;
riscv-elf) TARGETARCH=riscv64-elf
- GCC_OPTIONS="$GCC_OPTIONS --with-isa-spec=20191213"
- BINUTILS_OPTIONS="$BINUTILS_OPTIONS --with-isa-spec=20191213";;
+ TARGET_GCC_OPTIONS="$TARGET_GCC_OPTIONS --with-isa-spec=20191213"
+ TARGET_BINUTILS_OPTIONS="$TARGET_BINUTILS_OPTIONS --with-isa-spec=20191213";;
powerpc64*-linux*) ;;
i386*) TARGETARCH=i386-elf;;
arm*) TARGETARCH=arm-eabi;;

To view, visit change 80229. To unsubscribe, or for help writing mail filters, visit settings.

Gerrit-Project: coreboot
Gerrit-Branch: main
Gerrit-Change-Id: I5e4f54b758dd7daf4e69101c19dfa1212fa64cf6
Gerrit-Change-Number: 80229
Gerrit-PatchSet: 1
Gerrit-Owner: Patrick Georgi <patrick@coreboot.org>
Gerrit-Reviewer: Felix Singer <service+coreboot-gerrit@felixsinger.de>
Gerrit-Reviewer: Martin L Roth <gaumless@gmail.com>
Gerrit-Attention: Felix Singer <service+coreboot-gerrit@felixsinger.de>
Gerrit-Attention: Martin L Roth <gaumless@gmail.com>
Gerrit-MessageType: newchange