GNU bug report logs - #15793
Bug: linking shared libraries on Cygwin results in undefined references to __stack_chck_guard for code compiled with -fstack-protector

Please note: This is a static page, with minimal formatting, updated once a day.
Click here to see this page with the latest information and nicer formatting.

Package: libtool; Reported by: Richard PALO <richard.palo@HIDDEN>; dated Sat, 2 Nov 2013 23:16:01 UTC; Maintainer for libtool is bug-libtool@HIDDEN.

Message received at submit <at> debbugs.gnu.org:


Received: (at submit) by debbugs.gnu.org; 2 Nov 2013 23:15:32 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Sat Nov 02 19:15:32 2013
Received: from localhost ([127.0.0.1]:60140 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.80)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1VckPj-00029J-Qq
	for submit <at> debbugs.gnu.org; Sat, 02 Nov 2013 19:15:32 -0400
Received: from eggs.gnu.org ([208.118.235.92]:48166)
 by debbugs.gnu.org with esmtp (Exim 4.80)
 (envelope-from <gnu-bug-libtool@HIDDEN>) id 1Vck6O-0001e9-Co
 for submit <at> debbugs.gnu.org; Sat, 02 Nov 2013 18:55:33 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
 (envelope-from <gnu-bug-libtool@HIDDEN>) id 1Vck6C-0003Py-Fr
 for submit <at> debbugs.gnu.org; Sat, 02 Nov 2013 18:55:26 -0400
X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org
X-Spam-Level: 
X-Spam-Status: No, score=0.8 required=5.0 tests=BAYES_50,FREEMAIL_FROM
 autolearn=disabled version=3.3.2
Received: from lists.gnu.org ([2001:4830:134:3::11]:49486)
 by eggs.gnu.org with esmtp (Exim 4.71)
 (envelope-from <gnu-bug-libtool@HIDDEN>) id 1Vck6C-0003Pu-CM
 for submit <at> debbugs.gnu.org; Sat, 02 Nov 2013 18:55:20 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:49870)
 by lists.gnu.org with esmtp (Exim 4.71)
 (envelope-from <gnu-bug-libtool@HIDDEN>) id 1Vck66-0008Jp-Ei
 for bug-libtool@HIDDEN; Sat, 02 Nov 2013 18:55:20 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
 (envelope-from <gnu-bug-libtool@HIDDEN>) id 1Vck5x-0003L6-O8
 for bug-libtool@HIDDEN; Sat, 02 Nov 2013 18:55:14 -0400
Received: from plane.gmane.org ([80.91.229.3]:37513)
 by eggs.gnu.org with esmtp (Exim 4.71)
 (envelope-from <gnu-bug-libtool@HIDDEN>) id 1Vck5x-0003GE-Hs
 for bug-libtool@HIDDEN; Sat, 02 Nov 2013 18:55:05 -0400
Received: from list by plane.gmane.org with local (Exim 4.69)
 (envelope-from <gnu-bug-libtool@HIDDEN>) id 1Vck5v-0005TY-2I
 for bug-libtool@HIDDEN; Sat, 02 Nov 2013 23:55:03 +0100
Received: from pig83-1-78-228-114-66.fbx.proxad.net ([78.228.114.66])
 by main.gmane.org with esmtp (Gmexim 0.1 (Debian))
 id 1AlnuQ-0007hv-00
 for <bug-libtool@HIDDEN>; Sat, 02 Nov 2013 23:55:03 +0100
Received: from richard.palo by pig83-1-78-228-114-66.fbx.proxad.net with local
 (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00
 for <bug-libtool@HIDDEN>; Sat, 02 Nov 2013 23:55:03 +0100
X-Injected-Via-Gmane: http://gmane.org/
To: bug-libtool@HIDDEN
From: Richard PALO <richard.palo@HIDDEN>
Subject: Re: Bug: linking shared libraries on Cygwin results in undefined
 references to __stack_chck_guard for code compiled with -fstack-protector
Date: Sat, 02 Nov 2013 23:45:29 +0100
Lines: 30
Message-ID: <l53v9v$gjn$1@HIDDEN>
References: <AANLkTimBUMzojnf9RAqAowJGGG_B8c8o-R5Aq9bjWvYs@HIDDEN>
 <20100601222415.23d4ea46@YAAKOV04>
Mime-Version: 1.0
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 8bit
X-Complaints-To: usenet@HIDDEN
X-Gmane-NNTP-Posting-Host: pig83-1-78-228-114-66.fbx.proxad.net
User-Agent: Mozilla/5.0 (X11; SunOS i86pc;
 rv:24.0) Gecko/20100101 Thunderbird/24.0.1
In-Reply-To: <20100601222415.23d4ea46@YAAKOV04>
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
 recognized.
X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address
 (bad octet value).
X-Received-From: 2001:4830:134:3::11
X-Spam-Score: -4.1 (----)
X-Debbugs-Envelope-To: submit
X-Mailman-Approved-At: Sat, 02 Nov 2013 19:15:30 -0400
Cc: libtool-patches@HIDDEN
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.15
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <http://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <http://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <http://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -4.1 (----)

Le 02/06/10 05:24, Yaakov (Cygwin/X) a écrit :
> On Sat, 15 May 2010 09:07:49 +0200
> Bart Van Assche <bvanassche@HIDDEN> wrote:
>> This behavior has been observed with libtool version 2.2.6.
>
> Bug confirmed.  When code is compiled with -fstack-protector{,-all},
> GCC "emits extra code to check for buffer overflows, such as stack
> smashing attacks".  This extra code uses symbols from libssp, and
> therefore (at least) Cygwin's GCC specs contain:
>
> *link_ssp:
> %{fstack-protector|fstack-protector-all:-lssp_nonshared -lssp}
>
> Therefore, when libtool fails to pass -fstack-protector{,-all} at link
> stage, the link fails.
>
> Patch attached.  (Yes, I have a copyright assignment on file.)
>
>
> Yaakov
> Cygwin/X
>

I've done some limited testing of this patch on a SunOS distro with 
pkgsrc, and it certainly helps a number of cases since it is gcc that 
generates the necessary '-lssp_nonshared -lssp' libs for linking (at 
least in absence of '-nostdlib').

Please include in the upcoming version.






Acknowledgement sent to Richard PALO <richard.palo@HIDDEN>:
New bug report received and forwarded. Copy sent to bug-libtool@HIDDEN. Full text available.
Report forwarded to bug-libtool@HIDDEN:
bug#15793; Package libtool. Full text available.
Please note: This is a static page, with minimal formatting, updated once a day.
Click here to see this page with the latest information and nicer formatting.
Last modified: Fri, 31 Oct 2014 17:00:04 UTC

GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997 nCipher Corporation Ltd, 1994-97 Ian Jackson.