aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristophe Lyon <christophe.lyon@arm.com>2022-08-17 10:06:24 +0200
committerChristophe Lyon <christophe.lyon@arm.com>2022-08-17 13:49:12 +0200
commit06bca6950b154d7c85762acf1593d6792f8a2617 (patch)
tree34c612834227c393de3ca3800b157b41fe9adb6f
parentbac07a1da24fbc40720bd4080caaea6fa7769672 (diff)
downloadgcc-06bca6950b154d7c85762acf1593d6792f8a2617.zip
gcc-06bca6950b154d7c85762acf1593d6792f8a2617.tar.gz
gcc-06bca6950b154d7c85762acf1593d6792f8a2617.tar.bz2
arm: Define with_float to hard when target name ends with hf
On arm, the --with-float= configure option is used to define include files search path (among other things). However, when targeting arm-linux-gnueabihf, one would expect to automatically default to the hard-float ABI, but this is not the case. As a consequence, GCC bootstrap fails on an arm-linux-gnueabihf target if --with-float=hard is not used. This patch checks if the target name ends with 'hf' and defines with_float to hard if not already defined. This is achieved in gcc/config.gcc, just before selecting the default CPU depending on the $with_float value. 2022-08-17 Christophe Lyon <christophe.lyon@arm.com> gcc/ * config.gcc (arm): Define with_float to hard if target name ends with 'hf'.
-rw-r--r--gcc/config.gcc7
1 files changed, 7 insertions, 0 deletions
diff --git a/gcc/config.gcc b/gcc/config.gcc
index 4e3b15b..02f5897 100644
--- a/gcc/config.gcc
+++ b/gcc/config.gcc
@@ -1314,6 +1314,13 @@ arm*-*-linux-* | arm*-*-uclinuxfdpiceabi)
tm_file="$tm_file arm/uclinuxfdpiceabi.h"
;;
esac
+ # Define with_float to "hard" if not already defined and
+ # target name ends with "hf"
+ case $target:$with_float in
+ arm*-*-*hf:)
+ with_float=hard
+ ;;
+ esac
# Generation of floating-point instructions requires at least ARMv5te.
if [ "$with_float" = "hard" -o "$with_float" = "softfp" ] ; then
target_cpu_cname="arm10e"