From patchwork Fri Aug 20 12:49:43 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Iain Sandoe X-Patchwork-Id: 62274 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) by ozlabs.org (Postfix) with SMTP id 90864B70F3 for ; Fri, 20 Aug 2010 22:50:11 +1000 (EST) Received: (qmail 30246 invoked by alias); 20 Aug 2010 12:50:06 -0000 Received: (qmail 30229 invoked by uid 22791); 20 Aug 2010 12:50:05 -0000 X-SWARE-Spam-Status: No, hits=-2.0 required=5.0 tests=AWL, BAYES_00, RCVD_IN_DNSWL_NONE, TW_LG X-Spam-Check-By: sourceware.org Received: from c2beaomr07.btconnect.com (HELO c2beaomr07.btconnect.com) (213.123.26.185) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Fri, 20 Aug 2010 12:49:59 +0000 Received: from thor.office (host81-138-1-83.in-addr.btopenworld.com [81.138.1.83]) by c2beaomr07.btconnect.com with ESMTP id FIH20476; Fri, 20 Aug 2010 13:49:45 +0100 (BST) X-Mirapoint-IP-Reputation: reputation=Fair-1, source=Queried, refid=0001.0A0B0302.4C6E79E8.0308, actions=tag Cc: Jack Howarth , mrs@gcc.gnu.org Message-Id: <4F28FDAC-7843-446A-B573-CEE5C0B60CFA@sandoe-acoustics.co.uk> From: IainS To: gcc patches In-Reply-To: Mime-Version: 1.0 (Apple Message framework v936) Subject: Re: [Patch darwin, ppc] lgcc to provide save/restFP for pre-exisitng libraries. Date: Fri, 20 Aug 2010 13:49:43 +0100 References: X-IsSubscribed: yes Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Delivered-To: mailing list gcc-patches@gcc.gnu.org On 20 Aug 2010, at 13:46, IainS wrote: > > My patch of r163267 breaks powerpc in the case that one has a static > lib that refers to save/restFP. > Sorry, I didn't spot that, I bootstrap with gmp/mpfr/mpc in tree .. > > I could revert the lgcc change for all archs, but would prefer to > try this if that's OK with Mike: > > (if it turns out that i686 needs _eprintf for some pre-existing > external code, then we might have to give up and just re-add the > lgcc for all, which seems a shame) > > OK for trunk & 4.5 ? (since this is not a reversion - but an > additional patch). > Iain would help I pasted the right patch: "%{!m64:%:version-compare(!> 10.4 mmacosx-version-min= crt2.o%s)}" Index: gcc/config/rs6000/darwin.h =================================================================== --- gcc/config/rs6000/darwin.h (revision 163400) +++ gcc/config/rs6000/darwin.h (working copy) @@ -120,6 +120,11 @@ extern int darwin_emit_branch_islands; mcpu=G5:ppc970; \ :ppc}}" +/* Linked libs might refer to save/restFP - we still need to append - lgcc to + provide these. */ +#undef LIB_SPEC +#define LIB_SPEC "%{!static:-lgcc -lSystem}" + /* crt2.o is at least partially required for 10.3.x and earlier. */ #define DARWIN_CRT2_SPEC \