commit: 03138227aa0985a708bbb9ecf331baf06f75d5df
Author: Sergei Trofimovich <slyfox <AT> gentoo <DOT> org>
AuthorDate: Thu Sep 27 21:45:03 2018 +0000
Commit: Sergei Trofimovich <slyfox <AT> gentoo <DOT> org>
CommitDate: Thu Sep 27 22:26:32 2018 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=03138227
toolchain-funcs.eclass: softfloat detection, bug #666896
commit 921cb9c10de4d237924a61a1c27f914dfb479a64
"toolchain-funcs.eclass: Update tc-is-softfloat for new ARM tuples"
changed autodetection of mst 'arm*' targets from from 'no'
to 'yes'.
It is incorrect at least for bare-metal targets that tend
to pass their taget defaults.
Bug #666896 is one example example command:
# crossdev -s1 \
--env 'EXTRA_ECONF="--with-multilib-list=rmprofile"' \
arm-none-eabi
rmprofile one of special cases for gcc as it explicitky does
not myx with any arch-specific options and --with-float=soft
breaks it:
Error: You cannot use any of --with-arch/cpu/fpu/float/mode
with --with-multilib-list=rmprofile
The immediate fix is to restore initial autodetection for bare-metal
targets.
Reported-by: Eugene Bright
Closes: https://bugs.gentoo.org/666896
Signed-off-by: Sergei Trofimovich <slyfox <AT> gentoo.org>
eclass/toolchain-funcs.eclass | 7 +++++++
1 file changed, 7 insertions(+)
diff --git a/eclass/toolchain-funcs.eclass b/eclass/toolchain-funcs.eclass
index 3fa32820151..12ed132c48f 100644
--- a/eclass/toolchain-funcs.eclass
+++ b/eclass/toolchain-funcs.eclass
@@ -231,6 +231,10 @@ tc-detect-is-softfloat() {
[[ $(tc-getTARGET_CPP) == "gcc -E" ]] && return 1
case ${CTARGET:-${CHOST}} in
+ # Avoid autodetection for bare-metal targets. bug #666896
+ *-newlib|*-elf|*-eabi)
+ return 1 ;;
+
# arm-unknown-linux-gnueabi is ambiguous. We used to treat it as
# hardfloat but we now treat it as softfloat like most everyone
# else. Check existing toolchains to respect existing systems.
@@ -269,6 +273,9 @@ tc-tuple-is-softfloat() {
echo "softfp" ;;
arm*-hardfloat-*|arm*eabihf)
echo "no" ;;
+ # bare-metal targets have their defaults. bug #666896
+ *-newlib|*-elf|*-eabi)
+ echo "no" ;;
arm*)
echo "yes" ;;
*)