]> git.ipfire.org Git - thirdparty/gcc.git/blobdiff - libgcc/config.host
Update copyright years.
[thirdparty/gcc.git] / libgcc / config.host
index 168535b1780dca803b4cff73961afc40058174a1..017fbc7a06dc4f91c9079c6ee795b56a15f5e6d6 100644 (file)
@@ -1,5 +1,5 @@
 # libgcc host-specific configuration file.
-# Copyright (C) 1997-2021 Free Software Foundation, Inc.
+# Copyright (C) 1997-2024 Free Software Foundation, Inc.
 
 #This file is part of GCC.
 
@@ -110,8 +110,6 @@ bfin*-*)
 bpf-*-*)
         cpu_type=bpf
         ;;
-cr16-*-*)
-       ;;
 csky*-*-*)
        cpu_type=csky
        ;;
@@ -138,6 +136,22 @@ hppa*-*-*)
 lm32*-*-*)
        cpu_type=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
         ;;
@@ -185,9 +199,11 @@ riscv*-*-*)
        ;;
 sparc64*-*-*)
        cpu_type=sparc
+       tmake_file="${tmake_file} sparc/t-sparc"
        ;;
 sparc*-*-*)
        cpu_type=sparc
+       tmake_file="${tmake_file} sparc/t-sparc"
        ;;
 s390*-*-*)
        cpu_type=s390
@@ -196,12 +212,6 @@ s390*-*-*)
 sh[123456789lbe]*-*-*)
        cpu_type=sh
        ;;
-tilegx*-*-*)
-       cpu_type=tilegx
-       ;;
-tilepro*-*-*)
-       cpu_type=tilepro
-       ;;
 v850*-*-*)
        cpu_type=v850
        ;;
@@ -214,8 +224,57 @@ esac
 case ${host} in
 *-*-darwin*)
   asm_hidden_op=.private_extern
-  tmake_file="$tmake_file t-darwin ${cpu_type}/t-darwin t-libgcc-pic t-slibgcc-darwin"
-  extra_parts="crt3.o libd10-uwfef.a crttms.o crttme.o"
+  tmake_file="$tmake_file t-darwin ${cpu_type}/t-darwin t-libgcc-pic"
+  # The unwinder is provided by the system shared libraries, do not add one
+  # to the shared libgcc but, for older systems, we build a shared unwinder
+  # separately so that we can construct a libgcc_s.1 to use for binaries
+  # linked against the old libgcc_ext.10.x stubs.
+  case ${host} in
+    *-*-darwin[89]* | *-*-darwin10*)
+      tmake_file="$tmake_file t-darwin-ehs ${cpu_type}/t-darwin-ehs"
+      ;;
+  esac
+  tmake_file="$tmake_file t-slibgcc-darwin"
+  case ${host} in
+    *-*-darwin1[89]* | *-*-darwin2* )
+      tmake_file="t-darwin-min-8 $tmake_file"
+      ;;
+    *-*-darwin9* | *-*-darwin1[0-7]*)
+      tmake_file="t-darwin-min-5 $tmake_file"
+      ;;
+    *-*-darwin[4-8]*)
+      tmake_file="t-darwin-min-1 $tmake_file"
+      ;;
+    *)
+      # Fall back to configuring for the oldest system known to work with
+      # all archs and the current sources.
+      tmake_file="t-darwin-min-5 $tmake_file"
+      echo "Warning: libgcc configured to support macOS 10.5" 1>&2
+      ;;
+  esac
+  # We are not using libtool to build the libs here, so we need to replicate
+  # a little of the logic around setting Darwin rpaths.  Setting an explicit
+  # yes or no is honoured, otherwise we choose a suitable default.
+  # Sadly, this has to be kept in line with the rules in libtool.m4.
+  # This make fragment will override the setting in t-slibgcc-darwin so it
+  # must appear after it.
+  if test "x$enable_darwin_at_rpath" = "x"; then
+    echo "enable_darwin_at_rpath is unset" 1>&2
+    case ${host} in
+      *-darwin[45678]*) ;;
+      *-darwin9* | *-darwin1[01234]*) ;; # We might default these on later.
+      *-darwin*)
+        echo "but is needed after macOS 10.11 (setting it on)" 1>&2
+        enable_darwin_at_rpath=yes
+        ;;
+    esac
+  else
+    echo "enable_darwin_at_rpath is '$enable_darwin_at_rpath'" 1>&2
+  fi
+  if test "x$enable_darwin_at_rpath" = "xyes"; then
+    tmake_file="$tmake_file t-darwin-rpath "
+  fi
+  extra_parts="crt3.o libd10-uwfef.a crttms.o crttme.o libemutls_w.a"
   ;;
 *-*-dragonfly*)
   tmake_file="$tmake_file t-crtstuff-pic t-libgcc-pic t-eh-dw2-dip"
