[98488] trunk/dports/lang

jeremyhu at macports.org jeremyhu at macports.org
Sat Oct 6 14:49:32 PDT 2012


Revision: 98488
          http://trac.macports.org//changeset/98488
Author:   jeremyhu at macports.org
Date:     2012-10-06 14:49:31 -0700 (Sat, 06 Oct 2012)
Log Message:
-----------
gcc4[78]: Revert last commit ... it wasn't ready yet.

Modified Paths:
--------------
    trunk/dports/lang/gcc47/Portfile
    trunk/dports/lang/gcc47/files/gcc-PR-53453.patch
    trunk/dports/lang/gcc48/Portfile

Added Paths:
-----------
    trunk/dports/lang/gcc47/files/no-runtime-stubs.patch
    trunk/dports/lang/gcc48/files/no-runtime-stubs.patch

Modified: trunk/dports/lang/gcc47/Portfile
===================================================================
--- trunk/dports/lang/gcc47/Portfile	2012-10-06 21:45:20 UTC (rev 98487)
+++ trunk/dports/lang/gcc47/Portfile	2012-10-06 21:49:31 UTC (rev 98488)
@@ -51,9 +51,11 @@
 
 depends_skip_archcheck-append gcc_select ld64 cctools
 
-patchfiles          ppc_fde_encoding.diff  gcc-PR-53453.patch
+patchfiles          ppc_fde_encoding.diff
 patch.dir           ${workpath}/gcc-${version}
 
+patch.dir           ${workpath}/gcc-${version}
+
 set major           4.7
 
 worksrcdir          build
