View | Details | Raw Unified | Return to bug 166718
Collapse All | Expand All

(-)Makefile (-19 / +13 lines)
Lines 17-43 Link Here
17
MAINTAINER=	draco@marino.st
17
MAINTAINER=	draco@marino.st
18
COMMENT=	GNAT Ada compiler based on GCC ${GCC_BRANCH}
18
COMMENT=	GNAT Ada compiler based on GCC ${GCC_BRANCH}
19
19
20
LIB_DEPENDS=	gmp.10:${PORTSDIR}/math/gmp
20
.include "${.CURDIR}/Makefile.common"
21
LIB_DEPENDS+=	mpfr.4:${PORTSDIR}/math/mpfr
21
22
LIB_DEPENDS+=	mpc.2:${PORTSDIR}/math/mpc
23
24
ONLY_FOR_ARCHS=	i386 amd64
25
26
GNU_CONFIGURE=		yes
27
USE_GMAKE=		yes
28
USE_BZIP2=		yes
29
USE_ICONV=		yes
30
USE_PERL5_BUILD=	yes
31
ALL_TARGET=		default
32
MAKE_JOBS_SAFE=		yes
33
34
SNAPSHOT=		20111026
35
GCC_BRANCH=		4.6
36
GCC_POINT=		2
37
GCC_VERSION=		${GCC_BRANCH}.${GCC_POINT}
38
LANGS=			c
22
LANGS=			c
39
APPLY_DIFFS=		core
23
APPLY_DIFFS=		core
40
41
INTENDED_COMPILER=	NATIVE
24
INTENDED_COMPILER=	NATIVE
42
BOOTSTRAP_COMPILER=	NOT_REQUIRED
25
BOOTSTRAP_COMPILER=	NOT_REQUIRED
43
BOOTSTRAP_TRIPLET=	NOT_SET
26
BOOTSTRAP_TRIPLET=	NOT_SET
Lines 287-291 Link Here
287
	${ECHO_CMD} "@unexec ${RMDIR} %D/include/c++               2>/dev/null || true" >> ${WRKDIR}/PLIST.lib
270
	${ECHO_CMD} "@unexec ${RMDIR} %D/include/c++               2>/dev/null || true" >> ${WRKDIR}/PLIST.lib
288
271
289
	cd ${WRKDIR}; ${SED} -i -e "/PLIST.lib/ r PLIST.lib" ${TMPPLIST}
272
	cd ${WRKDIR}; ${SED} -i -e "/PLIST.lib/ r PLIST.lib" ${TMPPLIST}
273
.if ${OSVERSION} > 900000
274
	@${ECHO_MSG} "========================================================"
275
	@${ECHO_MSG} " NOTICE REGARDING ADA TASKING ON FREEBSD 9.x:"
276
	@${ECHO_MSG} " Due to a new resource check in the threading library"
277
	@${ECHO_MSG} " starting with FreeBSD 9.0, an exiting task panics with"
278
	@${ECHO_MSG} " the message 'thread exits with resources held!'."
279
	@${ECHO_MSG} " Essentially this behavior breaks Ada tasking and 23"
280
	@${ECHO_MSG} " ACATS tests fail on FreeBSD 9.x. A solution is being"
281
	@${ECHO_MSG} " sought, but the necessary patches will not be trivial."
282
	@${ECHO_MSG} "========================================================"