@@ -315,9 +374,6 @@ case ${host} in
   tmake_file="vms/t-vms"
   extra_parts="crt0.o crtbegin.o crtbeginS.o crtend.o crtendS.o"
   ;;
-*-*-vxworks7*)
-  tmake_file=t-vxworks7
-  ;;
 *-*-vxworksae*)
   tmake_file=t-vxworksae
   ;;
@@ -329,11 +385,8 @@ case ${host} in
   ;;
 esac
 
-# Except on ARM where we do not use DWARF, table based EH on VxWorks
-# relies on specially crafted crtstuff files
+# VxWorks ports rely on specially crafted crtstuff files
 case ${host} in
-arm-*-vxworks*)
-  ;;
 *-*-vxworks*)
   tmake_file="${tmake_file} t-vxcrtstuff"
   ;;
@@ -362,6 +415,7 @@ aarch64*-*-elf | aarch64*-*-rtems*)
        tmake_file="${tmake_file} ${cpu_type}/t-aarch64"
        tmake_file="${tmake_file} ${cpu_type}/t-lse t-slibgcc-libgcc"
        tmake_file="${tmake_file} ${cpu_type}/t-softfp t-softfp t-crtfm"
+       tmake_file="${tmake_file} t-dfprules"
        md_unwind_header=aarch64/aarch64-unwind.h
        ;;
 aarch64*-*-freebsd*)
@@ -369,18 +423,21 @@ aarch64*-*-freebsd*)
        tmake_file="${tmake_file} ${cpu_type}/t-aarch64"
        tmake_file="${tmake_file} ${cpu_type}/t-lse t-slibgcc-libgcc"
        tmake_file="${tmake_file} ${cpu_type}/t-softfp t-softfp t-crtfm"
+       tmake_file="${tmake_file} t-dfprules"
        md_unwind_header=aarch64/freebsd-unwind.h
        ;;
 aarch64*-*-netbsd*)
        extra_parts="$extra_parts crtfastmath.o"
        tmake_file="${tmake_file} ${cpu_type}/t-aarch64"
        tmake_file="${tmake_file} ${cpu_type}/t-softfp t-softfp t-crtfm"
+       tmake_file="${tmake_file} t-dfprules"
        md_unwind_header=aarch64/aarch64-unwind.h
        ;;
 aarch64*-*-fuchsia*)
        tmake_file="${tmake_file} ${cpu_type}/t-aarch64"
        tmake_file="${tmake_file} ${cpu_type}/t-lse t-slibgcc-libgcc"
        tmake_file="${tmake_file} ${cpu_type}/t-softfp t-softfp"
+       tmake_file="${tmake_file} t-dfprules"
        ;;
 aarch64*-*-linux*)
        extra_parts="$extra_parts crtfastmath.o"
@@ -388,13 +445,16 @@ aarch64*-*-linux*)
        tmake_file="${tmake_file} ${cpu_type}/t-aarch64"
        tmake_file="${tmake_file} ${cpu_type}/t-lse t-slibgcc-libgcc"
        tmake_file="${tmake_file} ${cpu_type}/t-softfp t-softfp t-crtfm"
+       tmake_file="${tmake_file} t-dfprules"
+       tmake_file="${tmake_file} ${cpu_type}/t-heap-trampoline"
        ;;
 aarch64*-*-vxworks7*)
        extra_parts="$extra_parts crtfastmath.o"
        md_unwind_header=aarch64/aarch64-unwind.h
        tmake_file="${tmake_file} ${cpu_type}/t-aarch64"
-       tmake_file="${tmake_file} ${cpu_type}/t-lse t-slibgcc-libgcc"
+       tmake_file="${tmake_file} ${cpu_type}/t-lse"
        tmake_file="${tmake_file} ${cpu_type}/t-softfp t-softfp t-crtfm"
