This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
[Patch, target]: use -lobjc-gnu at 64-bit on Darwin
- From: howarth at bromo dot msbb dot uc dot edu (Jack Howarth)
- To: gcc-patches at gcc dot gnu dot org
- Cc: geoffk at apple dot com, mrs at apple dot com
- Date: Sun, 8 Oct 2006 19:45:12 -0400 (EDT)
- Subject: [Patch, target]: use -lobjc-gnu at 64-bit on Darwin
The proposed patch causes libobjc-gnu to be automatically used
on Darwin at 64-bit since no 64-bit system objc runtime exists
in any currently shipping version of MacOS X. It would have been
better to do this conditionally with something like...
%{m64:%:version-compare(< 10.5 mmacosx-version-min= %{fgnu-runtime:%:replace-outfile(-lobjc -lobjc-gnu)})}\
but the current version-compare only takes simple strings as its
third argument. Okay for gcc trunk?
Jack
2006-10-08 Jack Howarth <howarth@bromo.med.uc.edu>
* config/darwin.h (LINK_SPEC): use -lobjc-gnu at 64-bit.
Index: config/darwin.h
===================================================================
--- config/darwin.h (revision 117559)
+++ config/darwin.h (working copy)
@@ -231,6 +231,7 @@ extern GTY(()) int darwin_ms_struct;
#define LINK_SPEC \
"%{static}%{!static:-dynamic} \
%{fgnu-runtime:%:replace-outfile(-lobjc -lobjc-gnu)}\
+ %{m64:%:replace-outfile(-lobjc -lobjc-gnu)}\
%{!Zdynamiclib: \
%{Zforce_cpusubtype_ALL:-arch %(darwin_arch) -force_cpusubtype_ALL} \
%{!Zforce_cpusubtype_ALL:-arch %(darwin_subarch)} \