Commit 7f814c0b by Iain Sandoe

update darwin to use link_gcc_c_sequence.

gcc:

	* config/darwin.h (LINK_COMMAND_SPEC_A): Use %(link_gcc_c_sequence).
	LINK_GCC_C_SEQUENCE_SPEC: Define new macro.

From-SVN: r167084
parent 90eb3e33
2010-11-23 Iain Sandoe <iains@gcc.gnu.org>
* config/darwin.h (LINK_COMMAND_SPEC_A): Use %(link_gcc_c_sequence).
LINK_GCC_C_SEQUENCE_SPEC: Define new macro.
2010-11-23 Jakub Jelinek <jakub@redhat.com> 2010-11-23 Jakub Jelinek <jakub@redhat.com>
PR middle-end/46499 PR middle-end/46499
...@@ -160,10 +160,9 @@ extern GTY(()) int darwin_ms_struct; ...@@ -160,10 +160,9 @@ extern GTY(()) int darwin_ms_struct;
" %{pthread:-D_REENTRANT}" " %{pthread:-D_REENTRANT}"
/* This is mostly a clone of the standard LINK_COMMAND_SPEC, plus /* This is mostly a clone of the standard LINK_COMMAND_SPEC, plus
precomp, libtool, and fat build additions. Also we precomp, libtool, and fat build additions.
don't specify a second %G after %L because libSystem is
self-contained and doesn't need to link against libgcc.a. */ In general, random Darwin linker flags should go into LINK_SPEC
/* In general, random Darwin linker flags should go into LINK_SPEC
instead of LINK_COMMAND_SPEC. The command spec is better for instead of LINK_COMMAND_SPEC. The command spec is better for
specifying the handling of options understood by generic Unix specifying the handling of options understood by generic Unix
linkers, and for positional arguments like libraries. */ linkers, and for positional arguments like libraries. */
...@@ -180,10 +179,12 @@ extern GTY(()) int darwin_ms_struct; ...@@ -180,10 +179,12 @@ extern GTY(()) int darwin_ms_struct;
%{L*} %(link_libgcc) %o %{fprofile-arcs|fprofile-generate*|coverage:-lgcov} \ %{L*} %(link_libgcc) %o %{fprofile-arcs|fprofile-generate*|coverage:-lgcov} \
%{fopenmp|ftree-parallelize-loops=*: \ %{fopenmp|ftree-parallelize-loops=*: \
%{static|static-libgcc|static-libstdc++|static-libgfortran: libgomp.a%s; : -lgomp } } \ %{static|static-libgcc|static-libstdc++|static-libgfortran: libgomp.a%s; : -lgomp } } \
%{!nostdlib:%{!nodefaultlibs: %(link_ssp) %G %L }} \ %{!nostdlib:%{!nodefaultlibs:\
%{!A:%{!nostdlib:%{!nostartfiles:%E}}} %{T*} %{F*} }}}}}}}\n" %(link_ssp) %(link_gcc_c_sequence)\
}}\
%{!A:%{!nostdlib:%{!nostartfiles:%E}}} %{T*} %{F*} }}}}}}}"
#define DSYMUTIL "dsymutil" #define DSYMUTIL "\ndsymutil"
#define DSYMUTIL_SPEC \ #define DSYMUTIL_SPEC \
"%{!fdump=*:%{!fsyntax-only:%{!c:%{!M:%{!MM:%{!E:%{!S:\ "%{!fdump=*:%{!fsyntax-only:%{!c:%{!M:%{!MM:%{!E:%{!S:\
...@@ -192,6 +193,11 @@ extern GTY(()) int darwin_ms_struct; ...@@ -192,6 +193,11 @@ extern GTY(()) int darwin_ms_struct;
#define LINK_COMMAND_SPEC LINK_COMMAND_SPEC_A DSYMUTIL_SPEC #define LINK_COMMAND_SPEC LINK_COMMAND_SPEC_A DSYMUTIL_SPEC
/* We only want one instance of %G, since libSystem (Darwin's -lc) does not depend
on libgcc. */
#undef LINK_GCC_C_SEQUENCE_SPEC
#define LINK_GCC_C_SEQUENCE_SPEC "%G %L"
#ifdef TARGET_SYSTEM_ROOT #ifdef TARGET_SYSTEM_ROOT
#define LINK_SYSROOT_SPEC \ #define LINK_SYSROOT_SPEC \
"%{isysroot*:-syslibroot %*;:-syslibroot " TARGET_SYSTEM_ROOT "}" "%{isysroot*:-syslibroot %*;:-syslibroot " TARGET_SYSTEM_ROOT "}"
......
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