pkgsrc-Changes archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

CVS commit: pkgsrc/lang



Module Name:    pkgsrc
Committed By:   maya
Date:           Sun Jun 17 19:50:52 UTC 2018

Modified Files:
        pkgsrc/lang/gcc7: Makefile distinfo
        pkgsrc/lang/gcc7-libs: Makefile
        pkgsrc/lang/gcc7/patches: patch-gcc_config.gcc
Added Files:
        pkgsrc/lang/gcc7/patches: patch-gcc_common_config_arm_arm-common.c
            patch-gcc_config_alpha_elf.h patch-gcc_config_alpha_linux.h
            patch-gcc_config_arm_netbsd-eabi.h
            patch-gcc_config_arm_netbsd-elf.h patch-gcc_config_netbsd-elf.h
            patch-gcc_ginclude_stddef.h patch-libgcc_config.host
            patch-libgcc_config_arm_t-netbsd
            patch-libgcc_config_arm_t-netbsd-eabi

Log Message:
gcc7: fix many netbsd targets.

add netbsd/arm EABI target. recognise dwarf2 unwinding in the common arm code.

switch convoluted stddef.h logic from relying on include guards having certain
names to only applying for netbsd, which should be the sole remaining user.
(necessary for netbsd/arm, which uses different include guards for ansi.h)

move linux/alpha code out of shared alpha+ELF header.

make all netbsd targets include netbsd-stdint.h.

Fixes PR pkg/52951.

Bump PKGREVISION. bump gcc7-libs PKGREVISION above this one.


To generate a diff of this commit:
cvs rdiff -u -r1.17 -r1.18 pkgsrc/lang/gcc7/Makefile
cvs rdiff -u -r1.9 -r1.10 pkgsrc/lang/gcc7/distinfo
cvs rdiff -u -r1.1 -r1.2 pkgsrc/lang/gcc7-libs/Makefile
cvs rdiff -u -r0 -r1.1 \
    pkgsrc/lang/gcc7/patches/patch-gcc_common_config_arm_arm-common.c \
    pkgsrc/lang/gcc7/patches/patch-gcc_config_alpha_elf.h \
    pkgsrc/lang/gcc7/patches/patch-gcc_config_alpha_linux.h \
    pkgsrc/lang/gcc7/patches/patch-gcc_config_arm_netbsd-eabi.h \
    pkgsrc/lang/gcc7/patches/patch-gcc_config_arm_netbsd-elf.h \
    pkgsrc/lang/gcc7/patches/patch-gcc_config_netbsd-elf.h \
    pkgsrc/lang/gcc7/patches/patch-gcc_ginclude_stddef.h \
    pkgsrc/lang/gcc7/patches/patch-libgcc_config.host \
    pkgsrc/lang/gcc7/patches/patch-libgcc_config_arm_t-netbsd \
    pkgsrc/lang/gcc7/patches/patch-libgcc_config_arm_t-netbsd-eabi
cvs rdiff -u -r1.2 -r1.3 pkgsrc/lang/gcc7/patches/patch-gcc_config.gcc

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: pkgsrc/lang/gcc7/Makefile
diff -u pkgsrc/lang/gcc7/Makefile:1.17 pkgsrc/lang/gcc7/Makefile:1.18
--- pkgsrc/lang/gcc7/Makefile:1.17      Wed May 23 08:11:16 2018
+++ pkgsrc/lang/gcc7/Makefile   Sun Jun 17 19:50:52 2018
@@ -1,7 +1,7 @@
-# $NetBSD: Makefile,v 1.17 2018/05/23 08:11:16 jperkin Exp $
+# $NetBSD: Makefile,v 1.18 2018/06/17 19:50:52 maya Exp $
 
 GCC_PKGNAME=           gcc7
-PKGREVISION=           1
+PKGREVISION=           2
 .include               "version.mk"
 
 DISTNAME=      gcc-${GCC7_DIST_VERSION}

Index: pkgsrc/lang/gcc7/distinfo
diff -u pkgsrc/lang/gcc7/distinfo:1.9 pkgsrc/lang/gcc7/distinfo:1.10
--- pkgsrc/lang/gcc7/distinfo:1.9       Wed May 23 08:11:16 2018
+++ pkgsrc/lang/gcc7/distinfo   Sun Jun 17 19:50:52 2018
@@ -1,4 +1,4 @@
-$NetBSD: distinfo,v 1.9 2018/05/23 08:11:16 jperkin Exp $
+$NetBSD: distinfo,v 1.10 2018/06/17 19:50:52 maya Exp $
 
 SHA1 (gcc-7.3.0.tar.xz) = 9689b9cae7b2886fdaa08449a26701f095c04e48
 RMD160 (gcc-7.3.0.tar.xz) = 31f6934a0e0c0ca84b6668110f9afdb91c1f9023
@@ -10,14 +10,21 @@ SHA512 (isl-0.16.1.tar.bz2) = c188667a84
 Size (isl-0.16.1.tar.bz2) = 1626446 bytes
 SHA1 (patch-contrib_download__prerequisites) = 86c6c16e0e3e3a0bcb38579a8b4004f603fac1ca
 SHA1 (patch-gcc_Makefile.in) = d96a57a098e49a2c5ea6478dd5d22aba584fc1bc
-SHA1 (patch-gcc_config.gcc) = 943797cbbdbf25885b4f16a1a027d137ef68357e
+SHA1 (patch-gcc_common_config_arm_arm-common.c) = 7c973cb9554a52f4b85f8fc98708f5e5cce8e8bd
+SHA1 (patch-gcc_config.gcc) = fd19774e62c2931d52eda2f979c1db65202ed4fb
+SHA1 (patch-gcc_config_alpha_elf.h) = 05657c528109480296cbe8a98461cba7853af492
+SHA1 (patch-gcc_config_alpha_linux.h) = fce1256bce232143ff6c1c1b8b9c855737adb23f
 SHA1 (patch-gcc_config_arm_arm.h) = 92c8bff1063e153fec4454e6dea5334a42b0dad6