283
.endif
290
284
291
.include <bsd.port.post.mk>
285
.include <bsd.port.post.mk>
(-)Makefile.common (+21 lines)
Added Link Here
1
# $FreeBSD$
2
3
LIB_DEPENDS=		gmp.10:${PORTSDIR}/math/gmp
4
LIB_DEPENDS+=		mpfr.4:${PORTSDIR}/math/mpfr
5
LIB_DEPENDS+=		mpc.2:${PORTSDIR}/math/mpc
6
7
ONLY_FOR_ARCHS= 	i386 amd64
8
9
GNU_CONFIGURE=		yes
10
USE_GMAKE=		yes
11
USE_BZIP2=		yes
12
USE_ICONV=		yes
13
USE_PERL5_BUILD=	yes
14
ALL_TARGET=		default
15
MAKE_JOBS_SAFE= 	yes
16
17
SNAPSHOT=		20120301
18
GCC_BRANCH=		4.6
19
GCC_POINT=		3
20
GCC_VERSION=		${GCC_BRANCH}.${GCC_POINT}
21
(-)distinfo (-12 / +12 lines)
Lines 1-15 Link Here
1
SHA256 (gcc-core-4.6.2.tar.bz2) = dcbf391f05277b7e09d14d54f3bdaba5515a3a8e7dd1d8af93af3f6f68455e10
1
SHA256 (gcc-core-4.6.3.tar.bz2) = 283e00881c0de258fafc5170843e4d9b14ee2a7dc4426f0d426e6be0400251c1
2
SIZE (gcc-core-4.6.2.tar.bz2) = 30258326
2
SIZE (gcc-core-4.6.3.tar.bz2) = 30305971
3
SHA256 (gcc-ada-4.6.2.tar.bz2) = 9ac26821ad900d02ed251b62e6a0506ee12417b506a7bb9b02ec9f09e5d9c84f
3
SHA256 (gcc-ada-4.6.3.tar.bz2) = 7bb213ec3948646df72720580fcba3489c84aa452bd0e4238712607ef83cbdf6
4
SIZE (gcc-ada-4.6.2.tar.bz2) = 6064757
4
SIZE (gcc-ada-4.6.3.tar.bz2) = 6092418
5
SHA256 (gcc-g++-4.6.2.tar.bz2) = 5470bea8093438cf5840fbbef3546b6dba7b0153ef6a16e142c1fba1fac6e598
5
SHA256 (gcc-g++-4.6.3.tar.bz2) = b3e0c733e900e99096b0c5480f57e22e3e583ec3d83596cc2cb9986bd64b29e8
6
SIZE (gcc-g++-4.6.2.tar.bz2) = 6955594
6
SIZE (gcc-g++-4.6.3.tar.bz2) = 6928430
7
SHA256 (gcc-fortran-4.6.2.tar.bz2) = 492becd732662349eaa5e7c4e458ac009df0ccb8904df54ae295d277c4d6be6f
7
SHA256 (gcc-fortran-4.6.3.tar.bz2) = fe1bdf3485f33e6d0a998ff7bcb42526fbf3083dbfc107c3d95a88c00739eadb
8
SIZE (gcc-fortran-4.6.2.tar.bz2) = 1676539
8
SIZE (gcc-fortran-4.6.3.tar.bz2) = 1676490
9
SHA256 (gcc-objc-4.6.2.tar.bz2) = 74cc0e46c7455f3781c740e0f49e06355d8b04a32cb6f015d2bfde39a9ad1dd4
9
SHA256 (gcc-objc-4.6.3.tar.bz2) = 4c193397ce0b8b7b3a6b090078f7228e22999edb14a53480ac709f7f165a4ca3
10
SIZE (gcc-objc-4.6.2.tar.bz2) = 342544
10
SIZE (gcc-objc-4.6.3.tar.bz2) = 342441
11
SHA256 (gcc-testsuite-4.6.2.tar.bz2) = 146e2ec50913515989405162e8e861e17d710c3ca1d4d19073527ea24a0ef81e
11
SHA256 (gcc-testsuite-4.6.3.tar.bz2) = a3448d09e5e8ce6baee4080981efc85e6af1621b66a68258dd645c04ae381bed
12
SIZE (gcc-testsuite-4.6.2.tar.bz2) = 6309400
12
SIZE (gcc-testsuite-4.6.3.tar.bz2) = 6354781
13
SHA256 (gnat-bootstrap.i386.freebsd.tar.bz2) = c38e1c960f651c3f248c1ef540b1df724058fa71c1d046af93ce975483abb645
13
SHA256 (gnat-bootstrap.i386.freebsd.tar.bz2) = c38e1c960f651c3f248c1ef540b1df724058fa71c1d046af93ce975483abb645
14
SIZE (gnat-bootstrap.i386.freebsd.tar.bz2) = 27973176
14
SIZE (gnat-bootstrap.i386.freebsd.tar.bz2) = 27973176
15
SHA256 (gnat-bootstrap.x86_64.freebsd.tar.bz2) = c4abd6af1281785d47d99352e28e41b2a1455e25ff347eca0de5791cdede9ed8
15
SHA256 (gnat-bootstrap.x86_64.freebsd.tar.bz2) = c4abd6af1281785d47d99352e28e41b2a1455e25ff347eca0de5791cdede9ed8
(-)files/diff-ada (-7 / +7 lines)
Lines 782-790 Link Here
782
+ * will be copied.  Always NUL terminates (unless siz == 0).
782
+ * will be copied.  Always NUL terminates (unless siz == 0).
783
+ * Returns strlen(src); if retval >= siz, truncation occurred.
783
+ * Returns strlen(src); if retval >= siz, truncation occurred.
784
+ *
784
+ *
785
+ * $OpenBSD: strlcpy.c,v 1.11 2006/05/05 15:27:38 millert Exp $
785
+ * OpenBSD: strlcpy.c,v 1.11 2006/05/05 15:27:38 millert Exp
786
+ * $FreeBSD: ports/lang/gnat-aux/files/diff-ada,v 1.1 2012/01/12 14:24:37 culot Exp $
786
+ * FreeBSD: src/lib/libc/string/strlcpy.c,v 1.10 2008/10/19 delphij Exp
787
+ * $DragonFly: src/lib/libc/string/strlcpy.c,v 1.4 2005/09/18 asmodai Exp $
787
+ * DragonFly: src/lib/libc/string/strlcpy.c,v 1.4 2005/09/18 asmodai Exp
788
+ */
788
+ */
789
+
789
+
790
+size_t
790
+size_t
Lines 823-831 Link Here
823
+ * Returns strlen(src) + MIN(siz, strlen(initial dst)).
823
+ * Returns strlen(src) + MIN(siz, strlen(initial dst)).
824
+ * If retval >= siz, truncation occurred.
824
+ * If retval >= siz, truncation occurred.
825
+ *
825
+ *
826
+ * $OpenBSD: strlcat.c,v 1.13 2005/08/08 08:05:37 espie Exp $
826
+ * OpenBSD: strlcat.c,v 1.13 2005/08/08 08:05:37 espie Exp
827
+ * $FreeBSD: ports/lang/gnat-aux/files/diff-ada,v 1.1 2012/01/12 14:24:37 culot Exp $
827
+ * FreeBSD: src/lib/libc/string/strlcat.c,v 1.11 2009/01/12 delphij Exp
828
+ * $DragonFly: src/lib/libc/string/strlcat.c,v 1.4 2004/12/18 asmodai Exp $
828
+ * DragonFly: src/lib/libc/string/strlcat.c,v 1.4 2004/12/18 asmodai Exp
829
+ */
829
+ */
830
+
830
+
831
+size_t
831
+size_t
Lines 2439-2445 Link Here
2439
 /* VxWorks Section */