+       tmake_file="${tmake_file} t-dfprules"
        ;;
 alpha*-*-linux*)
        tmake_file="${tmake_file} alpha/t-alpha alpha/t-ieee t-crtfm alpha/t-linux"
@@ -496,7 +556,7 @@ arm*-*-eabi* | arm*-*-symbianelf* | arm*-*-rtems*)
        tm_file="$tm_file arm/bpabi-lib.h"
        case ${host} in
        arm*-*-eabi* | arm*-*-rtems*)
-         tmake_file="${tmake_file} arm/t-bpabi t-crtfm"
+         tmake_file="${tmake_file} arm/t-bpabi arm/t-sync t-crtfm"
          extra_parts="crtbegin.o crtend.o crti.o crtn.o"
          ;;
        arm*-*-symbianelf*)
@@ -571,10 +631,6 @@ bpf-*-*)
         tmake_file="$tmake_file ${cpu_type}/t-${cpu_type}"
         extra_parts="crti.o crtn.o"
        ;;
-cr16-*-elf)
-       tmake_file="${tmake_file} cr16/t-cr16 cr16/t-crtlibid t-fdpbit"
-       extra_parts="$extra_parts crti.o crtn.o crtlibid.o"
-        ;;
 cris-*-elf)
        tmake_file="$tmake_file cris/t-cris t-softfp-sfdf t-softfp cris/t-elfmulti"
        ;;
@@ -619,7 +675,7 @@ h8300-*-linux*)
        tm_file="$tm_file h8300/h8300-lib.h"
        ;;
 hppa*64*-*-linux*)
-       tmake_file="$tmake_file pa/t-linux64 pa/t-dimode"
+       tmake_file="$tmake_file pa/t-pa64-linux pa/t-dimode"
        tmake_file="$tmake_file pa/t-softfp-sfdftf t-softfp"
        extra_parts="crtbegin.o crtbeginS.o crtbeginT.o crtend.o crtendS.o"
        ;;
@@ -634,19 +690,8 @@ hppa*-*-linux*)
        extra_parts="crtbegin.o crtbeginS.o crtbeginT.o crtend.o crtendS.o"
        md_unwind_header=pa/linux-unwind.h
        ;;
-hppa[12]*-*-hpux10*)
-       tmake_file="$tmake_file pa/t-hpux pa/t-hpux10 t-libgcc-pic t-slibgcc"
-       # Set the libgcc version number
-       if test x$ac_cv_sjlj_exceptions = xyes; then
-           tmake_file="$tmake_file pa/t-slibgcc-sjlj-ver"
-       else
-           tmake_file="$tmake_file pa/t-slibgcc-dwarf-ver"
-       fi
-       tmake_file="$tmake_file pa/t-slibgcc-hpux t-slibgcc-hpux"
-       md_unwind_header=pa/hpux-unwind.h
-       ;;
 hppa*64*-*-hpux11*)
-       tmake_file="$tmake_file pa/t-hpux pa/t-pa64 pa/t-dimode"
+       tmake_file="$tmake_file pa/t-pa64-hpux pa/t-dimode"
        tmake_file="$tmake_file pa/t-stublib t-libgcc-pic t-slibgcc"
        # Set the libgcc version number
        if test x$ac_cv_sjlj_exceptions = xyes; then
@@ -661,17 +706,6 @@ hppa*64*-*-hpux11*)
                     libgcc_stub.a"
        md_unwind_header=pa/hpux-unwind.h
        ;;
-hppa[12]*-*-hpux11*)
-       tmake_file="$tmake_file pa/t-hpux pa/t-stublib t-libgcc-pic t-slibgcc"
-       # Set the libgcc version number
-       if test x$ac_cv_sjlj_exceptions = xyes; then
-           tmake_file="$tmake_file pa/t-slibgcc-sjlj-ver"
-       else
-           tmake_file="$tmake_file pa/t-slibgcc-dwarf-ver"
-       fi
-       tmake_file="$tmake_file pa/t-slibgcc-hpux t-slibgcc-hpux"
-       md_unwind_header=pa/hpux-unwind.h
-       ;;
 hppa*-*-openbsd*)
        tmake_file="$tmake_file pa/t-openbsd"
        ;;