+SHA1 (patch-gcc_config_arm_netbsd-eabi.h) = 9c1d2148e306024e8de3bdc9802fb63b976e0e7a
+SHA1 (patch-gcc_config_arm_netbsd-elf.h) = 80a07645fab197969b4a6f518fdc81bda7376375
+SHA1 (patch-gcc_config_netbsd-elf.h) = 5a9b5ef26c03bec3cd58e2f446224aa6e94a30d5
 SHA1 (patch-gcc_config_netbsd-protos.h) = 6d28864b4ccc8c1a63fe28e43601b84b63a00633
 SHA1 (patch-gcc_config_netbsd.h) = 8861abb345b3ad72574fbe7afca2ea78b81d9632
 SHA1 (patch-gcc_config_t-netbsd) = 802ad5706aa7ca9629f8e237f08fbb1569d28846
 SHA1 (patch-gcc_config_x-netbsd) = 6dc3d78e26df62054ea29f98ca51592858e671e3
 SHA1 (patch-gcc_configure) = 15fb7af267b79965f83bc64ce8aad1279b0ea52d
 SHA1 (patch-gcc_ggc-common.c) = a5d2dba635859f5d680c3f80d7c30b42461c752b
+SHA1 (patch-gcc_ginclude_stddef.h) = 583b7931aad14058be75569b0138efad8ac74113
 SHA1 (patch-gcc_lto_lto.c) = 825b632e2a7ff5777d4fbfdcf6f0ea3f64c4742b
 SHA1 (patch-gcc_system.h) = 4c959a6b1c4d524cbdf44cfb80f0e5758ec20783
 SHA1 (patch-isl_configure) = 36b37778ee13c0b364fb24d5864d6a9e65b29b7d
@@ -26,6 +33,9 @@ SHA1 (patch-libcilkrts_runtime_os-unix.c
 SHA1 (patch-libdecnumber_decNumber.c) = cec90e49c829bfc6ba1ec605d2fac7daaad62762
 SHA1 (patch-libffi_configure) = bcfbfe8abddc378e2de4a39ad0669583b37e0292
 SHA1 (patch-libffi_testsuite_libffi.call_float2.c) = 6321dde308579448c27c2b6e1e30633699dd145f
+SHA1 (patch-libgcc_config.host) = 1c2ebce3a44d935e9bbab30952b51b6f3716e47e
+SHA1 (patch-libgcc_config_arm_t-netbsd) = fe986b09ccbfc253aaaca263e8e38f06da4891cc
+SHA1 (patch-libgcc_config_arm_t-netbsd-eabi) = 1e818e92fe79f57d305ff42ce3449dddf87c3179
 SHA1 (patch-libgcc_config_i386_cpuinfo.h) = d217e3c65178c96c7314cb88c740b9586d4e8fed
 SHA1 (patch-libgcc_crtstuff.c) = e3a3b02a26229992851f195b5701cb1b86c29efe
 SHA1 (patch-libgfortran_configure) = 869a60fd08edecf18a42732dcbf226bad1309394

Index: pkgsrc/lang/gcc7-libs/Makefile
diff -u pkgsrc/lang/gcc7-libs/Makefile:1.1 pkgsrc/lang/gcc7-libs/Makefile:1.2
--- pkgsrc/lang/gcc7-libs/Makefile:1.1  Mon May 21 10:05:58 2018
+++ pkgsrc/lang/gcc7-libs/Makefile      Sun Jun 17 19:50:52 2018
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.1 2018/05/21 10:05:58 jperkin Exp $
+# $NetBSD: Makefile,v 1.2 2018/06/17 19:50:52 maya Exp $
 
 GCC_PKGNAME=   gcc7
 .include       "../../lang/${GCC_PKGNAME}/version.mk"
@@ -9,7 +9,7 @@ PKGNAME=        ${GCC_PKGNAME}-libs-${GCC7_DIST
 ## The PKGREVISION of this package needs to be at least 1 more than the
 ## PKGREVISION of the lang/gcc7 package so that with the dependence pattern
 ## '{gcc7,gcc7-libs}>=7.3.*' pkg_add will choose gcc7-libs over gcc7.
-PKGREVISION=   2
+PKGREVISION=   3
 
 CATEGORIES=    lang
 MASTER_SITES=  # empty

Index: pkgsrc/lang/gcc7/patches/patch-gcc_config.gcc
diff -u pkgsrc/lang/gcc7/patches/patch-gcc_config.gcc:1.2 pkgsrc/lang/gcc7/patches/patch-gcc_config.gcc:1.3
--- pkgsrc/lang/gcc7/patches/patch-gcc_config.gcc:1.2   Thu Jan 25 23:27:30 2018
+++ pkgsrc/lang/gcc7/patches/patch-gcc_config.gcc       Sun Jun 17 19:50:52 2018
@@ -1,10 +1,14 @@
-$NetBSD: patch-gcc_config.gcc,v 1.2 2018/01/25 23:27:30 maya Exp $
+$NetBSD: patch-gcc_config.gcc,v 1.3 2018/06/17 19:50:52 maya Exp $
 
 Workaround netbsd's compatibility non-C99 cabs (causes gfortran link failures)
+netbsd/arm eabi support
+
+use nbsd_tm_file to make sure every netbsd target gets netbsd-stdint.h
+(upstreamed)
 
 --- gcc/config.gcc.orig        2018-01-08 13:39:11.000000000 +0000
 +++ gcc/config.gcc
-@@ -781,6 +781,10 @@ case ${target} in
+@@ -781,7 +781,12 @@ case ${target} in
    gas=yes
    gnu_ld=yes
    use_gcc_stdint=wrap
@@ -13,18 +17,119 @@ Workaround netbsd's compatibility non-C9
 +  target_gtfiles="${target_gtfiles} \$(srcdir)/config/netbsd.c"
 +  extra_objs="${extra_objs} netbsd.o"
  
++  nbsd_tm_file="netbsd.h netbsd-stdint.h netbsd-elf.h"
    # NetBSD 2.0 and later get POSIX threads enabled by default.
    # Allow them to be explicitly enabled on any other version.
-@@ -1487,10 +1491,12 @@ x86_64-*-freebsd*)
+   case ${enable_threads} in
+@@ -1001,7 +1006,7 @@ alpha*-*-freebsd*)
+       extra_options="${extra_options} alpha/elf.opt"
+       ;;
+ alpha*-*-netbsd*)
+-      tm_file="elfos.h ${tm_file} netbsd.h alpha/elf.h netbsd-elf.h alpha/netbsd.h"
++      tm_file="elfos.h ${tm_file} ${nbsd_tm_file} alpha/elf.h alpha/netbsd.h"
+       tmake_file="${tmake_file} alpha/t-alpha"
+       extra_options="${extra_options} netbsd.opt netbsd-elf.opt \
+                      alpha/elf.opt"
+@@ -1092,10 +1097,37 @@ arm*-*-freebsd*)                # ARM Fr
+       with_tls=${with_tls:-gnu}
+       ;;
+ arm*-*-netbsdelf*)
+-      tm_file="dbxelf.h elfos.h netbsd.h netbsd-elf.h arm/elf.h arm/aout.h ${tm_file} arm/netbsd-elf.h"
+-      extra_options="${extra_options} netbsd.opt netbsd-elf.opt"
+       tmake_file="${tmake_file} arm/t-arm"
+-      target_cpu_cname="arm6"
++      tm_file="dbxelf.h elfos.h ${nbsd_tm_file} arm/elf.h"
++      extra_options="${extra_options} netbsd.opt netbsd-elf.opt"
++      case ${target} in
++      arm*eb-*) tm_defines="${tm_defines} TARGET_BIG_ENDIAN_DEFAULT=1" ;;
++      esac
++      case ${target} in
++      arm*-*-netbsdelf-*eabi*)
++          tm_file="$tm_file arm/bpabi.h arm/netbsd-elf.h arm/netbsd-eabi.h"
++          tmake_file="$tmake_file arm/t-bpabi arm/t-netbsdeabi"
++          # The BPABI long long divmod functions return a 128-bit value in
++          # registers r0-r3.  Correctly modeling that requires the use of
++          # TImode.
++          need_64bit_hwint=yes
++          ;;
++      *)
++          tm_file="$tm_file arm/netbsd-elf.h"
++          tmake_file="$tmake_file arm/t-netbsd"
++          ;;
++      esac
++      tm_file="${tm_file} arm/aout.h arm/arm.h"
++      case ${target} in
++      arm*-*-netbsdelf-*eabihf*)
++          tm_defines="${tm_defines} TARGET_DEFAULT_FLOAT_ABI=ARM_FLOAT_ABI_HARD"
++          ;;
++      esac
++      case ${target} in
++      armv4*) target_cpu_cname="strongarm";;
++      armv6*) target_cpu_cname="arm1176jzfs";;
++      armv7*) target_cpu_cname="cortexa8";;
++      esac
+       ;;
+ arm*-*-linux-*)                       # ARM GNU/Linux with ELF
+       tm_file="dbxelf.h elfos.h gnu-user.h linux.h linux-android.h glibc-stdint.h arm/elf.h arm/linux-gas.h arm/linux-elf.h"
+@@ -1485,12 +1517,14 @@ 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-*-netbsdelf*)
-       tm_file="${tm_file} i386/unix.h i386/att.h dbxelf.h elfos.h netbsd.h netbsd-stdint.h netbsd-elf.h i386/netbsd-elf.h"
+-      tm_file="${tm_file} i386/unix.h i386/att.h dbxelf.h elfos.h netbsd.h netbsd-stdint.h netbsd-elf.h i386/netbsd-elf.h"
++      tm_file="${tm_file} i386/unix.h i386/att.h dbxelf.h elfos.h ${nbsd_tm_file} i386/netbsd-elf.h"
        extra_options="${extra_options} netbsd.opt netbsd-elf.opt"
 +      tmake_file="${tmake_file} i386/t-crtstuff"
        ;;
  x86_64-*-netbsd*)