@@ -126,10 +128,10 @@
 if {${subport} == "libstdcxx"} {
     conflicts       libstdcxx-devel
 
-    post-patch {
-        # Force linking against a static libgcc
-        reinplace "/DENABLE_SHARED_LIBGCC/d" ${patch.dir}/gcc/Makefile.in
-    }
+    # We might want to consider adding this patch to the gcc subport as well
+    # since it removes stuff that doesn't really make sense in the context of
+    # MacPorts
+    patchfiles-append  no-runtime-stubs.patch
 
     depends_run-delete path:lib/libstdc\\\\+\\\\+.6.dylib:libstdcxx
 

Modified: trunk/dports/lang/gcc47/files/gcc-PR-53453.patch
===================================================================
--- trunk/dports/lang/gcc47/files/gcc-PR-53453.patch	2012-10-06 21:45:20 UTC (rev 98487)
+++ trunk/dports/lang/gcc47/files/gcc-PR-53453.patch	2012-10-06 21:49:31 UTC (rev 98488)
@@ -1,90 +0,0 @@
-http://gcc.gnu.org/ml/gcc-patches/2012-06/msg01181.html
-http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53453
-
-diff -uNr gcc/config/darwin.h gcc/config/darwin.h
---- gcc/config/darwin.h	2012-02-16 03:21:46.000000000 -0500
-+++ gcc/config/darwin.h	2012-06-08 08:54:25.000000000 -0400
-@@ -356,7 +356,9 @@
-      %{!Zbundle:%{pg:%{static:-lgcrt0.o}				    \
-                      %{!static:%{object:-lgcrt0.o}			    \
-                                %{!object:%{preload:-lgcrt0.o}		    \
--                                 %{!preload:-lgcrt1.o %(darwin_crt2)}}}}    \
-+                                 %{!preload:-lgcrt1.o                       \
-+                                 %:version-compare(>= 10.8 mmacosx-version-min= -no_new_main) \
-+                                 %(darwin_crt2)}}}}    \
-                 %{!pg:%{static:-lcrt0.o}				    \
-                       %{!static:%{object:-lcrt0.o}			    \
-                                 %{!object:%{preload:-lcrt0.o}		    \
-@@ -379,7 +381,7 @@
- #define DARWIN_CRT1_SPEC						\
-   "%:version-compare(!> 10.5 mmacosx-version-min= -lcrt1.o)		\
-    %:version-compare(>< 10.5 10.6 mmacosx-version-min= -lcrt1.10.5.o)	\
--   %:version-compare(>= 10.6 mmacosx-version-min= -lcrt1.10.6.o)	\
-+   %:version-compare(>< 10.6 10.8 mmacosx-version-min= -lcrt1.10.6.o)	\
-    %{fgnu-tm: -lcrttms.o}"
- 
- /* Default Darwin ASM_SPEC, very simple.  */
-@@ -414,6 +416,8 @@
- 
- #define TARGET_WANT_DEBUG_PUB_SECTIONS true
- 
-+#define TARGET_FORCE_AT_COMP_DIR true
-+
- /* When generating stabs debugging, use N_BINCL entries.  */
- 
- #define DBX_USE_BINCL
-diff -uNr gcc/doc/tm.texi gcc/doc/tm.texi
---- gcc/doc/tm.texi	2012-01-26 16:48:27.000000000 -0500
-+++ gcc/doc/tm.texi	2012-06-08 08:54:25.000000000 -0400
-@@ -9487,6 +9487,10 @@
- True if the @code{.debug_pubtypes} and @code{.debug_pubnames} sections should be emitted.  These sections are not used on most platforms, and in particular GDB does not use them.
- @end deftypevr
- 
-+ at deftypevr {Target Hook} bool TARGET_FORCE_AT_COMP_DIR
-+True if the @code{DW_AT_comp_dir} attribute should be emitted for each  compilation unit.  This attribute is required for the darwin linker  to emit debug information.
-+ at end deftypevr
-+
- @deftypevr {Target Hook} bool TARGET_DELAY_SCHED2
- True if sched2 is not to be run at its normal place.  This usually means it will be run as part of machine-specific reorg.
- @end deftypevr
-diff -uNr gcc/doc/tm.texi.in gcc/doc/tm.texi.in
---- gcc/doc/tm.texi.in	2012-01-26 16:48:27.000000000 -0500
-+++ gcc/doc/tm.texi.in	2012-06-08 08:54:25.000000000 -0400
-@@ -9386,6 +9386,8 @@
- 
- @hook TARGET_WANT_DEBUG_PUB_SECTIONS
- 
-+ at hook TARGET_FORCE_AT_COMP_DIR
-+
- @hook TARGET_DELAY_SCHED2
- 
- @hook TARGET_DELAY_VARTRACK
-diff -uNr gcc/dwarf2out.c gcc/dwarf2out.c
---- gcc/dwarf2out.c	2012-06-04 09:24:24.000000000 -0400
-+++ gcc/dwarf2out.c	2012-06-08 08:54:25.000000000 -0400
-@@ -22501,7 +22501,7 @@
-   /* Add the name for the main input file now.  We delayed this from
-      dwarf2out_init to avoid complications with PCH.  */
-   add_name_attribute (comp_unit_die (), remap_debug_filename (filename));
--  if (!IS_ABSOLUTE_PATH (filename))
-+  if (!IS_ABSOLUTE_PATH (filename) || targetm.force_at_comp_dir)
-     add_comp_dir_attribute (comp_unit_die ());
-   else if (get_AT (comp_unit_die (), DW_AT_comp_dir) == NULL)
-     {
-diff -uNr gcc/target.def gcc/target.def
---- gcc/target.def	2012-01-26 16:48:27.000000000 -0500
-+++ gcc/target.def	2012-06-08 08:54:25.000000000 -0400
-@@ -2748,6 +2748,13 @@
-  bool, false)
- 
- DEFHOOKPOD
-+(force_at_comp_dir,
-+ "True if the @code{DW_AT_comp_dir} attribute should be emitted for each \
-+ compilation unit.  This attribute is required for the darwin linker \
-+ to emit debug information.",
-+ bool, false)
-+
-+DEFHOOKPOD
- (delay_sched2, "True if sched2 is not to be run at its normal place.  \
- This usually means it will be run as part of machine-specific reorg.",
- bool, false)

Added: trunk/dports/lang/gcc47/files/no-runtime-stubs.patch
===================================================================
--- trunk/dports/lang/gcc47/files/no-runtime-stubs.patch	                        (rev 0)
+++ trunk/dports/lang/gcc47/files/no-runtime-stubs.patch	2012-10-06 21:49:31 UTC (rev 98488)
@@ -0,0 +1,34 @@
+--- gcc/config/darwin.h.orig	2012-09-13 20:20:33.000000000 -0700
++++ gcc/config/darwin.h	2012-09-13 20:23:03.000000000 -0700
+@@ -325,17 +325,8 @@ extern GTY(()) int darwin_ms_struct;
+ #undef REAL_LIBGCC_SPEC
+ #define REAL_LIBGCC_SPEC						   \
+    "%{static-libgcc|static: -lgcc_eh -lgcc;				   \
+-      shared-libgcc|fexceptions|fgnu-runtime:				   \
+-       %:version-compare(!> 10.5 mmacosx-version-min= -lgcc_s.10.4)	   \
+-       %:version-compare(>< 10.5 10.6 mmacosx-version-min= -lgcc_s.10.5)   \
+-       %:version-compare(!> 10.5 mmacosx-version-min= -lgcc_ext.10.4)	   \
+-       %:version-compare(>= 10.5 mmacosx-version-min= -lgcc_ext.10.5)	   \
+-       -lgcc ;								   \
+-      :%:version-compare(>< 10.3.9 10.5 mmacosx-version-min= -lgcc_s.10.4) \
+-       %:version-compare(>< 10.5 10.6 mmacosx-version-min= -lgcc_s.10.5)   \
+-       %:version-compare(!> 10.5 mmacosx-version-min= -lgcc_ext.10.4)	   \
+-       %:version-compare(>= 10.5 mmacosx-version-min= -lgcc_ext.10.5)	   \
+-       -lgcc }"
++      shared-libgcc|fexceptions|fgnu-runtime: -lgcc;			   \
++      : -lgcc }"
+ 
+ /* We specify crt0.o as -lcrt0.o so that ld will search the library path.
+ 
+--- libgcc/config/t-slibgcc-darwin.orig	2012-09-13 20:26:11.000000000 -0700
++++ libgcc/config/t-slibgcc-darwin	2012-09-13 20:27:08.000000000 -0700
+@@ -39,7 +39,7 @@ endif
+ 
+ LGCC_FILES = libgcc_s.$(SHLIB_SOVERSION)$(SHLIB_EXT)
+ LGCC_FILES += $(LGCC_STUBS)
+-LEXT_STUBS = libgcc_ext.10.4$(SHLIB_EXT) libgcc_ext.10.5$(SHLIB_EXT)
++LEXT_STUBS =
+ LGCC_FILES += $(LEXT_STUBS)
+ INSTALL_FILES=$(LGCC_FILES)
+ 
+

Modified: trunk/dports/lang/gcc48/Portfile
===================================================================
--- trunk/dports/lang/gcc48/Portfile	2012-10-06 21:45:20 UTC (rev 98487)
+++ trunk/dports/lang/gcc48/Portfile	2012-10-06 21:49:31 UTC (rev 98488)
@@ -7,7 +7,6 @@
 subport             libstdcxx-devel {}
 
 version             4.8-20120930
-# reset revision in libstdcxx-devel upon bump
 revision            1
 platforms           darwin
 categories          lang
@@ -108,14 +107,11 @@
 # TODO: Optimize this.  We don't need to actually bootstrap gcc to build libstdc++
 if {${subport} == "libstdcxx-devel"} {
     conflicts       libstdcxx
-
-    # delete this revision as well when bumping base version
-    revision 2
     
-    post-patch {
-        # Force linking against a static libgcc
-        reinplace "/DENABLE_SHARED_LIBGCC/d" ${patch.dir}/gcc/Makefile.in
-    }
+    # We might want to consider adding this patch to the gcc subport as well
+    # since it removes stuff that doesn't really make sense in the context of
+    # MacPorts
+    patchfiles-append  no-runtime-stubs.patch
 
     depends_run-delete port:${subport}
 

Added: trunk/dports/lang/gcc48/files/no-runtime-stubs.patch
===================================================================
--- trunk/dports/lang/gcc48/files/no-runtime-stubs.patch	                        (rev 0)
+++ trunk/dports/lang/gcc48/files/no-runtime-stubs.patch	2012-10-06 21:49:31 UTC (rev 98488)
@@ -0,0 +1,34 @@
+--- gcc/config/darwin.h.orig	2012-09-13 20:20:33.000000000 -0700
++++ gcc/config/darwin.h	2012-09-13 20:23:03.000000000 -0700
+@@ -325,17 +325,8 @@ extern GTY(()) int darwin_ms_struct;
+ #undef REAL_LIBGCC_SPEC
+ #define REAL_LIBGCC_SPEC						   \
+    "%{static-libgcc|static: -lgcc_eh -lgcc;				   \
+-      shared-libgcc|fexceptions|fgnu-runtime:				   \
+-       %:version-compare(!> 10.5 mmacosx-version-min= -lgcc_s.10.4)	   \
+-       %:version-compare(>< 10.5 10.6 mmacosx-version-min= -lgcc_s.10.5)   \
+-       %:version-compare(!> 10.5 mmacosx-version-min= -lgcc_ext.10.4)	   \
+-       %:version-compare(>= 10.5 mmacosx-version-min= -lgcc_ext.10.5)	   \
+-       -lgcc ;								   \
+-      :%:version-compare(>< 10.3.9 10.5 mmacosx-version-min= -lgcc_s.10.4) \
+-       %:version-compare(>< 10.5 10.6 mmacosx-version-min= -lgcc_s.10.5)   \
+-       %:version-compare(!> 10.5 mmacosx-version-min= -lgcc_ext.10.4)	   \
+-       %:version-compare(>= 10.5 mmacosx-version-min= -lgcc_ext.10.5)	   \
+-       -lgcc }"
++      shared-libgcc|fexceptions|fgnu-runtime: -lgcc;			   \
++      : -lgcc }"
+ 
+ /* We specify crt0.o as -lcrt0.o so that ld will search the library path.
+ 
+--- libgcc/config/t-slibgcc-darwin.orig	2012-09-13 20:26:11.000000000 -0700
++++ libgcc/config/t-slibgcc-darwin	2012-09-13 20:27:08.000000000 -0700
+@@ -39,7 +39,7 @@ endif
+ 
+ LGCC_FILES = libgcc_s.$(SHLIB_SOVERSION)$(SHLIB_EXT)
+ LGCC_FILES += $(LGCC_STUBS)
+-LEXT_STUBS = libgcc_ext.10.4$(SHLIB_EXT) libgcc_ext.10.5$(SHLIB_EXT)
++LEXT_STUBS =
+ LGCC_FILES += $(LEXT_STUBS)
+ INSTALL_FILES=$(LGCC_FILES)
+ 
+
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/macports-changes/attachments/20121006/56b5930d/attachment.html>


More information about the macports-changes mailing list