Commit 8633c315 by Richard Sandiford Committed by Richard Sandiford

pa-hpux.h (LINK_SPEC): Remove "%<fwhole-program".

gcc/
	* config/pa/pa-hpux.h (LINK_SPEC): Remove "%<fwhole-program".
	* config/pa/pa-hpux10.h (LINK_SPEC): Likewise.
	* config/pa/pa-hpux11.h (LINK_SPEC): Likewise.
	* gcc.c (set_collect_gcc_options): Don't add -fwhole-program
	to COLLECT_GCC_OPTIONS.

From-SVN: r148099
parent 70ed7339
2009-06-02 Richard Sandiford <r.sandiford@uk.ibm.com> 2009-06-02 Richard Sandiford <r.sandiford@uk.ibm.com>
* config/pa/pa-hpux.h (LINK_SPEC): Remove "%<fwhole-program".
* config/pa/pa-hpux10.h (LINK_SPEC): Likewise.
* config/pa/pa-hpux11.h (LINK_SPEC): Likewise.
* gcc.c (set_collect_gcc_options): Don't add -fwhole-program
to COLLECT_GCC_OPTIONS.
2009-06-02 Richard Sandiford <r.sandiford@uk.ibm.com>
* collect2.c (target_system_root): New variable. * collect2.c (target_system_root): New variable.
(main): Handle --sysroot=. (main): Handle --sysroot=.
(ignore_library): Strip the sysroot from the library path. (ignore_library): Strip the sysroot from the library path.
......
...@@ -95,12 +95,10 @@ along with GCC; see the file COPYING3. If not see ...@@ -95,12 +95,10 @@ along with GCC; see the file COPYING3. If not see
#undef LINK_SPEC #undef LINK_SPEC
#if ((TARGET_DEFAULT | TARGET_CPU_DEFAULT) & MASK_PA_11) #if ((TARGET_DEFAULT | TARGET_CPU_DEFAULT) & MASK_PA_11)
#define LINK_SPEC \ #define LINK_SPEC \
"%<fwhole-program\ "%{!mpa-risc-1-0:%{!march=1.0:%{static:-L/lib/pa1.1 -L/usr/lib/pa1.1 }}}%{mlinker-opt:-O} %{!shared:-u main} %{static:-a archive} %{g*:-a archive} %{shared:-b}"
%{!mpa-risc-1-0:%{!march=1.0:%{static:-L/lib/pa1.1 -L/usr/lib/pa1.1 }}}%{mlinker-opt:-O} %{!shared:-u main} %{static:-a archive} %{g*:-a archive} %{shared:-b}"
#else #else
#define LINK_SPEC \ #define LINK_SPEC \
"%<fwhole-program\ "%{mlinker-opt:-O} %{!shared:-u main} %{static:-a archive} %{g*:-a archive} %{shared:-b}"
%{mlinker-opt:-O} %{!shared:-u main} %{static:-a archive} %{g*:-a archive} %{shared:-b}"
#endif #endif
/* hpux8 and later have C++ compatible include files, so do not /* hpux8 and later have C++ compatible include files, so do not
......
...@@ -82,8 +82,7 @@ along with GCC; see the file COPYING3. If not see ...@@ -82,8 +82,7 @@ along with GCC; see the file COPYING3. If not see
#undef LINK_SPEC #undef LINK_SPEC
#if ((TARGET_DEFAULT | TARGET_CPU_DEFAULT) & MASK_PA_11) #if ((TARGET_DEFAULT | TARGET_CPU_DEFAULT) & MASK_PA_11)
#define LINK_SPEC \ #define LINK_SPEC \
"%<fwhole-program\ "%{!mpa-risc-1-0:%{!march=1.0:%{static:-L/lib/pa1.1 -L/usr/lib/pa1.1 }}}\
%{!mpa-risc-1-0:%{!march=1.0:%{static:-L/lib/pa1.1 -L/usr/lib/pa1.1 }}}\
%{!shared:%{p:-L/lib/libp %{!static:\ %{!shared:%{p:-L/lib/libp %{!static:\
%nWarning: consider linking with `-static' as system libraries with\n\ %nWarning: consider linking with `-static' as system libraries with\n\
%n profiling support are only provided in archive format}}}\ %n profiling support are only provided in archive format}}}\
...@@ -94,8 +93,7 @@ along with GCC; see the file COPYING3. If not see ...@@ -94,8 +93,7 @@ along with GCC; see the file COPYING3. If not see
%{static:-a archive} %{shared:-b}" %{static:-a archive} %{shared:-b}"
#else #else
#define LINK_SPEC \ #define LINK_SPEC \
"%<fwhole-program\ "%{!shared:%{p:-L/lib/libp %{!static:\
%{!shared:%{p:-L/lib/libp %{!static:\
%nWarning: consider linking with `-static' as system libraries with\n\ %nWarning: consider linking with `-static' as system libraries with\n\
%n profiling support are only provided in archive format}}}\ %n profiling support are only provided in archive format}}}\
%{!shared:%{pg:-L/lib/libp %{!static:\ %{!shared:%{pg:-L/lib/libp %{!static:\
......
...@@ -104,8 +104,7 @@ along with GCC; see the file COPYING3. If not see ...@@ -104,8 +104,7 @@ along with GCC; see the file COPYING3. If not see
want dereferencing of a NULL pointer to cause a SEGV. */ want dereferencing of a NULL pointer to cause a SEGV. */
#undef LINK_SPEC #undef LINK_SPEC
#define LINK_SPEC \ #define LINK_SPEC \
"%<fwhole-program\ "%{!shared:%{p:-L/lib/libp -L/usr/lib/libp %{!static:\
%{!shared:%{p:-L/lib/libp -L/usr/lib/libp %{!static:\
%nWarning: consider linking with `-static' as system libraries with\n\ %nWarning: consider linking with `-static' as system libraries with\n\
%n profiling support are only provided in archive format}}}\ %n profiling support are only provided in archive format}}}\
%{!shared:%{pg:-L/lib/libp -L/usr/lib/libp %{!static:\ %{!shared:%{pg:-L/lib/libp -L/usr/lib/libp %{!static:\
......
...@@ -4434,6 +4434,11 @@ set_collect_gcc_options (void) ...@@ -4434,6 +4434,11 @@ set_collect_gcc_options (void)
if ((switches[i].live_cond & SWITCH_IGNORE) != 0) if ((switches[i].live_cond & SWITCH_IGNORE) != 0)
continue; continue;
/* Don't use -fwhole-program when compiling the init and fini routines,
since we'd wrongly assume that the routines aren't needed. */
if (strcmp (switches[i].part1, "fwhole-program") == 0)
continue;
obstack_grow (&collect_obstack, "'-", 2); obstack_grow (&collect_obstack, "'-", 2);
q = switches[i].part1; q = switches[i].part1;
while ((p = strchr (q, '\''))) while ((p = strchr (q, '\'')))
......
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