-       tm_file="${tm_file} i386/unix.h i386/att.h dbxelf.h elfos.h netbsd.h netbsd-stdint.h netbsd-elf.h i386/x86-64.h i386/netbsd64.h"
+-      tm_file="${tm_file} i386/unix.h i386/att.h dbxelf.h elfos.h netbsd.h netbsd-stdint.h netbsd-elf.h i386/x86-64.h i386/netbsd64.h"
++      tm_file="${tm_file} i386/unix.h i386/att.h dbxelf.h elfos.h ${nbsd_tm_file} i386/x86-64.h i386/netbsd64.h"
        extra_options="${extra_options} netbsd.opt netbsd-elf.opt"
 +      tmake_file="${tmake_file} i386/t-crtstuff"
        ;;
  i[34567]86-*-openbsd*)
        tm_file="${tm_file} i386/unix.h i386/att.h dbxelf.h elfos.h"
+@@ -2381,7 +2415,7 @@ powerpc*-*-freebsd*)
+       esac
+       ;;
+ powerpc-*-netbsd*)
+-      tm_file="${tm_file} dbxelf.h elfos.h netbsd.h netbsd-elf.h freebsd-spec.h rs6000/sysv4.h rs6000/netbsd.h"
++      tm_file="${tm_file} dbxelf.h elfos.h ${nbsd_tm_file} freebsd-spec.h rs6000/sysv4.h rs6000/netbsd.h"
+       extra_options="${extra_options} netbsd.opt netbsd-elf.opt"
+       tmake_file="${tmake_file} rs6000/t-netbsd"
+       extra_options="${extra_options} rs6000/sysv4.opt"
+@@ -2700,7 +2734,7 @@ sh-*-elf* | sh[12346l]*-*-elf* | \
+                       fi
+                       tm_file="${tm_file} gnu-user.h linux.h glibc-stdint.h sh/linux.h" ;;
+       sh*-*-netbsd*)
+-                      tm_file="${tm_file} netbsd.h netbsd-elf.h sh/netbsd-elf.h"
++                      tm_file="${tm_file} ${nbsd_tm_file} sh/netbsd-elf.h"
+                       extra_options="${extra_options} netbsd.opt netbsd-elf.opt"
+ 
+                       ;;
+@@ -2860,7 +2894,7 @@ sparc-*-linux*)
+       fi
+       ;;
+ sparc-*-netbsdelf*)
+-      tm_file="${tm_file} dbxelf.h elfos.h sparc/sysv4.h netbsd.h netbsd-elf.h sparc/netbsd-elf.h"
++      tm_file="${tm_file} dbxelf.h elfos.h sparc/sysv4.h ${nbsd_tm_file} sparc/netbsd-elf.h"
+       extra_options="${extra_options} netbsd.opt netbsd-elf.opt"
+       extra_options="${extra_options} sparc/long-double-switch.opt"
+       tmake_file="${tmake_file} sparc/t-sparc"
+@@ -2908,7 +2942,7 @@ sparc64-*-freebsd*|ultrasparc-*-freebsd*
+       ;;
+ sparc64-*-netbsd*)
+       tm_file="sparc/biarch64.h ${tm_file}"
+-      tm_file="${tm_file} dbxelf.h elfos.h sparc/sysv4.h netbsd.h netbsd-elf.h sparc/netbsd-elf.h"
++      tm_file="${tm_file} dbxelf.h elfos.h sparc/sysv4.h ${nbsd_tm_file} sparc/netbsd-elf.h"
+       extra_options="${extra_options} netbsd.opt netbsd-elf.opt"
+       extra_options="${extra_options} sparc/long-double-switch.opt"
+       tmake_file="${tmake_file} sparc/t-sparc sparc/t-netbsd64"
+@@ -3012,7 +3046,7 @@ vax-*-linux*)
+       extra_options="${extra_options} vax/elf.opt"
+       ;;
+ vax-*-netbsdelf*)
+-      tm_file="${tm_file} elfos.h netbsd.h netbsd-elf.h vax/elf.h vax/netbsd-elf.h"
++      tm_file="${tm_file} elfos.h ${nbsd_tm_file} vax/elf.h vax/netbsd-elf.h"
+       extra_options="${extra_options} netbsd.opt netbsd-elf.opt vax/elf.opt"
+       ;;
+ vax-*-openbsd*)