@@ -687,6 +721,7 @@ x86_64-*-darwin*)
        tmake_file="$tmake_file i386/t-crtpc t-crtfm i386/t-msabi"
        tm_file="$tm_file i386/darwin-lib.h"
        extra_parts="$extra_parts crtprec32.o crtprec64.o crtprec80.o crtfastmath.o"
+       tmake_file="${tmake_file} i386/t-heap-trampoline"
        ;;
 i[34567]86-*-elfiamcu)
        tmake_file="$tmake_file i386/t-crtstuff t-softfp-sfdftf i386/32/t-softfp i386/32/t-iamcu i386/t-softfp t-softfp t-dfprules"
@@ -753,12 +788,19 @@ x86_64-*-linux*)
        tmake_file="${tmake_file} i386/t-crtpc t-crtfm i386/t-crtstuff t-dfprules"
        tm_file="${tm_file} i386/elf-lib.h"
        md_unwind_header=i386/linux-unwind.h
+       tmake_file="${tmake_file} i386/t-heap-trampoline"
        ;;
 x86_64-*-kfreebsd*-gnu)
        extra_parts="$extra_parts crtprec32.o crtprec64.o crtprec80.o crtfastmath.o"
        tmake_file="${tmake_file} i386/t-crtpc t-crtfm i386/t-crtstuff t-dfprules"
        tm_file="${tm_file} i386/elf-lib.h"
        ;;
+x86_64-*-gnu*)
+       extra_parts="$extra_parts crtprec32.o crtprec64.o crtprec80.o crtfastmath.o"
+       tmake_file="${tmake_file} i386/t-crtpc t-crtfm i386/t-crtstuff t-dfprules"
+       tm_file="${tm_file} i386/elf-lib.h"
+       md_unwind_header=i386/gnu-unwind.h
+       ;;
 i[34567]86-pc-msdosdjgpp*)
        ;;
 i[34567]86-*-lynxos*)
@@ -828,10 +870,13 @@ i[34567]86-*-mingw*)
        fi
        case ${target_thread_file} in
          win32)
-           tmake_file="$tmake_file i386/t-gthr-win32"
+           tmake_thr_file="i386/t-gthr-win32"
            ;;
          posix)
-           tmake_file="i386/t-mingw-pthread $tmake_file"
+           tmake_thr_file="i386/t-mingw-pthread"
+           ;;
+         mcf)
+           tmake_thr_file="i386/t-mingw-mcfgthread"
            ;;
        esac
        # This has to match the logic for DWARF2_UNWIND_INFO in gcc/config/i386/cygming.h
@@ -847,15 +892,18 @@ i[34567]86-*-mingw*)
        else
                tmake_dlldir_file="i386/t-dlldir-x"
        fi
-       tmake_file="${tmake_file} ${tmake_eh_file} ${tmake_dlldir_file} i386/t-slibgcc-cygming i386/t-cygming i386/t-mingw32 t-crtfm i386/t-chkstk t-dfprules"
+       tmake_file="${tmake_file} ${tmake_eh_file} ${tmake_thr_file} ${tmake_dlldir_file} i386/t-slibgcc-cygming i386/t-slibgcc-mingw i386/t-cygming i386/t-mingw32 t-crtfm i386/t-chkstk t-dfprules"
        ;;
 x86_64-*-mingw*)
        case ${target_thread_file} in
          win32)
-           tmake_file="$tmake_file i386/t-gthr-win32"
+           tmake_thr_file="i386/t-gthr-win32"
            ;;
          posix)
-           tmake_file="i386/t-mingw-pthread $tmake_file"
+           tmake_thr_file="i386/t-mingw-pthread"
+           ;;
+         mcf)
+           tmake_thr_file="i386/t-mingw-mcfgthread"
            ;;
        esac
        # This has to match the logic for DWARF2_UNWIND_INFO in gcc/config/i386/cygming.h
@@ -874,7 +922,7 @@ x86_64-*-mingw*)
        else
                tmake_dlldir_file="i386/t-dlldir-x"
        fi