2439
 /* VxWorks Section */
2440
 /*******************/
2440
 /*******************/
2441
 
2441
 
2442
@@ -2320,6 +2392,7 @@
2442
@@ -2341,6 +2413,7 @@
2443
 
2443
 
2444
 #if defined (_WIN32) || defined (__INTERIX) \
2444
 #if defined (_WIN32) || defined (__INTERIX) \
2445
   || defined (__Lynx__) || defined(__NetBSD__) || defined(__FreeBSD__) \
2445
   || defined (__Lynx__) || defined(__NetBSD__) || defined(__FreeBSD__) \
(-)files/diff-core (-15 / +42 lines)
Lines 290-296 Link Here
290
+#define UINTPTR_TYPE      (LONG_TYPE_SIZE == 64 ? UINT64_TYPE : UINT32_TYPE)
290
+#define UINTPTR_TYPE      (LONG_TYPE_SIZE == 64 ? UINT64_TYPE : UINT32_TYPE)
291
--- /dev/null
291
--- /dev/null
292
+++ gcc/config/dragonfly.h
292
+++ gcc/config/dragonfly.h
293
@@ -0,0 +1,141 @@
293
@@ -0,0 +1,139 @@
294
+/* Base configuration file for all DragonFly targets.
294
+/* Base configuration file for all DragonFly targets.
295
+   Copyright (C) 1999, 2000, 2001, 2007, 2008 Free Software Foundation, Inc.
295
+   Copyright (C) 1999, 2000, 2001, 2007, 2008 Free Software Foundation, Inc.
296
+   Copyright (C) 2010-2012 John R. Marino <www.dragonlace.net>
296
+   Copyright (C) 2010-2012 John R. Marino <www.dragonlace.net>
Lines 388-399 Link Here
388
+#undef  LINK_SPEC
388
+#undef  LINK_SPEC
389
+#define LINK_SPEC DFBSD_LINK_SPEC
389
+#define LINK_SPEC DFBSD_LINK_SPEC
390
+
390
+
391
+#define	DFBSD_DYNAMIC_LINKER \
391
+#define	DFBSD_DYNAMIC_LINKER "/usr/libexec/ld-elf.so.2"
392
+  "/usr/libexec/ld-elf.so.2"
393
+
392
+
394
+#if defined(HAVE_LD_EH_FRAME_HDR)
393
+#if defined(HAVE_LD_EH_FRAME_HDR)
395
+#define LINK_EH_SPEC \
394
+#define LINK_EH_SPEC "--eh-frame-hdr"
396
+  "%{!static:--eh-frame-hdr}"
397
+#endif
395
+#endif
398
+
396
+
399
+/* Use --as-needed -lgcc_s for eh support.  */
397
+/* Use --as-needed -lgcc_s for eh support.  */
Lines 1157-1167 Link Here
1157
 