Added files:

Index: pkgsrc/lang/gcc7/patches/patch-gcc_common_config_arm_arm-common.c
diff -u /dev/null pkgsrc/lang/gcc7/patches/patch-gcc_common_config_arm_arm-common.c:1.1
--- /dev/null   Sun Jun 17 19:50:53 2018
+++ pkgsrc/lang/gcc7/patches/patch-gcc_common_config_arm_arm-common.c   Sun Jun 17 19:50:52 2018
@@ -0,0 +1,16 @@
+$NetBSD: patch-gcc_common_config_arm_arm-common.c,v 1.1 2018/06/17 19:50:52 maya Exp $
+
+use dwarf2 if requested, netbsd/arm uses this.
+
+--- gcc/common/config/arm/arm-common.c.orig    2017-01-11 14:39:00.884692000 +0000
++++ gcc/common/config/arm/arm-common.c
+@@ -49,6 +49,9 @@ arm_except_unwind_info (struct gcc_optio
+     return UI_SJLJ;
+ #endif
+ 
++  if (ARM_DWARF_UNWIND_TABLES)
++    return UI_DWARF2;
++
+   /* If not using ARM EABI unwind tables... */
+   if (ARM_UNWIND_INFO)
+     {
Index: pkgsrc/lang/gcc7/patches/patch-gcc_config_alpha_elf.h
diff -u /dev/null pkgsrc/lang/gcc7/patches/patch-gcc_config_alpha_elf.h:1.1
--- /dev/null   Sun Jun 17 19:50:53 2018
+++ pkgsrc/lang/gcc7/patches/patch-gcc_config_alpha_elf.h       Sun Jun 17 19:50:52 2018
@@ -0,0 +1,40 @@
+$NetBSD: patch-gcc_config_alpha_elf.h,v 1.1 2018/06/17 19:50:52 maya Exp $
+
+Move linux-specific definitions to linux file.
+PR target/85095, https://gcc.gnu.org/ml/gcc-patches/2018-05/msg01370.html
+
+--- gcc/config/alpha/elf.h.orig        2017-01-01 12:07:43.905435000 +0000
++++ gcc/config/alpha/elf.h
+@@ -100,32 +100,6 @@ do {                                                                      \
+     ASM_OUTPUT_DEF (FILE, alias, name);                               \
+   } while (0)
+ 
+-/* Provide a STARTFILE_SPEC appropriate for ELF.  Here we add the
+-   (even more) magical crtbegin.o file which provides part of the
+-   support for getting C++ file-scope static object constructed
+-   before entering `main'.  */
+-
+-#undef        STARTFILE_SPEC
+-#ifdef HAVE_LD_PIE
+-#define STARTFILE_SPEC \
+-  "%{!shared: %{pg|p:gcrt1.o%s;pie:Scrt1.o%s;:crt1.o%s}}\
+-   crti.o%s %{static:crtbeginT.o%s;shared|pie:crtbeginS.o%s;:crtbegin.o%s}"
+-#else
+-#define STARTFILE_SPEC \
+-  "%{!shared: %{pg|p:gcrt1.o%s;:crt1.o%s}}\
+-   crti.o%s %{static:crtbeginT.o%s;shared|pie:crtbeginS.o%s;:crtbegin.o%s}"
+-#endif
+-
+-/* Provide a ENDFILE_SPEC appropriate for ELF.  Here we tack on the
+-   magical crtend.o file which provides part of the support for
+-   getting C++ file-scope static object constructed before entering
+-   `main', followed by a normal ELF "finalizer" file, `crtn.o'.  */
+-
+-#undef        ENDFILE_SPEC
+-#define ENDFILE_SPEC \
+-  "%{Ofast|ffast-math|funsafe-math-optimizations:crtfastmath.o%s} \
+-   %{shared|pie:crtendS.o%s;:crtend.o%s} crtn.o%s"
+-
+ /* This variable should be set to 'true' if the target ABI requires
+    unwinding tables even when exceptions are not used.  */
+ #define TARGET_UNWIND_TABLES_DEFAULT true
Index: pkgsrc/lang/gcc7/patches/patch-gcc_config_alpha_linux.h
diff -u /dev/null pkgsrc/lang/gcc7/patches/patch-gcc_config_alpha_linux.h:1.1
--- /dev/null   Sun Jun 17 19:50:53 2018
+++ pkgsrc/lang/gcc7/patches/patch-gcc_config_alpha_linux.h     Sun Jun 17 19:50:52 2018
@@ -0,0 +1,40 @@
+$NetBSD: patch-gcc_config_alpha_linux.h,v 1.1 2018/06/17 19:50:52 maya Exp $
+
+Move linux-specific definitions to linux file.
+PR target/85095, https://gcc.gnu.org/ml/gcc-patches/2018-05/msg01370.html
+
+--- gcc/config/alpha/linux.h.orig      2017-01-01 12:07:43.905435000 +0000
++++ gcc/config/alpha/linux.h
+@@ -78,6 +78,32 @@ along with GCC; see the file COPYING3.  
+ 
+ #define TARGET_POSIX_IO
+ 
++/* Provide a STARTFILE_SPEC appropriate for ELF.  Here we add the
++   (even more) magical crtbegin.o file which provides part of the
++   support for getting C++ file-scope static object constructed
++   before entering `main'.  */
++
++#undef        STARTFILE_SPEC
++#ifdef HAVE_LD_PIE
++#define STARTFILE_SPEC \
++  "%{!shared: %{pg|p:gcrt1.o%s;pie:Scrt1.o%s;:crt1.o%s}}\
++   crti.o%s %{static:crtbeginT.o%s;shared|pie:crtbeginS.o%s;:crtbegin.o%s}"
++#else
++#define STARTFILE_SPEC \
++  "%{!shared: %{pg|p:gcrt1.o%s;:crt1.o%s}}\
++   crti.o%s %{static:crtbeginT.o%s;shared|pie:crtbeginS.o%s;:crtbegin.o%s}"
++#endif
++
++/* Provide a ENDFILE_SPEC appropriate for ELF.  Here we tack on the
++   magical crtend.o file which provides part of the support for
++   getting C++ file-scope static object constructed before entering
++   `main', followed by a normal ELF "finalizer" file, `crtn.o'.  */
++
++#undef        ENDFILE_SPEC
++#define ENDFILE_SPEC \
++  "%{Ofast|ffast-math|funsafe-math-optimizations:crtfastmath.o%s} \
++   %{shared|pie:crtendS.o%s;:crtend.o%s} crtn.o%s"
++
+ #define LINK_GCC_C_SEQUENCE_SPEC \
+   "%{static:--start-group} %G %L %{static:--end-group}%{!static:%G}"
+ 
Index: pkgsrc/lang/gcc7/patches/patch-gcc_config_arm_netbsd-eabi.h
diff -u /dev/null pkgsrc/lang/gcc7/patches/patch-gcc_config_arm_netbsd-eabi.h:1.1
--- /dev/null   Sun Jun 17 19:50:53 2018
+++ pkgsrc/lang/gcc7/patches/patch-gcc_config_arm_netbsd-eabi.h Sun Jun 17 19:50:52 2018
@@ -0,0 +1,119 @@
+$NetBSD: patch-gcc_config_arm_netbsd-eabi.h,v 1.1 2018/06/17 19:50:52 maya Exp $
+
+netbsd/arm EABI support
+
+--- gcc/config/arm/netbsd-eabi.h.orig  2018-02-02 18:49:57.566284082 +0000
++++ gcc/config/arm/netbsd-eabi.h
+@@ -0,0 +1,112 @@
++/* Definitions of target machine for GNU compiler, NetBSD/arm ELF version.
++   Copyright (C) 2002, 2003, 2004, 2005, 2007 Free Software Foundation, Inc.
++   Contributed by Wasabi Systems, Inc.
++
++   This file is part of GCC.
++
++   GCC is free software; you can redistribute it and/or modify it
++   under the terms of the GNU General Public License as published
++   by the Free Software Foundation; either version 3, or (at your
++   option) any later version.
++
++   GCC is distributed in the hope that it will be useful, but WITHOUT
++   ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
++   or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public
++   License for more details.
++
++   You should have received a copy of the GNU General Public License
++   along with GCC; see the file COPYING3.  If not see
++   <http://www.gnu.org/licenses/>.  */
++
++/* Run-time Target Specification.  */
++#undef MULTILIB_DEFAULTS
++#define MULTILIB_DEFAULTS { "mabi=aapcs-linux" }
++
++#define TARGET_LINKER_EABI_SUFFIX \
++    (TARGET_DEFAULT_FLOAT_ABI == ARM_FLOAT_ABI_SOFT \
++     ? "%{!mabi=apcs-gnu:%{!mabi=atpcs:%{mfloat-abi=hard:_eabihf;:_eabi}}}" \
++     : "%{!mabi=apcs-gnu:%{!mabi=atpcs:%{mfloat-abi=soft:_eabi;:_eabihf}}}")
++#define TARGET_LINKER_BIG_EMULATION "armelfb_nbsd%(linker_eabi_suffix)"
++#define TARGET_LINKER_LITTLE_EMULATION "armelf_nbsd%(linker_eabi_suffix)"
++
++/* TARGET_BIG_ENDIAN_DEFAULT is set in
++   config.gcc for big endian configurations.  */
++#undef  TARGET_LINKER_EMULATION
++#if TARGET_BIG_ENDIAN_DEFAULT
++#define TARGET_LINKER_EMULATION TARGET_LINKER_BIG_EMULATION
++#undef BE8_LINK_SPEC
++#define BE8_LINK_SPEC " %{!mlittle-endian:%{march=armv7-a|mcpu=cortex-a5|mcpu=cortex-a8|mcpu=cortex-a9:%{!r:--be8}}}" 
++#else
++#define TARGET_LINKER_EMULATION TARGET_LINKER_LITTLE_EMULATION
++#endif
++
++#undef ARM_DEFAULT_ABI
++#define ARM_DEFAULT_ABI ARM_ABI_AAPCS_LINUX
++
++#undef ARM_EABI_UNWIND_TABLES
++#define ARM_EABI_UNWIND_TABLES 0
++#undef ARM_UNWIND_INFO
++#define ARM_UNWIND_INFO 0
++#undef ARM_DWARF_UNWIND_TABLES
++#define ARM_DWARF_UNWIND_TABLES 1
++
++#undef TARGET_OS_CPP_BUILTINS
++#define TARGET_OS_CPP_BUILTINS()              \
++  do                                          \
++    {                                         \
++      if (TARGET_AAPCS_BASED)                 \
++      TARGET_BPABI_CPP_BUILTINS();            \
++      NETBSD_OS_CPP_BUILTINS_ELF();           \
++      if (ARM_DWARF_UNWIND_TABLES)            \
++      builtin_define ("__ARM_DWARF_EH__");    \
++      if (ARM_EABI_UNWIND_TABLES)             \
++      builtin_define ("__UNWIND_TABLES__");   \
++    }                                         \
++  while (0)
++
++#undef SUBTARGET_CPP_SPEC
++#define SUBTARGET_CPP_SPEC NETBSD_CPP_SPEC
++
++/*
++ * Override AAPCS types to remain compatible the existing NetBSD types.
++ */
++#undef WCHAR_TYPE
++#define WCHAR_TYPE "int"
++
++#undef SIZE_TYPE
++#define SIZE_TYPE "long unsigned int"
++ 
++#undef PTRDIFF_TYPE
++#define PTRDIFF_TYPE "long int"
++
++#undef SUBTARGET_EXTRA_ASM_SPEC
++#define SUBTARGET_EXTRA_ASM_SPEC      \
++  "-matpcs %{mabi=apcs-gnu|mabi=atpcs:-meabi=gnu} %{fpic|fpie:-k} %{fPIC|fPIE:-k}"
++
++/* Default to full VFP if -mhard-float is specified.  */
++#undef SUBTARGET_ASM_FLOAT_SPEC
++#define SUBTARGET_ASM_FLOAT_SPEC      \
++  "%{mhard-float:%{!mfpu=*:-mfpu=vfp}}   \
++   %{mfloat-abi=hard:%{!mfpu=*:-mfpu=vfp}}"
++
++#undef SUBTARGET_EXTRA_SPECS
++#define SUBTARGET_EXTRA_SPECS                         \
++  { "subtarget_extra_asm_spec",       SUBTARGET_EXTRA_ASM_SPEC }, \
++  { "subtarget_asm_float_spec", SUBTARGET_ASM_FLOAT_SPEC }, \
++  { "linker_eabi_suffix",     TARGET_LINKER_EABI_SUFFIX }, \
++  { "linker_emulation",               TARGET_LINKER_EMULATION }, \
++  { "linker_big_emulation",   TARGET_LINKER_BIG_EMULATION }, \
++  { "linker_little_emulation",        TARGET_LINKER_LITTLE_EMULATION }, \
++  { "be8_link_spec",          BE8_LINK_SPEC }, \
++  { "target_fix_v4bx_spec",   TARGET_FIX_V4BX_SPEC }, \
++  NETBSD_SUBTARGET_EXTRA_SPECS
++
++#define NETBSD_ENTRY_POINT "__start"
++
++#undef LINK_SPEC
++#define LINK_SPEC \
++  "-X %{mbig-endian:-EB -m %(linker_big_emulation)} \
++   %{mlittle-endian:-EL -m %(linker_liitle_emulation)} \
++   %{!mbig-endian:%{!mlittle-endian:-m %(linker_emulation)}} \
++   %(be8_link_spec) %(target_fix_v4bx_spec) \
++   %(netbsd_link_spec)"
Index: pkgsrc/lang/gcc7/patches/patch-gcc_config_arm_netbsd-elf.h
diff -u /dev/null pkgsrc/lang/gcc7/patches/patch-gcc_config_arm_netbsd-elf.h:1.1
--- /dev/null   Sun Jun 17 19:50:53 2018
+++ pkgsrc/lang/gcc7/patches/patch-gcc_config_arm_netbsd-elf.h  Sun Jun 17 19:50:52 2018
@@ -0,0 +1,96 @@
+$NetBSD: patch-gcc_config_arm_netbsd-elf.h,v 1.1 2018/06/17 19:50:52 maya Exp $
+
+netbsd/arm EABI support
+
+--- gcc/config/arm/netbsd-elf.h.orig   2017-01-01 12:07:43.000000000 +0000
++++ gcc/config/arm/netbsd-elf.h
+@@ -27,9 +27,20 @@
+ 
+ /* arm.h defaults to ARM6 CPU.  */
+ 
+-/* This defaults us to little-endian.  */
+-#ifndef TARGET_ENDIAN_DEFAULT
+-#define TARGET_ENDIAN_DEFAULT 0
++/* Default EABI to armv5t so that thumb shared libraries work.
++   The ARM926EH-S core is the default for armv5te, so set
++   SUBTARGET_CPU_DEFAULT to achieve this.  */
++
++#define SUBTARGET_CPU_DEFAULT \
++      (ARM_DEFAULT_ABI != ARM_ABI_APCS && ARM_DEFAULT_ABI != ARM_ABI_ATPCS \
++          ? TARGET_CPU_arm926ejs : TARGET_CPU_arm6)
++
++/* TARGET_BIG_ENDIAN_DEFAULT is set in
++   config.gcc for big endian configurations.  */
++#if TARGET_BIG_ENDIAN_DEFAULT
++#define TARGET_ENDIAN_DEFAULT    MASK_BIG_END
++#else
++#define TARGET_ENDIAN_DEFAULT    0
+ #endif
+ 
+ #undef MULTILIB_DEFAULTS
+@@ -43,6 +54,7 @@
+ #undef ARM_DEFAULT_ABI
+ #define ARM_DEFAULT_ABI ARM_ABI_ATPCS
+ 
++#undef TARGET_OS_CPP_BUILTINS
+ #define TARGET_OS_CPP_BUILTINS()      \
+   do                                  \
+     {                                 \
+@@ -55,25 +67,21 @@
+ 
+ #undef SUBTARGET_EXTRA_ASM_SPEC
+ #define SUBTARGET_EXTRA_ASM_SPEC      \
+-  "-matpcs %{" FPIE_OR_FPIC_SPEC ":-k}"
++  "-matpcs %{mabi=aapcs*:-meabi=5} %{" FPIE_OR_FPIC_SPEC ":-k}"
+ 
+ /* Default to full VFP if -mfloat-abi=hard is specified.  */
+ #undef SUBTARGET_ASM_FLOAT_SPEC
+ #define SUBTARGET_ASM_FLOAT_SPEC      \
+-  "%{mfloat-abi=hard:{!mfpu=*:-mfpu=vfp}}"
+-
+-#undef SUBTARGET_EXTRA_SPECS
+-#define SUBTARGET_EXTRA_SPECS                         \
+-  { "subtarget_extra_asm_spec",       SUBTARGET_EXTRA_ASM_SPEC }, \
+-  { "subtarget_asm_float_spec", SUBTARGET_ASM_FLOAT_SPEC }, \
+-  { "netbsd_link_spec",               NETBSD_LINK_SPEC_ELF }, \
+-  { "netbsd_entry_point",     NETBSD_ENTRY_POINT },
++  "%{mhard-float:%{!mfpu=*:-mfpu=vfp}}   \
++   %{mfloat-abi=hard:%{!mfpu=*:-mfpu=vfp}}"
+ 
+ #define NETBSD_ENTRY_POINT "__start"
+ 
+ #undef LINK_SPEC
+ #define LINK_SPEC \
+-  "-X %{mbig-endian:-EB} %{mlittle-endian:-EL} \
++  "-X \
++   %{mbig-endian:-EB %{-mabi=aapcs*:-m armelfb_nbsd_eabi}} \
++   %{mlittle-endian:-EL %{-mabi=aapcs*:-m armelf_nbsd_eabi}} \
+    %(netbsd_link_spec)"
+ 
+ /* Make GCC agree with <machine/ansi.h>.  */
+@@ -84,6 +92,12 @@
+ #undef PTRDIFF_TYPE
+ #define PTRDIFF_TYPE "long int"
+ 
++#undef INTPTR_TYPE
++#define INTPTR_TYPE PTRDIFF_TYPE
++
++#undef UINTPTR_TYPE
++#define UINTPTR_TYPE SIZE_TYPE
++
+ /* We don't have any limit on the length as out debugger is GDB.  */
+ #undef DBX_CONTIN_LENGTH
+ 
+@@ -157,3 +171,12 @@ while (0)
+ #undef FPUTYPE_DEFAULT
+ #define FPUTYPE_DEFAULT "vfp"
+ 
++/* Ensure that libgcc does not attempt to define __[CD]TOR_LIST__[] for APCS,
++   which belongs in crtbegin on NetBSD.  */
++#ifndef __ARM_EABI__
++#define CTOR_LISTS_DEFINED_EXTERNALLY
++#endif
++
++#undef FPUTYPE_DEFAULT
++#define FPUTYPE_DEFAULT "vfp"
++
Index: pkgsrc/lang/gcc7/patches/patch-gcc_config_netbsd-elf.h
diff -u /dev/null pkgsrc/lang/gcc7/patches/patch-gcc_config_netbsd-elf.h:1.1
--- /dev/null   Sun Jun 17 19:50:53 2018
+++ pkgsrc/lang/gcc7/patches/patch-gcc_config_netbsd-elf.h      Sun Jun 17 19:50:52 2018
@@ -0,0 +1,34 @@
+$NetBSD: patch-gcc_config_netbsd-elf.h,v 1.1 2018/06/17 19:50:52 maya Exp $
+
+Need NETBSD_SUBTARGET_EXTRA_SPECS for netbsd-eabi.h file.
+
+--- gcc/config/netbsd-elf.h.orig       2017-01-01 12:07:43.000000000 +0000
++++ gcc/config/netbsd-elf.h
+@@ -67,6 +67,9 @@ along with GCC; see the file COPYING3.  
+ 
+    Target-specific code must provide the %(netbsd_entry_point) spec.  */
+ 
++#define NETBSD_LINK_LD_ELF_SO_SPEC \
++  "%{!dynamic-linker:-dynamic-linker /usr/libexec/ld.elf_so}"
++
+ #define NETBSD_LINK_SPEC_ELF \
+   "%{assert*} %{R*} %{rpath*} \
+    %{shared:-shared} \
+@@ -81,6 +84,17 @@ along with GCC; see the file COPYING3.  
+        -dynamic-linker /usr/libexec/ld.elf_so} \
+      %{static:-static}}"
+ 
++/* Provide the standard list of subtarget extra specs for NetBSD targets.  */
++#define NETBSD_SUBTARGET_EXTRA_SPECS \
++  { "netbsd_link_ld_elf_so",    NETBSD_LINK_LD_ELF_SO_SPEC }, \
++  { "netbsd_cpp_spec",          NETBSD_CPP_SPEC }, \
++  { "netbsd_link_spec",         NETBSD_LINK_SPEC_ELF }, \
++  { "netbsd_entry_point",       NETBSD_ENTRY_POINT }, \
++  { "netbsd_endfile_spec",      NETBSD_ENDFILE_SPEC },
++
++#undef SUBTARGET_EXTRA_SPECS
++#define SUBTARGET_EXTRA_SPECS   NETBSD_SUBTARGET_EXTRA_SPECS
++
+ /* Use --as-needed -lgcc_s for eh support.  */
+ #ifdef HAVE_LD_AS_NEEDED
+ #define USE_LD_AS_NEEDED 1
Index: pkgsrc/lang/gcc7/patches/patch-gcc_ginclude_stddef.h
diff -u /dev/null pkgsrc/lang/gcc7/patches/patch-gcc_ginclude_stddef.h:1.1
--- /dev/null   Sun Jun 17 19:50:53 2018
+++ pkgsrc/lang/gcc7/patches/patch-gcc_ginclude_stddef.h        Sun Jun 17 19:50:52 2018
@@ -0,0 +1,62 @@
+$NetBSD: patch-gcc_ginclude_stddef.h,v 1.1 2018/06/17 19:50:52 maya Exp $
+
+handle netbsd/arm not using the same include guards for
+ansi.h as other archs
+
+--- gcc/ginclude/stddef.h.orig 2017-01-01 12:07:43.000000000 +0000
++++ gcc/ginclude/stddef.h
+@@ -46,9 +46,7 @@ see the files COPYING3 and COPYING.RUNTI
+ /* This avoids lossage on SunOS but only if stdtypes.h comes first.
+    There's no way to win with the other order!  Sun lossage.  */
+ 
+-/* On 4.3bsd-net2, make sure ansi.h is included, so we have
+-   one less case to deal with in the following.  */
+-#if defined (__BSD_NET2__) || defined (____386BSD____) || (defined (__FreeBSD__) && (__FreeBSD__ < 5)) || defined(__NetBSD__)
++#if defined(__NetBSD__)
+ #include <machine/ansi.h>
+ #endif
+ /* On FreeBSD 5, machine/ansi.h does not exist anymore... */
+@@ -56,11 +54,7 @@ see the files COPYING3 and COPYING.RUNTI
+ #include <sys/_types.h>
+ #endif
+ 
+-/* In 4.3bsd-net2, machine/ansi.h defines these symbols, which are
+-   defined if the corresponding type is *not* defined.
+-   FreeBSD-2.1 defines _MACHINE_ANSI_H_ instead of _ANSI_H_.
+-   NetBSD defines _I386_ANSI_H_ and _X86_64_ANSI_H_ instead of _ANSI_H_ */
+-#if defined(_ANSI_H_) || defined(_MACHINE_ANSI_H_) || defined(_X86_64_ANSI_H_)  || defined(_I386_ANSI_H_)
++#if defined(__NetBSD__)
+ #if !defined(_SIZE_T_) && !defined(_BSD_SIZE_T_)
+ #define _SIZE_T
+ #endif
+@@ -87,7 +81,7 @@ see the files COPYING3 and COPYING.RUNTI
+ #undef _WCHAR_T_
+ #undef _BSD_WCHAR_T_
+ #endif
+-#endif /* defined(_ANSI_H_) || defined(_MACHINE_ANSI_H_) || defined(_X86_64_ANSI_H_) || defined(_I386_ANSI_H_) */
++#endif /* defined(__NetBSD__) */
+ 
+ /* Sequent's header files use _PTRDIFF_T_ in some conflicting way.
+    Just ignore it.  */
+@@ -359,11 +353,7 @@ typedef __WINT_TYPE__ wint_t;
+ #undef __need_wint_t
+ #endif
+ 
+-/*  In 4.3bsd-net2, leave these undefined to indicate that size_t, etc.
+-    are already defined.  */
+-/*  BSD/OS 3.1 and FreeBSD [23].x require the MACHINE_ANSI_H check here.  */
+-/*  NetBSD 5 requires the I386_ANSI_H and X86_64_ANSI_H checks here.  */
+-#if defined(_ANSI_H_) || defined(_MACHINE_ANSI_H_) || defined(_X86_64_ANSI_H_) || defined(_I386_ANSI_H_)
++#if defined(__NetBSD__)
+ /*  The references to _GCC_PTRDIFF_T_, _GCC_SIZE_T_, and _GCC_WCHAR_T_
+     are probably typos and should be removed before 2.8 is released.  */
+ #ifdef _GCC_PTRDIFF_T_
+@@ -391,7 +381,7 @@ typedef __WINT_TYPE__ wint_t;
+ #undef _WCHAR_T_
+ #undef _BSD_WCHAR_T_
+ #endif
+-#endif /* _ANSI_H_ || _MACHINE_ANSI_H_ || _X86_64_ANSI_H_ || _I386_ANSI_H_ */
++#endif /* __NetBSD__ */
+ 
+ #endif /* __sys_stdtypes_h */
+ 
Index: pkgsrc/lang/gcc7/patches/patch-libgcc_config.host
diff -u /dev/null pkgsrc/lang/gcc7/patches/patch-libgcc_config.host:1.1
--- /dev/null   Sun Jun 17 19:50:53 2018
+++ pkgsrc/lang/gcc7/patches/patch-libgcc_config.host   Sun Jun 17 19:50:52 2018
@@ -0,0 +1,24 @@
+$NetBSD: patch-libgcc_config.host,v 1.1 2018/06/17 19:50:52 maya Exp $
+
+netbsd/arm EABI support
+
+--- libgcc/config.host.orig    2018-01-08 13:39:11.000000000 +0000
++++ libgcc/config.host
+@@ -396,7 +396,16 @@ arm*-*-freebsd*)                # ARM Fr
+       tmake_file="${tmake_file} t-softfp-sfdf t-softfp-excl arm/t-softfp t-softfp"
+       ;;
+ arm*-*-netbsdelf*)
+-      tmake_file="$tmake_file arm/t-arm arm/t-netbsd t-slibgcc-gld-nover"
++      tmake_file="$tmake_file arm/t-arm"
++      case ${host} in
++      arm*-*-netbsdelf-*eabi*)
++        tmake_file="${tmake_file} arm/t-netbsd-eabi"
++        unwind_header=config/arm/unwind-arm.h
++      ;;
++      *)
++        tmake_file="${tmake_file} arm/t-netbsd t-slibgcc-gld-nover"
++        ;;
++      esac
+       ;;
+ arm*-*-linux*)                        # ARM GNU/Linux with ELF
+       tmake_file="${tmake_file} arm/t-arm t-fixedpoint-gnu-prefix t-crtfm"
Index: pkgsrc/lang/gcc7/patches/patch-libgcc_config_arm_t-netbsd
diff -u /dev/null pkgsrc/lang/gcc7/patches/patch-libgcc_config_arm_t-netbsd:1.1
--- /dev/null   Sun Jun 17 19:50:53 2018
+++ pkgsrc/lang/gcc7/patches/patch-libgcc_config_arm_t-netbsd   Sun Jun 17 19:50:52 2018
@@ -0,0 +1,27 @@
+$NetBSD: patch-libgcc_config_arm_t-netbsd,v 1.1 2018/06/17 19:50:52 maya Exp $
+
+Update arm t-netbsd from netbsd's base.
+
+--- libgcc/config/arm/t-netbsd.orig    2011-11-02 15:23:48.000000000 +0000
++++ libgcc/config/arm/t-netbsd
+@@ -1,7 +1,18 @@
++# This list is from t-elf, but with some things removed.
++LIB1ASMFUNCS += _udivsi3 _divsi3 _umodsi3 _modsi3 _dvmd_tls _bb_init_func \
++      _call_via_rX _interwork_call_via_rX \
++      _arm_fixunsdfsi _arm_fixunssfsi \
++      _arm_floatdidf _arm_floatdisf _arm_floatundidf _arm_floatundisf \
++      _lshrdi3 _ashrdi3 _ashldi3 \
++      _clzsi2 _clzdi2 _ctzsi2
++
+ # Just for these, we omit the frame pointer since it makes such a big
+ # difference.  It is then pointless adding debugging.
+ HOST_LIBGCC2_CFLAGS += -fomit-frame-pointer
+ 
+-LIBGCC2_DEBUG_CFLAGS = -g0
+-
+ LIB2ADD += $(srcdir)/floatunsidf.c $(srcdir)/floatunsisf.c
++
++# Currently there is a bug somewhere in GCC's alias analysis
++# or scheduling code that is breaking _fpmul_parts in fp-bit.c.
++# Disabling function inlining is a workaround for this problem.
++HOST_LIBGCC2_CFLAGS += -fno-inline
Index: pkgsrc/lang/gcc7/patches/patch-libgcc_config_arm_t-netbsd-eabi
diff -u /dev/null pkgsrc/lang/gcc7/patches/patch-libgcc_config_arm_t-netbsd-eabi:1.1
--- /dev/null   Sun Jun 17 19:50:53 2018
+++ pkgsrc/lang/gcc7/patches/patch-libgcc_config_arm_t-netbsd-eabi      Sun Jun 17 19:50:52 2018
@@ -0,0 +1,26 @@
+$NetBSD: patch-libgcc_config_arm_t-netbsd-eabi,v 1.1 2018/06/17 19:50:52 maya Exp $
+
+netbsd/arm EABI support
+
+--- libgcc/config/arm/t-netbsd-eabi.orig       2018-06-15 14:49:36.798627201 +0000
++++ libgcc/config/arm/t-netbsd-eabi
+@@ -0,0 +1,19 @@
++# This list is from t-elf, but with lots removed.
++LIB1ASMFUNCS += _dvmd_tls _bb_init_func _call_via_rX _interwork_call_via_rX \
++        _clzsi2 _clzdi2 _ctzsi2
++
++# Derived from t-bpabi
++# Add the BPABI C functions.
++LIB2ADD +=    $(srcdir)/config/arm/unaligned-funcs.c
++
++LIB2ADDEH = $(srcdir)/config/arm/unwind-arm.c \
++  $(srcdir)/config/arm/libunwind.S \
++  $(srcdir)/config/arm/pr-support.c $(srcdir)/unwind-c.c
++
++# Add the BPABI names.
++SHLIB_MAPFILES += $(srcdir)/config/arm/libgcc-bpabi.ver
++
++# On ARM, specifying -fnon-call-exceptions will needlessly pull in
++# the unwinder in simple programs which use 64-bit division.  Omitting
++# the option is safe.
++LIB2_DIVMOD_EXCEPTION_FLAGS := -fexceptions



Home | Main Index | Thread Index | Old Index