Commit 5b6693af by Samuel Thibault Committed by Matthias Klose

gnu.h (STARTFILE_SPEC): Use gcrt0.o in profile mode, add -profile option, add pie support.

2007-08-08  Samuel Thibault  <samuel.thibault@ens-lyon.org>

        * gcc/config/i386/gnu.h (STARTFILE_SPEC): Use gcrt0.o in profile mode, add
        -profile option, add pie support.
        (ENDFILE_SPEC): New spec.
        * gcc/config/gnu.h (LIB_SPEC): Add -profile option.

From-SVN: r127290
parent cf1c6ebf
2007-08-08 Samuel Thibault <samuel.thibault@ens-lyon.org> 2007-08-08 Samuel Thibault <samuel.thibault@ens-lyon.org>
* gcc/config/i386/gnu.h (STARTFILE_SPEC): Use gcrt0.o in profile mode, add
-profile option, add pie support.
(ENDFILE_SPEC): New spec.
* gcc/config/gnu.h (LIB_SPEC): Add -profile option.
2007-08-08 Samuel Thibault <samuel.thibault@ens-lyon.org>
* gcc/config/i386/gnu.h (CPP_SPEC): Add -pthread option. * gcc/config/i386/gnu.h (CPP_SPEC): Add -pthread option.
* gcc/config/gnu.h (LIB_SPEC): Likewise. * gcc/config/gnu.h (LIB_SPEC): Likewise.
......
...@@ -6,7 +6,7 @@ ...@@ -6,7 +6,7 @@
/* Default C library spec. Use -lbsd-compat for gcc -bsd. */ /* Default C library spec. Use -lbsd-compat for gcc -bsd. */
#undef LIB_SPEC #undef LIB_SPEC
#define LIB_SPEC "%{pthread:-lpthread} %{bsd:-lbsd-compat} %{!p:%{!pg:-lc}}%{p:-lc_p}%{pg:-lc_p}" #define LIB_SPEC "%{pthread:-lpthread} %{bsd:-lbsd-compat} %{pg|p|profile:-lc_p;:-lc}"
/* Standard include directory. In GNU, "/usr" is a four-letter word. */ /* Standard include directory. In GNU, "/usr" is a four-letter word. */
#undef STANDARD_INCLUDE_DIR #undef STANDARD_INCLUDE_DIR
......
...@@ -26,13 +26,19 @@ ...@@ -26,13 +26,19 @@
%{static:-static}}" %{static:-static}}"
#undef STARTFILE_SPEC #undef STARTFILE_SPEC
#if defined HAVE_LD_PIE
#define STARTFILE_SPEC \ #define STARTFILE_SPEC \
"%{!shared: \ "%{!shared: %{pg|p|profile:gcrt0.o%s;pie:Scrt1.o%s;static:crt0.o%s;:crt1.o%s}} \
%{!static: \ crti.o%s %{static:crtbeginT.o%s;shared|pie:crtbeginS.o%s;:crtbegin.o%s}"
%{pg:gcrt1.o%s} %{!pg:%{p:gcrt1.o%s} %{!p:crt1.o%s}}} \ #else
%{static:crt0.o%s}} \ #define STARTFILE_SPEC \
crti.o%s %{static:crtbeginT.o%s}\ "%{!shared: %{pg|p|profile:gcrt0.o%s;static:crt0.o%s;:crt1.o%s}} \
%{!static:%{!shared:crtbegin.o%s} %{shared:crtbeginS.o%s}}" crti.o%s %{static:crtbeginT.o%s;shared|pie:crtbeginS.o%s;:crtbegin.o%s}"
#endif
#undef ENDFILE_SPEC
#define ENDFILE_SPEC \
"%{shared|pie:crtendS.o%s;:crtend.o%s} crtn.o%s"
/* FIXME: Is a Hurd-specific fallback mechanism necessary? */ /* FIXME: Is a Hurd-specific fallback mechanism necessary? */
#undef MD_UNWIND_SUPPORT #undef MD_UNWIND_SUPPORT
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment