summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBrian Harring <ferringb@gentoo.org>2005-10-04 14:13:49 +0000
committerBrian Harring <ferringb@gentoo.org>2005-10-04 14:13:49 +0000
commita37a3655484e327a6ce28d8d8892424599fa9d2c (patch)
tree339dd48f22aa5eac6f97ae896d34db81abf761d8
parentd8396b3457c86b78cab14244d56d2a91b0ae03c1 (diff)
downloadportage-a37a3655484e327a6ce28d8d8892424599fa9d2c.tar.gz
portage-a37a3655484e327a6ce28d8d8892424599fa9d2c.tar.bz2
portage-a37a3655484e327a6ce28d8d8892424599fa9d2c.zip
bug 107770 , fix A D and a few other vars being set implicitly by readonly protection during setup phase.
svn path=/main/branches/2.0/; revision=2083
-rwxr-xr-xbin/ebuild.sh6
1 files changed, 4 insertions, 2 deletions
diff --git a/bin/ebuild.sh b/bin/ebuild.sh
index cf012d1b0..ca47396ba 100755
--- a/bin/ebuild.sh
+++ b/bin/ebuild.sh
@@ -1733,8 +1733,10 @@ export S=${WORKDIR}/${P}
unset E_IUSE E_DEPEND E_RDEPEND E_CDEPEND E_PDEPEND
-declare -r T P PN PV PVR PR A D EBUILD EMERGE_FROM O PPID FILESDIR
-declare -r PORTAGE_TMPDIR
+for x in T P PN PV PVR PR A D EBUILD EMERGE_FROM O PPID FILESDIR PORTAGE_TMPDIR; do
+ [[ ${!x-UNSET_VAR} != UNSET_VAR ]] && declare -r ${!x}
+done
+unset x
# Turn of extended glob matching so that g++ doesn't get incorrectly matched.
shopt -u extglob