[PATCH]: Fix PR32765

Jack Howarth howarth@bromo.msbb.uc.edu
Sun Aug 12 21:48:00 GMT 2007


The attached patch passes -static-libgcc on the Darwin target. This
work-around will be required until Apple revises the libgcc support
in FSF gcc on Darwin to use the complete symbol list of the current
libgcc (and not the limited symbol list for MacOS X 10.4 or 10.5).
This patch also provides users with the clue that code resembling
this testcase that uses the ___emutls_get_address symbol in libgcc
will require the use of -static-libgcc to gain access to that
symbol on Darwin. Okay for gcc trunk?
              Jack Howarth

ChangeLog:
2007-08-12  Jack Howarth  <howarth@bromo.med.uc.edu>

	PR target/32765
	* testsuite/libgomp.fortran/pr32550.f90: Use -static-libgcc on Darwin.
	* testsuite/libgomp.fortran/crayptr2.f90: Likwise.

Index: libgomp/testsuite/libgomp.fortran/crayptr2.f90
===================================================================
--- libgomp/testsuite/libgomp.fortran/crayptr2.f90	(revision 127385)
+++ libgomp/testsuite/libgomp.fortran/crayptr2.f90	(working copy)
@@ -1,4 +1,5 @@
 ! { dg-do run }
+! { dg-options "-fopenmp -fcray-pointer -static-libgcc" { target *-*-darwin* } }
 ! { dg-options "-fopenmp -fcray-pointer" }
 
   use omp_lib
Index: libgomp/testsuite/libgomp.fortran/pr32550.f90
===================================================================
--- libgomp/testsuite/libgomp.fortran/pr32550.f90	(revision 127385)
+++ libgomp/testsuite/libgomp.fortran/pr32550.f90	(working copy)
@@ -1,5 +1,6 @@
 ! PR fortran/32550
 ! { dg-do run }
+! { dg-options "-static-libgcc" { target *-*-darwin* } }
 
       integer, pointer, save :: ptr
       integer, target :: targ



More information about the Fortran mailing list