-       tmake_file="${tmake_file} ${tmake_eh_file} ${tmake_dlldir_file} i386/t-slibgcc-cygming i386/t-cygming i386/t-mingw32 t-dfprules t-crtfm i386/t-chkstk"
+       tmake_file="${tmake_file} ${tmake_eh_file} ${tmake_thr_file} ${tmake_dlldir_file} i386/t-slibgcc-cygming i386/t-slibgcc-mingw i386/t-cygming i386/t-mingw32 t-dfprules t-crtfm i386/t-chkstk"
        extra_parts="$extra_parts crtbegin.o crtend.o crtfastmath.o"
        if test x$enable_vtable_verify = xyes; then
                extra_parts="$extra_parts vtv_start.o vtv_end.o vtv_start_preinit.o vtv_end_preinit.o"
@@ -921,7 +969,22 @@ lm32-*-rtems*)
 lm32-*-uclinux*)
         extra_parts="$extra_parts crtbegin.o crtendS.o crtbeginT.o"
         tmake_file="lm32/t-lm32 lm32/t-uclinux t-libgcc-pic t-softfp-sfdf t-softfp"
-       ;;      
+       ;;
+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
+       ;;
+loongarch*-elf*)
+       extra_parts="$extra_parts crtfastmath.o"
+       tmake_file="${tmake_file} t-crtfm loongarch/t-crtstuff"
+       tmake_file="${tmake_file} t-slibgcc-libgcc"
+       ;;
 m32r-*-elf*)
        tmake_file="$tmake_file m32r/t-m32r t-fdpbit"
        extra_parts="$extra_parts crtinit.o crtfini.o"
@@ -1136,10 +1199,14 @@ powerpc-*-darwin*)
          md_unwind_header=rs6000/darwin-unwind.h
          ;;
        esac
+       # We build the darwin10 EH shim for Rosetta (running on x86 machines).
+       tm_file="$tm_file i386/darwin-lib.h"
        tmake_file="$tmake_file rs6000/t-ppc64-fp rs6000/t-ibm-ldouble"
        extra_parts="$extra_parts crt2.o crt3_2.o libef_ppc.a dw_ppc.o"
        ;;
 powerpc64-*-darwin*)
+       # We build the darwin10 EH shim for Rosetta (running on x86 machines).
+       tm_file="$tm_file i386/darwin-lib.h"
        tmake_file="$tmake_file rs6000/t-darwin64 rs6000/t-ibm-ldouble"
        extra_parts="$extra_parts crt2.o crt3_2.o libef_ppc.a dw_ppc.o"
        ;;
@@ -1228,7 +1295,8 @@ powerpc*-*-linux*)
        md_unwind_header=rs6000/linux-unwind.h
        ;;
 powerpc*-wrs-vxworks7*)
-        tmake_file="$tmake_file rs6000/t-ppccomm rs6000/t-savresfgpr rs6000/t-crtstuff rs6000/t-linux t-dfprules config/rs6000/t-ppc64-fp t-slibgcc-libgcc"
+        tmake_file="$tmake_file rs6000/t-vxworks rs6000/t-savresfgpr t-dfprules rs6000/t-ppc64-fp"
+        tmake_file="rs6000/t-crtstuff ${tmake_file}"
         case $ppc_fp_type in
         64)
                 ;;
@@ -1245,8 +1313,7 @@ powerpc*-wrs-vxworks7*)
         esac
         ;;
 powerpc-wrs-vxworks*)
-       tmake_file="$tmake_file rs6000/t-ppccomm rs6000/t-savresfgpr t-fdpbit"
-       extra_parts="$extra_parts crtbegin.o crtend.o"
+       tmake_file="$tmake_file rs6000/t-vxworks rs6000/t-savresfgpr t-fdpbit"
        ;;
 powerpc-*-lynxos*)
        tmake_file="$tmake_file rs6000/t-lynx t-fdpbit"
@@ -1268,12 +1335,12 @@ pru-*-*)
        tm_file="$tm_file pru/pru-abi.h"
        ;;
 riscv*-*-linux*)
-       tmake_file="${tmake_file} riscv/t-softfp${host_address} t-softfp riscv/t-elf riscv/t-elf${host_address} t-slibgcc-libgcc"
+       tmake_file="${tmake_file} riscv/t-crtstuff riscv/t-softfp${host_address} t-softfp riscv/t-elf riscv/t-elf${host_address} t-slibgcc-libgcc"
        extra_parts="$extra_parts crtbegin.o crtend.o crti.o crtn.o crtendS.o crtbeginT.o"
        md_unwind_header=riscv/linux-unwind.h
        ;;
 riscv*-*-freebsd*)
