This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

4.2/4.3 PATCH: Fix libgomp link tests on IRIX 6 (PR libgomp/32538)


As described in the PR, all libgomp link tests fail on IRIX 6 since
copysignl is undefined.  The following patch fixes this, with the
unfortunate side effect that every program is linked with libm now.

I haven't yet applied this since I don't know yet why only IRIX seems to be
affected: both alpha-dec-osf* and *-*-solaris* have no references to
copysignl in their libgcc.  Is this still the right approach or am I just
papering over an underlying problem?

	Rainer

-----------------------------------------------------------------------------
Rainer Orth, Faculty of Technology, Bielefeld University


Mon Jul  2 13:16:32 2007  Rainer Orth  <ro@TechFak.Uni-Bielefeld.DE>

	PR libgomp/32538
	* config/mips/iris6.h (LIBGCC_SPEC): Add libm.

Index: gcc/config/mips/iris6.h
===================================================================
--- gcc/config/mips/iris6.h	(revision 125953)
+++ gcc/config/mips/iris6.h	(working copy)
@@ -96,10 +96,11 @@ Boston, MA 02110-1301, USA.  */
      " %{pthread:-lpthread} %{p:libprof1.a%s}%{pg:libprof1.a%s} -lc " \
      SUBTARGET_WARN_UNUSED_SPEC "}"
 
-/* Avoid getting two warnings for libgcc.a everytime we link.  */
+/* Avoid getting two warnings for libgcc.a everytime we link.  libgcc.a
+   contains references to copysignl, so link with libm to resolve them.  */
 #undef LIBGCC_SPEC
 #define LIBGCC_SPEC \
-  SUBTARGET_DONT_WARN_UNUSED_SPEC " -lgcc " SUBTARGET_WARN_UNUSED_SPEC
+  SUBTARGET_DONT_WARN_UNUSED_SPEC " -lgcc -lm " SUBTARGET_WARN_UNUSED_SPEC
 
 #undef ENDFILE_SPEC
 #define ENDFILE_SPEC \


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]