rhill       14/06/14 08:07:11

  Modified:             common.eblit
  Log:
  Strip -fstack-protector*. These flags are now enabled by default so we can
  consider them supported. And even on systems where gcc-specs-ssp is true,
  having -fstack-protector in CFLAGS causes a failure because flags added
  here end up getting /pre/pended to user flags.
  
  Signed-off-by: Ryan Hill <rh...@gentoo.org>
  (Portage version: 2.2.10/cvs/Linux x86_64, signed Manifest commit with key 
957A8463)

Revision  Changes    Path
1.35                 sys-libs/glibc/files/eblits/common.eblit

file : 
http://sources.gentoo.org/viewvc.cgi/gentoo-x86/sys-libs/glibc/files/eblits/common.eblit?rev=1.35&view=markup
plain: 
http://sources.gentoo.org/viewvc.cgi/gentoo-x86/sys-libs/glibc/files/eblits/common.eblit?rev=1.35&content-type=text/plain
diff : 
http://sources.gentoo.org/viewvc.cgi/gentoo-x86/sys-libs/glibc/files/eblits/common.eblit?r1=1.34&r2=1.35

Index: common.eblit
===================================================================
RCS file: /var/cvsroot/gentoo-x86/sys-libs/glibc/files/eblits/common.eblit,v
retrieving revision 1.34
retrieving revision 1.35
diff -u -r1.34 -r1.35
--- common.eblit        16 Jan 2014 17:38:31 -0000      1.34
+++ common.eblit        14 Jun 2014 08:07:10 -0000      1.35
@@ -1,6 +1,6 @@
 # Copyright 1999-2014 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/sys-libs/glibc/files/eblits/common.eblit,v 
1.34 2014/01/16 17:38:31 vapier Exp $
+# $Header: /var/cvsroot/gentoo-x86/sys-libs/glibc/files/eblits/common.eblit,v 
1.35 2014/06/14 08:07:10 rhill Exp $
 
 alt_prefix() {
        is_crosscompile && echo /usr/${CTARGET}
@@ -183,7 +183,12 @@
        # building glibc with SSP is fraught with difficulty, especially
        # due to __stack_chk_fail_local which would mean significant changes
        # to the glibc build process. See bug #94325 #293721
-       gcc-specs-ssp && append-cflags $(test-flags-CC -fno-stack-protector)
+       # Note we have to handle both user-given CFLAGS and gcc defaults via
+       # spec rules here.  We can't simply add -fno-stack-protector as it gets
+       # added before user flags, and we can't just filter-flags because
+       # _filter_hardened doesn't support globs.
+       filter-flags -fstack-protector*
+       gcc-specs-ssp && append-flags $(test-flags -fno-stack-protector)
 
        if use hardened && gcc-specs-pie ; then
                # Force PIC macro definition for all compilations since they're 
all




Reply via email to