diff options
author | Kevin F. Quinn <kevquinn@gentoo.org> | 2007-03-06 18:53:43 +0000 |
---|---|---|
committer | Kevin F. Quinn <kevquinn@gentoo.org> | 2007-03-06 18:53:43 +0000 |
commit | d87430c5c38ef927a58c865e10aca1c6538f785f (patch) | |
tree | 983d1b3cfd83d7385ef8ba372f029a2a7074bbe9 /hardened/toolchain/branches/pieworld/eclass/flag-o-matic.eclass | |
parent | Align with gentoo-x86 3 Mar 2007 (diff) | |
download | kevquinn-d87430c5c38ef927a58c865e10aca1c6538f785f.tar.gz kevquinn-d87430c5c38ef927a58c865e10aca1c6538f785f.tar.bz2 kevquinn-d87430c5c38ef927a58c865e10aca1c6538f785f.zip |
Various updates suggested by vapier, some work still in progress
svn path=/; revision=186
Diffstat (limited to 'hardened/toolchain/branches/pieworld/eclass/flag-o-matic.eclass')
-rw-r--r-- | hardened/toolchain/branches/pieworld/eclass/flag-o-matic.eclass | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/hardened/toolchain/branches/pieworld/eclass/flag-o-matic.eclass b/hardened/toolchain/branches/pieworld/eclass/flag-o-matic.eclass index 5f642e6..7dfb2f6 100644 --- a/hardened/toolchain/branches/pieworld/eclass/flag-o-matic.eclass +++ b/hardened/toolchain/branches/pieworld/eclass/flag-o-matic.eclass @@ -124,7 +124,7 @@ setup-allowed-flags() { _manage-hardened() { local newspec=$1 [[ -z $2 ]] && die "Internal flag-o-matic error ($*) - please report" - if gcc-specs-exists ${newspec}.specs; then + if _gcc-specs-exists ${newspec}.specs; then [[ -z ${GCC_SPECS} ]] || newspec=":${newspec}" export GCC_SPECS="${GCC_SPECS}${newspec}.specs" einfo "Hardened compiler filtered $2 - GCC_SPECS set to ${GCC_SPECS}" @@ -154,7 +154,7 @@ _manage-hardened() { ;; esac if [[ -n ${newspec} ]]; then - if gcc-specs-exists ${newspec}; then + if _gcc-specs-exists ${newspec}; then export GCC_SPECS="${newspec}" einfo "Hardened compiler filtered $2 - GCC_SPECS set to ${GCC_SPECS}" fi @@ -232,29 +232,29 @@ append-lfs-flags() { # Append flag if the compiler doesn't barf it _raw_append_flag() { - test-flag-CC $1 && + test-flag-CC "$1" && export CFLAGS="${CFLAGS} $1" - test-flag-CXX $1 && + test-flag-CXX "$1" && export CXXFLAGS="${CXXFLAGS} $1" } # Special case: -fno-stack-protector-all needs special management # on hardened gcc-4. _append-flag() { - [[ -z $1 ]] && return 0 - case $1 in + [[ -z "$1" ]] && return 0 + case "$1" in -fno-stack-protector-all) _manage-hardened nosspall.specs -fno-stack-protector-all ;; *) - _raw_append_flag $1 + _raw_append_flag "$1" esac } append-flags() { local f - [[ -z $* ]] && return 0 - for f in $*; do - _append-flag ${f} + [[ -z "$@" ]] && return 0 + for f in "$@"; do + _append-flag "${f}" done return 0 } |