1155
 
1158
 /* Put all *tf routines in libgcc.  */
1156
 /* Put all *tf routines in libgcc.  */
1159
 #undef LIBGCC2_HAS_TF_MODE
1157
 #undef LIBGCC2_HAS_TF_MODE
1160
@@ -147,3 +148,39 @@
1158
@@ -148,5 +149,38 @@
1161
 #if FBSD_MAJOR >= 6
1162
 #define SUBTARGET32_DEFAULT_CPU "i486"
1159
 #define SUBTARGET32_DEFAULT_CPU "i486"
1163
 #endif
1160
 #endif
1164
+
1161
 
1162
-#define TARGET_ASM_FILE_END file_end_indicate_exec_stack
1165
+/* Define location of OS-specific unwind support configuration. */
1163
+/* Define location of OS-specific unwind support configuration. */
1166
+#define MD_UNWIND_SUPPORT "config/i386/freebsd-unwind.h"
1164
+#define MD_UNWIND_SUPPORT "config/i386/freebsd-unwind.h"
1167
+
1165
+
Lines 1196-1202 Link Here
1196
+  (void) mprotect (page, ends - page, perms);            \
1194
+  (void) mprotect (page, ends - page, perms);            \
1197
+}
1195
+}
1198
+
1196
+
1199
+
1197
 
1200
--- gcc/config/i386/netbsd-elf.h.orig
1198
--- gcc/config/i386/netbsd-elf.h.orig
1201
+++ gcc/config/i386/netbsd-elf.h
1199
+++ gcc/config/i386/netbsd-elf.h
1202
@@ -2,6 +2,7 @@
1200
@@ -2,6 +2,7 @@
Lines 1787-1793 Link Here
1787
 
1785
 
1788
 #This file is part of GCC.
1786
 #This file is part of GCC.
1789
 
1787
 
1790
@@ -166,6 +167,8 @@
1788
@@ -157,6 +158,8 @@
1791
   ;;
1789
   ;;
1792
 *-*-openbsd*)
1790
 *-*-openbsd*)
1793
   ;;
1791
   ;;
Lines 1796-1802 Link Here
1796
 *-*-rtems*)
1794
 *-*-rtems*)
1797
   ;;
1795
   ;;
1798
 *-*-vxworks*)
1796
 *-*-vxworks*)
1799
@@ -287,6 +290,14 @@
1797
@@ -278,6 +281,14 @@
1800
 x86_64-*-freebsd*)
1798
 x86_64-*-freebsd*)
1801
 	tmake_file="${tmake_file} i386/t-freebsd"
1799
 	tmake_file="${tmake_file} i386/t-freebsd"
1802
 	;;
1800
 	;;
Lines 1811-1817 Link Here
1811
 i[34567]86-*-netbsdelf*)
1809
 i[34567]86-*-netbsdelf*)
1812
 	;;
1810
 	;;
1813
 i[34567]86-*-netbsd*)
1811
 i[34567]86-*-netbsd*)
1814
@@ -297,6 +308,8 @@
1812
@@ -288,6 +299,8 @@
1815
 	;;
1813
 	;;
1816
 i[34567]86-*-openbsd*)
1814
 i[34567]86-*-openbsd*)
1817
 	;;
1815
 	;;
Lines 1820-1826 Link Here
1820
 i[34567]86-*-linux* | i[34567]86-*-kfreebsd*-gnu | i[34567]86-*-knetbsd*-gnu | i[34567]86-*-gnu*)
1818
 i[34567]86-*-linux* | i[34567]86-*-kfreebsd*-gnu | i[34567]86-*-knetbsd*-gnu | i[34567]86-*-gnu*)
1821
 	extra_parts="$extra_parts crtprec32.o crtprec64.o crtprec80.o crtfastmath.o"
1819
 	extra_parts="$extra_parts crtprec32.o crtprec64.o crtprec80.o crtfastmath.o"
1822
 	tmake_file="${tmake_file} i386/t-crtpc i386/t-crtfm"
