summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorZac Medico <zmedico@gentoo.org>2007-11-22 21:59:54 +0000
committerZac Medico <zmedico@gentoo.org>2007-11-22 21:59:54 +0000
commit63865f1e164a80a322637718263a6fa5b2afd9e5 (patch)
treec311d82366b1c219dc80b396ee483e7509ee6f1a
parenta7a50212d0254cc0d5ab777e36510310a41f3c1f (diff)
downloadportage-63865f1e164a80a322637718263a6fa5b2afd9e5.tar.gz
portage-63865f1e164a80a322637718263a6fa5b2afd9e5.tar.bz2
portage-63865f1e164a80a322637718263a6fa5b2afd9e5.zip
Generalize the sed expression in filter_readonly_variables() so that
it will work with things like 'declare -xr' as well as 'declare -rx'. svn path=/main/trunk/; revision=8605
-rwxr-xr-xbin/ebuild.sh2
1 files changed, 1 insertions, 1 deletions
diff --git a/bin/ebuild.sh b/bin/ebuild.sh
index e03b18fa3..8ad15241d 100755
--- a/bin/ebuild.sh
+++ b/bin/ebuild.sh
@@ -1394,7 +1394,7 @@ filter_readonly_variables() {
# listed in READONLY_EBUILD_METADATA, since having any readonly attributes
# persisting in the saved environment can be inconvenient when it
# eventually needs to be reloaded.
- egrep -v -e "${var_grep}" | sed 's:^declare -rx:declare -x:'
+ egrep -v -e "${var_grep}" | sed 's:^declare[[:space:]]\+-\([[:alnum:]]*\)r\([[:alnum:]]*\)[[:space:]]\+:declare -\1\2 :'
}
# @FUNCTION: preprocess_ebuild_env