summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorZac Medico <zmedico@gentoo.org>2008-12-02 22:39:22 +0000
committerZac Medico <zmedico@gentoo.org>2008-12-02 22:39:22 +0000
commit1feeb2804ba52aa215646fe07bbd19213aa424b7 (patch)
treee75c60bc169e91aa3f0f5f85970dd70cd551337a /bin/ebuild.sh
parentSource bashrc files as late as possible, giving them the opportunity to (diff)
downloadportage-multirepo-1feeb2804ba52aa215646fe07bbd19213aa424b7.tar.gz
portage-multirepo-1feeb2804ba52aa215646fe07bbd19213aa424b7.tar.bz2
portage-multirepo-1feeb2804ba52aa215646fe07bbd19213aa424b7.zip
Skip sourcing of profile.bashrc during the depend phase. (trunk r12136)
svn path=/main/branches/2.1.6/; revision=12137
Diffstat (limited to 'bin/ebuild.sh')
-rwxr-xr-xbin/ebuild.sh19
1 files changed, 11 insertions, 8 deletions
diff --git a/bin/ebuild.sh b/bin/ebuild.sh
index 197be269..0a16e8a7 100755
--- a/bin/ebuild.sh
+++ b/bin/ebuild.sh
@@ -1516,14 +1516,17 @@ source_all_bashrcs() {
fi
local OCC="${CC}" OCXX="${CXX}"
- # source the existing profile.bashrc's.
- save_IFS
- IFS=$'\n'
- local path_array=($PROFILE_PATHS)
- restore_IFS
- for x in "${path_array[@]}" ; do
- [ -f "${x}/profile.bashrc" ] && qa_source "${x}/profile.bashrc"
- done
+
+ if [[ $EBUILD_PHASE != depend ]] ; then
+ # source the existing profile.bashrcs.
+ save_IFS
+ IFS=$'\n'
+ local path_array=($PROFILE_PATHS)
+ restore_IFS
+ for x in "${path_array[@]}" ; do
+ [ -f "$x/profile.bashrc" ] && qa_source "$x/profile.bashrc"
+ done
+ fi
# We assume if people are changing shopts in their bashrc they do so at their
# own peril. This is the ONLY non-portage bit of code that can change shopts