1820
 	tmake_file="${tmake_file} i386/t-crtpc i386/t-crtfm"
1823
@@ -628,6 +641,9 @@
1821
@@ -619,6 +632,9 @@
1824
 		tmake_file="${tmake_file} t-softfp i386/${host_address}/t-fprules-softfp"
1822
 		tmake_file="${tmake_file} t-softfp i386/${host_address}/t-fprules-softfp"
1825
 	fi
1823
 	fi
1826
 	;;
1824
 	;;
Lines 1837-1843 Link Here
1837
+SHLIB_MAPFILES += $(srcdir)/config/i386/libgcc-bsd.ver
1835
+SHLIB_MAPFILES += $(srcdir)/config/i386/libgcc-bsd.ver
1838
--- gcc/configure.orig
1836
--- gcc/configure.orig
1839
+++ gcc/configure
1837
+++ gcc/configure
1840
@@ -25843,6 +25843,20 @@
1838
@@ -25833,6 +25833,20 @@
1841
       gcc_cv_target_dl_iterate_phdr=no
1839
       gcc_cv_target_dl_iterate_phdr=no
1842
     fi
1840
     fi
1843
     ;;
1841
     ;;
Lines 1890-1898 Link Here
1890
 
1888
 
1891
 $(DESTDIR)$(man7dir)/%$(man7ext): doc/%.7 installdirs
1889
 $(DESTDIR)$(man7dir)/%$(man7ext): doc/%.7 installdirs
1892
 	-rm -f $@
1890
 	-rm -f $@
1891
--- libiberty/getpagesize.c.orig
1892
+++ libiberty/getpagesize.c
1893
@@ -20,6 +20,7 @@
1894
 
1895
 */
1896
 
1897
+#ifndef __ANDROID__
1898
 #ifndef VMS
1899
 
1900
 #include "config.h"
1901
@@ -88,3 +89,4 @@
1902
 }
1903
 
1904
 #endif /* VMS */
1905
+#endif /* __ANDROID__ */
1906
--- libiberty/setproctitle.c.orig
1907
+++ libiberty/setproctitle.c
1908
@@ -40,9 +40,11 @@
1909
 void
1910
 setproctitle (const char *name ATTRIBUTE_UNUSED, ...)
1911
 {
1912
+#ifndef __ANDROID__
1913
 #ifdef PR_SET_NAME
1914
   /* On Linux this sets the top visible "comm", but not necessarily
1915
      the name visible in ps. */
1916
   prctl (PR_SET_NAME, name);
1917
 #endif
1918
+#endif
1919
 }
1893
--- configure.orig
1920
--- configure.orig
1894
+++ configure
1921
+++ configure
1895
@@ -14200,7 +14200,7 @@
1922
@@ -14196,7 +14196,7 @@
1896
 _ACEOF
1923
 _ACEOF
1897
 if ac_fn_c_try_compile "$LINENO"; then :
1924
 if ac_fn_c_try_compile "$LINENO"; then :
1898
   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
1925
   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
(-)files/diff-fortran (+20 lines)
Lines 52-54 Link Here
52
 
52
 
53
 install-dvi: install-dvi-am
53
 install-dvi: install-dvi-am
54
 
54
 
55
--- gcc/testsuite/gfortran.dg/large_real_kind_2.F90.orig
56
+++ gcc/testsuite/gfortran.dg/large_real_kind_2.F90
57
@@ -1,6 +1,6 @@
58
 ! { dg-do run }
59
 ! { dg-require-effective-target fortran_large_real }
60
-! { dg-xfail-if "" { "*-*-freebsd*" } { "*" }  { "" } }
61
+! { dg-xfail-if "" { *-*-freebsd* *-*-dragonfly* *-*-netbsd* } { "*" }  { "" } }
62
 
63
 ! Testing library calls on large real kinds (larger than kind=8)
64
   implicit none
65
--- gcc/testsuite/gfortran.dg/large_real_kind_3.F90.orig
66
+++ gcc/testsuite/gfortran.dg/large_real_kind_3.F90
67
@@ -1,6 +1,6 @@
68
 ! { dg-do run }
69
 ! { dg-require-effective-target fortran_large_real }
70
-! { dg-xfail-if "" { "*-*-freebsd*" } { "*" }  { "" } }
71
+! { dg-xfail-if "" { *-*-freebsd* *-*-dragonfly* *-*-netbsd* } { "*" }  { "" } }
72
 
73
 ! Testing erf and erfc library calls on large real kinds (larger than kind=8)
74
   implicit none

Return to bug 166718