$NetBSD: patch-gcc_config.gcc,v 1.5 2017/06/21 11:36:20 maya Exp $ Darwin 64-bit support. DragonFly BSD support. FreeBSD 10 to 12 support. NetBSD/mips64 should default to n32 ABI --- ../gcc-4.1.2/gcc/config.gcc.orig 2006-10-15 23:12:23.000000000 +0000 +++ ../gcc-4.1.2/gcc/config.gcc @@ -412,6 +412,12 @@ case ${target} in tm_defines="${tm_defines} FBSD_MAJOR=8" ;; *-*-freebsd9 | *-*-freebsd[9].*) tm_defines="${tm_defines} FBSD_MAJOR=9" ;; + *-*-freebsd10 | *-*-freebsd10.*) + tm_defines="${tm_defines} FBSD_MAJOR=10" ;; + *-*-freebsd11 | *-*-freebsd11.*) + tm_defines="${tm_defines} FBSD_MAJOR=11" ;; + *-*-freebsd12 | *-*-freebsd12.*) + tm_defines="${tm_defines} FBSD_MAJOR=12" ;; *) echo 'Please update *-*-freebsd* in gcc/config.gcc' exit 1 @@ -440,6 +446,23 @@ case ${target} in esac fbsd_tm_file="${fbsd_tm_file} freebsd-spec.h freebsd.h" ;; +*-*-dragonfly*) + gas=yes + gnu_ld=yes + extra_parts="crtbegin.o crtend.o crtbeginS.o crtendS.o" + tmake_file="t-slibgcc-elf-ver t-dragonfly" + case ${enable_threads} in + "" | yes | posix) + thread_file='posix' + tmake_file="${tmake_file} t-dragonfly-thread" + ;; + *) + echo 'Unknown thread configuration for FreeBSD' + exit 1 + ;; + esac + dfly_tm_file="${dfly_tm_file} dragonfly-spec.h dragonfly.h" + ;; *-*-linux*libc1* | *-*-linux*aout*) # Avoid the generic linux case. ;; @@ -981,6 +1004,8 @@ hppa[12]*-*-hpux11*) i[34567]86-*-darwin*) # All the configuration is presently done generically. ;; +x86_64-*-darwin*) + ;; i[34567]86-*-elf*) tm_file="${tm_file} i386/unix.h i386/att.h dbxelf.h elfos.h i386/i386elf.h" tmake_file="i386/t-i386elf t-svr4" @@ -1012,6 +1037,12 @@ i[34567]86-*-freebsd*) x86_64-*-freebsd*) tm_file="${tm_file} i386/unix.h i386/att.h dbxelf.h elfos.h ${fbsd_tm_file} i386/x86-64.h i386/freebsd.h i386/freebsd64.h" ;; +i[34567]86-*-dragonfly*) + tm_file="${tm_file} i386/unix.h i386/att.h dbxelf.h elfos.h ${dfly_tm_file} i386/dragonfly.h" + ;; +x86_64-*-dragonfly*) + tm_file="${tm_file} i386/unix.h i386/att.h dbxelf.h elfos.h ${dfly_tm_file} i386/x86-64.h i386/dragonfly.h i386/dragonfly64.h" + ;; i[34567]86-*-netbsdelf*) tm_file="${tm_file} i386/unix.h i386/att.h dbxelf.h elfos.h netbsd.h netbsd-elf.h i386/netbsd-elf.h" ;; @@ -1473,6 +1504,11 @@ mips-sgi-irix[56]*) # fi use_fixproto=yes ;; +mips64*-*-netbsd*) # NetBSD/mips64, either endian. + target_cpu_default="MASK_ABICALLS" + tm_defines="MIPS_ISA_DEFAULT=3 MIPS_ABI_DEFAULT=ABI_N32" + tm_file="elfos.h ${tm_file} mips/elf.h netbsd.h netbsd-elf.h mips/netbsd.h" + ;; mips*-*-netbsd*) # NetBSD/mips, either endian. target_cpu_default="MASK_ABICALLS" tm_file="elfos.h ${tm_file} mips/elf.h netbsd.h netbsd-elf.h mips/netbsd.h"