# Copyright 1999-2007 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/eclass/flag-o-matic.eclass,v 1.116 2007/03/04 21:03:59 vapier Exp $
+# $Header: /var/cvsroot/gentoo-x86/eclass/flag-o-matic.eclass,v 1.117 2007/03/04 21:13:17 vapier Exp $
#
# Maintainer: toolchain@gentoo.org
#
# C[XX]FLAGS that we allow in strip-flags
+# Note: shell globs and character lists are allowed
setup-allowed-flags() {
if [[ -z ${ALLOWED_FLAGS} ]] ; then
export ALLOWED_FLAGS="-pipe"
export ALLOWED_FLAGS="${ALLOWED_FLAGS} -fstack-protector -fstack-protector-all"
export ALLOWED_FLAGS="${ALLOWED_FLAGS} -fbounds-checking -fno-bounds-checking"
export ALLOWED_FLAGS="${ALLOWED_FLAGS} -fno-PIE -fno-pie -fno-unit-at-a-time"
- export ALLOWED_FLAGS="${ALLOWED_FLAGS} -g -g0 -g1 -g2 -g3 -ggdb -ggdb0 -ggdb1 -ggdb2 -ggdb3"
+ export ALLOWED_FLAGS="${ALLOWED_FLAGS} -g -g[0-9] -ggdb -ggdb[0-9] -gstabs -gstabs+"
export ALLOWED_FLAGS="${ALLOWED_FLAGS} -fno-ident"
fi
# allow a bunch of flags that negate features / control ABI