summaryrefslogtreecommitdiff
path: root/eclass
diff options
context:
space:
mode:
authorSam James <sam@gentoo.org>2024-02-03 14:04:08 +0000
committerSam James <sam@gentoo.org>2024-02-03 14:06:40 +0000
commit2add8e9e5a9a837954f6cc4dbbbe72f448b636a8 (patch)
tree1c30fdf6b5bc4b7f92b182b1c2679c3495c3e715 /eclass
parentdev-python/mpi4py: Stabilize 3.1.5 amd64, #923698 (diff)
downloadgentoo-2add8e9e5a9a837954f6cc4dbbbe72f448b636a8.tar.gz
gentoo-2add8e9e5a9a837954f6cc4dbbbe72f448b636a8.tar.bz2
gentoo-2add8e9e5a9a837954f6cc4dbbbe72f448b636a8.zip
toolchain.eclass: don't take shortcut for non-GCC bootstrap compiler
We're fragile for stage0 so if we're not building using GCC, use -O0. The use of regular CFLAGS/CXXFLAGS there should be seen as a bonus as it has some caveats. Best to play it safe to avoid confusing hard-to-diagnose differences later on. Signed-off-by: Sam James <sam@gentoo.org>
Diffstat (limited to 'eclass')
-rw-r--r--eclass/toolchain.eclass2
1 files changed, 1 insertions, 1 deletions
diff --git a/eclass/toolchain.eclass b/eclass/toolchain.eclass
index 1679a3d3a366..4cf76229cf88 100644
--- a/eclass/toolchain.eclass
+++ b/eclass/toolchain.eclass
@@ -1712,7 +1712,7 @@ gcc_do_make() {
# The last known issues are with < GCC 4.9 or so, but it's easier
# to keep this bound somewhat fresh just to avoid problems. Ultimately,
# using not-O0 is just a build-time speed improvement anyway.
- if tc-is-gcc && ver_test $(gcc-fullversion) -lt 10 ; then
+ if ! tc-is-gcc || ver_test $(gcc-fullversion) -lt 10 ; then
STAGE1_CFLAGS="-O0"
fi