From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 27381 invoked by alias); 4 Aug 2005 03:50:48 -0000 Mailing-List: contact gcc-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Archive: List-Post: List-Help: Sender: gcc-owner@gcc.gnu.org Received: (qmail 27373 invoked by uid 22791); 4 Aug 2005 03:50:46 -0000 Received: from mx1.redhat.com (HELO mx1.redhat.com) (66.187.233.31) by sourceware.org (qpsmtpd/0.30-dev) with ESMTP; Thu, 04 Aug 2005 03:50:46 +0000 Received: from int-mx1.corp.redhat.com (int-mx1.corp.redhat.com [172.16.52.254]) by mx1.redhat.com (8.12.11/8.12.11) with ESMTP id j743msiP004333; Wed, 3 Aug 2005 23:48:54 -0400 Received: from potter.sfbay.redhat.com (potter.sfbay.redhat.com [172.16.27.15]) by int-mx1.corp.redhat.com (8.11.6/8.11.6) with ESMTP id j743msV24555; Wed, 3 Aug 2005 23:48:54 -0400 Received: from ballpeen.sfbay.redhat.com (ballpeen.sfbay.redhat.com [172.16.24.33]) by potter.sfbay.redhat.com (8.12.8/8.12.8) with ESMTP id j743mq9S028688; Wed, 3 Aug 2005 23:48:52 -0400 Received: from ballpeen.sfbay.redhat.com (ballpeen.sfbay.redhat.com [127.0.0.1]) by ballpeen.sfbay.redhat.com (8.13.4/8.13.1) with ESMTP id j743mqD1018300; Wed, 3 Aug 2005 20:48:52 -0700 Received: (from rth@localhost) by ballpeen.sfbay.redhat.com (8.13.4/8.13.4/Submit) id j743mpBp018299; Wed, 3 Aug 2005 20:48:51 -0700 Date: Thu, 04 Aug 2005 03:50:00 -0000 From: Richard Henderson To: Jack Howarth Cc: gcc@gcc.gnu.org Subject: Re: does -fstack-protector work for gcc 4.1 on Darwin 8? Message-ID: <20050804034851.GB18262@redhat.com> Mail-Followup-To: Richard Henderson , Jack Howarth , gcc@gcc.gnu.org References: <20050804013913.DE1101DC06D@bromo.msbb.uc.edu> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20050804013913.DE1101DC06D@bromo.msbb.uc.edu> User-Agent: Mutt/1.4.2.1i X-SW-Source: 2005-08/txt/msg00136.txt.bz2 On Wed, Aug 03, 2005 at 09:39:13PM -0400, Jack Howarth wrote: > Do you think I should be able to build gcc itself with the > -fstack-protector flag and what is the most appropriate way to > achieve that (ie brute force using a CFLAG or some configure > flag)? Considering that I don't think that self-building with -fstack-protector will ever be common, I don't think we ought to spend too many brain cells on this. The only way to bootstrap with -fstack-protector without existing support in libc is to use a top-level bootstrap. That said, I don't think this really addresses what you want to accomplish... > I am interested in doing this so that I can have a > libgfortran built with -fstack-protector to try to track down > a potential stack corruption problem. Thanks in advance for any > advice. This should be as simple as make all-gcc make all-target-libssp make CFLAGS_FOR_TARGET='-O -g -fstack-protector-all' all-target-libgfortran and then explicitly build your test program with -fstack-protector-all so that the right libraries get linked in. r~