-       tmake_file="${tmake_file} riscv/t-softfp${host_address} t-softfp riscv/t-elf riscv/t-elf${host_address} t-slibgcc-libgcc"
+       tmake_file="${tmake_file} riscv/t-crtstuff riscv/t-softfp${host_address} t-softfp riscv/t-elf riscv/t-elf${host_address} t-slibgcc-libgcc"
        extra_parts="$extra_parts crtbegin.o crtend.o crti.o crtn.o crtendS.o crtbeginT.o"
        ;;
 riscv*-*-*)
@@ -1447,17 +1514,6 @@ tic6x-*-elf)
        extra_parts="$extra_parts crtbeginS.o crtendS.o crti.o crtn.o"
        unwind_header=config/c6x/unwind-c6x.h
        ;;
-tilegx*-*-linux*)
-       if test "${host_address}" = 64; then
-               tmake_file="${tmake_file} tilegx/t-softfp"
-       fi
-       tmake_file="${tmake_file} tilegx/t-crtstuff t-softfp-sfdf t-softfp tilegx/t-tilegx"
-       md_unwind_header=tilepro/linux-unwind.h
-        ;;
-tilepro*-*-linux*)
-       tmake_file="${tmake_file} tilepro/t-crtstuff t-softfp-sfdf t-softfp tilepro/t-tilepro t-slibgcc-libgcc"
-       md_unwind_header=tilepro/linux-unwind.h
-        ;;
 v850*-*-*)
        tmake_file="${tmake_file} v850/t-v850 t-fdpbit"
        ;;
@@ -1493,7 +1549,7 @@ am33_2.0-*-linux*)
        extra_parts="crtbegin.o crtend.o crtbeginS.o crtendS.o"
        tmake_file="$tmake_file t-fdpbit"
        ;;
-m32c-*-elf*|m32c-*-rtems*)
+m32c-*-elf*)
        tmake_file="$tmake_file m32c/t-m32c"
        ;;
 nvptx-*)
@@ -1522,7 +1578,7 @@ esac
 case ${host} in
 i[34567]86-*-linux* | x86_64-*-linux* | \
   i[34567]86-*-kfreebsd*-gnu | x86_64-*-kfreebsd*-gnu | \
-  i[34567]86-*-gnu*)
+  i[34567]86-*-gnu* | x86_64-*-gnu*)
        tmake_file="${tmake_file} t-tls i386/t-linux i386/t-msabi t-slibgcc-libgcc"
        if test "$libgcc_cv_cfi" = "yes"; then
                tmake_file="${tmake_file} t-stack i386/t-stack-i386"
@@ -1552,6 +1608,38 @@ aarch64*-*-*)
        # ILP32 needs an extra header for unwinding
        tm_file="${tm_file} aarch64/value-unwind.h"
        ;;
+riscv*-*-*)
+       tm_file="${tm_file} riscv/value-unwind.h"
+       ;;
+esac
+
+# Setup to build a shared libgcc for VxWorks when that was requested,
+# for library variants that support it (rtp only, code model not large).
+#
+
+case ${host} in
+*vxworks*)
+       case ${with_multisubdir}-${enable_shared} in
+       *large*)
+               ;;
+       *mrtp*-yes)
+               tmake_file="${tmake_file} t-libgcc-pic"
+
+               # Arrange to set a soname on libgcc_s so DT_NEEDED entries
+               # for it refer to that alone. This ensures absence of path
+               # components which would be incorrect as the runtime loader
+               # on target has no visibility over the host filesystem.
+               tmake_file="${tmake_file} t-slibgcc-gld-nover"
+               tmake_file="${tmake_file} t-slibgcc"
+
+               # t-slibgcc-libgcc is needed on at least aarch64 (for
+               # lse) and at most harmless on other targets.
+               tmake_file="${tmake_file} t-slibgcc-libgcc"
+
+               tmake_file="${tmake_file} t-crtstuff-pic t-vxcrtstuffS"
+               ;;
+       esac
+       ;;
 esac
 
 # The vxworks threads implementation relies on a few extra sources,