This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Darwin -fpic == -fPIC
- From: Stan Shebs <shebs at apple dot com>
- To: gcc-patches at gcc dot gnu dot org
- Date: Thu, 05 Sep 2002 09:43:25 -0700
- Subject: Darwin -fpic == -fPIC
Nobody uses -fpic on Darwin, because code is PI by default (except in
the kernel), but this tweak catches oddballs and more importantly :-)
fixes some testsuite failures. Bootstrapped on powerpc-apple-darwin,
committed to trunk.
Stan
2002-09-05 Stan Shebs <shebs@apple.com>
* config/rs6000/rs6000.c (rs6000_override_options): Make -fpic and
-fPIC equivalent on Darwin.
Index: config/rs6000/rs6000.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/config/rs6000/rs6000.c,v
retrieving revision 1.369
diff -p -r1.369 rs6000.c
*** config/rs6000/rs6000.c 5 Sep 2002 03:49:41 -0000 1.369
--- config/rs6000/rs6000.c 5 Sep 2002 16:16:12 -0000
*************** rs6000_override_options (default_cpu)
*** 602,607 ****
--- 602,611 ----
}
#endif
+ /* For Darwin, always silently make -fpic and -fPIC identical. */
+ if (flag_pic == 1 && DEFAULT_ABI == ABI_DARWIN)
+ flag_pic = 2;
+
/* Set debug flags */
if (rs6000_debug_name)
{