]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
LoongArch: Prioritize target-specific makefile fragments
authorYang Yujie <yangyujie@loongson.cn>
Sat, 2 Aug 2025 09:14:25 +0000 (17:14 +0800)
committerLulu Cheng <chenglulu@loongson.cn>
Wed, 13 Aug 2025 03:01:49 +0000 (11:01 +0800)
libgcc/ChangeLog:

* config.host: Remove unused code. Include LoongArch-specific
tmake_files after the OS-specific ones.

libgcc/config.host

index 92acdd0d4993740b425afd58491ac229ed6a66b4..82ea1772f5166fec19ed7102f536881495445cce 100644 (file)
@@ -141,19 +141,6 @@ lm32*-*-*)
        ;;
 loongarch*-*)
        cpu_type=loongarch
-       tmake_file="loongarch/t-loongarch"
-       if test "${libgcc_cv_loongarch_hard_float}" = yes; then
-               tmake_file="${tmake_file} t-hardfp-sfdf t-hardfp"
-       else
-               tmake_file="${tmake_file} t-softfp-sfdf"
-       fi
-       if test "${ac_cv_sizeof_long_double}" = 16; then
-               tmake_file="${tmake_file} loongarch/t-softfp-tf"
-       fi
-       if test "${host_address}" = 64; then
-               tmake_file="${tmake_file} loongarch/t-loongarch64"
-       fi
-       tmake_file="${tmake_file} t-softfp"
        ;;
 m32r*-*-*)
         cpu_type=m32r
@@ -1003,16 +990,22 @@ lm32-*-uclinux*)
        ;;
 loongarch*-linux*)
        extra_parts="$extra_parts crtfastmath.o"
-       tmake_file="${tmake_file} t-crtfm loongarch/t-crtstuff"
-       case ${host} in
-         *)
-           tmake_file="${tmake_file} t-slibgcc-libgcc"
-           ;;
-       esac
        md_unwind_header=loongarch/linux-unwind.h
+       tmake_file="${tmake_file} loongarch/t-loongarch t-softfp-sfdf loongarch/t-softfp-tf"
+       if test "${host_address}" = 64; then
+               tmake_file="${tmake_file} loongarch/t-loongarch64"
+       fi
+       tmake_file="${tmake_file} t-softfp"
+       tmake_file="${tmake_file} t-crtfm loongarch/t-crtstuff"
+       tmake_file="${tmake_file} t-slibgcc-libgcc"
        ;;
 loongarch*-elf*)
        extra_parts="$extra_parts crtfastmath.o"
+       tmake_file="${tmake_file} loongarch/t-loongarch t-softfp-sfdf loongarch/t-softfp-tf"
+       if test "${host_address}" = 64; then
+               tmake_file="${tmake_file} loongarch/t-loongarch64"
+       fi
+       tmake_file="${tmake_file} t-softfp"
        tmake_file="${tmake_file} t-crtfm loongarch/t-crtstuff"
        tmake_file="${tmake_file} t-slibgcc-libgcc"
        ;;