Hello,
The patch fixes the build issue for arm-none-eabi target configured with
--with-multilib-list=aprofile,rmprofile, in which case the header file
arm/arm-mlib.h is being included more than once and the toolchain build
is failing (PR108505).
Regression tested on arm-none-eabi target and found no regressions.
Ok for master?
Regards,
Srinath.
gcc/ChangeLog:
2023-01-24 Srinath Parvathaneni <[email protected]>
PR target/108505
* config.gcc (tm_file): Move the variable out of loop.
############### Attachment also inlined for ease of reply ###############
diff --git a/gcc/config.gcc b/gcc/config.gcc
index
771bd35e803b47e79c0a62eab8f4845e9bbf96ef..d828223c16d3076da0ab6582dfaf59ad657ea438
100644
--- a/gcc/config.gcc
+++ b/gcc/config.gcc
@@ -4350,7 +4350,6 @@ case "${target}" in
case ${arm_multilib} in
aprofile|rmprofile)
tmake_profile_file="arm/t-multilib"
- tm_file="$tm_file
arm/arm-mlib.h"
;;
@*)
ml=`echo "X$arm_multilib" | sed
'1s,^X@,,'`
@@ -4389,6 +4388,7 @@ case "${target}" in
# through to the multilib selector
with_float="soft"
tmake_file="${tmake_file} ${tmake_profile_file}"
+ tm_file="$tm_file arm/arm-mlib.h"
TM_MULTILIB_CONFIG="$with_multilib_list"
fi
fi
diff --git a/gcc/config.gcc b/gcc/config.gcc
index
771bd35e803b47e79c0a62eab8f4845e9bbf96ef..d828223c16d3076da0ab6582dfaf59ad657ea438
100644
--- a/gcc/config.gcc
+++ b/gcc/config.gcc
@@ -4350,7 +4350,6 @@ case "${target}" in
case ${arm_multilib} in
aprofile|rmprofile)
tmake_profile_file="arm/t-multilib"
- tm_file="$tm_file
arm/arm-mlib.h"
;;
@*)
ml=`echo "X$arm_multilib" | sed
'1s,^X@,,'`
@@ -4389,6 +4388,7 @@ case "${target}" in
# through to the multilib selector
with_float="soft"
tmake_file="${tmake_file} ${tmake_profile_file}"
+ tm_file="$tm_file arm/arm-mlib.h"
TM_MULTILIB_CONFIG="$with_multilib_list"
fi
fi