This is the mail archive of the 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]

[PATCH][4.8][4.7][4.6] Make -shared-libgcc the default on Cygwin.

    Hello list,

  The attached patch makes -shared-libgcc the default for Cygwin.  This is
something that I should have done some time ago, as shared libgcc on Cygwin is
more than mature.  What's more, it is vital for reliable compilation of
applications that throw exceptions or share TLS variables from DLLs into the
main executable; at present these compile incorrectly without an explicit
-shared-libgcc.  For instance, the just-released MPFR-3.1.2 doesn't work
without it.

  Given that it's a very simple tweak to the compiler specs on a single
platform only, I would like to use my target maintainer's discretion to apply
it even at this late stage, but I figure it's so close to RC1 that I should
ask the RM's permission anyway.

  I'd also like to backport it to all the currently-open branches.


2013-03-12  Dave Korn  <dave.korn.cygwin@....>

	* config/i386/cygwin.h (SHARED_LIBGCC_SPEC): Make shared libgcc the
	default setting.

  Is this OK by everyone?


Index: gcc/config/i386/cygwin.h
--- gcc/config/i386/cygwin.h	(revision 196604)
+++ gcc/config/i386/cygwin.h	(working copy)
@@ -48,11 +48,7 @@ along with GCC; see the file COPYING3.  If not see
  %{static|static-libgcc:-lgcc -lgcc_eh} \
  %{!static: \
    %{!static-libgcc: \
-     %{!shared: \
-       %{!shared-libgcc:-lgcc -lgcc_eh} \
-       %{shared-libgcc:-lgcc_s -lgcc} \
-      } \
-     %{shared:-lgcc_s -lgcc} \
+     -lgcc_s -lgcc \
     } \
   } "

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