aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChris Gianelloni <wolf31o2@gentoo.org>2008-02-21 02:03:30 +0000
committerChris Gianelloni <wolf31o2@gentoo.org>2008-02-21 02:03:30 +0000
commit6aa007caa3b89635bf4be4cb8ff614618daa18dc (patch)
treeb83c08c83eabb84568c54a50bb348076e35aed45 /targets/support/chroot-functions.sh
parentSince my python sucks and I don't feel like troubleshooting it at the moment,... (diff)
downloadcatalyst-6aa007caa3b89635bf4be4cb8ff614618daa18dc.tar.gz
catalyst-6aa007caa3b89635bf4be4cb8ff614618daa18dc.tar.bz2
catalyst-6aa007caa3b89635bf4be4cb8ff614618daa18dc.zip
Moved creating of stage1 package list to the beginning of stage1-chroot.sh so we can get the output with --debug, added --newuse to the options for stage1, as we should always rebuild any package where the USE has changed, removed removal of portage logs from stage2-chroot.sh since it is being done by cleanup_stages, moved world removal in cleanup_stages into a check for stages 1 through 3, made update_env_settings check for the existence of env-update before running it since we now run update_env_settings by default everywhere chroot-functions.sh is sourced, and added a section to show_debug to list the packages, since we don't yet force-enable verbose with debug.
git-svn-id: svn+ssh://svn.gentoo.org/var/svnroot/catalyst/trunk@1318 d1e1f19c-881f-0410-ab34-b69fee027534
Diffstat (limited to 'targets/support/chroot-functions.sh')
-rwxr-xr-xtargets/support/chroot-functions.sh38
1 files changed, 35 insertions, 3 deletions
diff --git a/targets/support/chroot-functions.sh b/targets/support/chroot-functions.sh
index d9123554..e15c8309 100755
--- a/targets/support/chroot-functions.sh
+++ b/targets/support/chroot-functions.sh
@@ -202,15 +202,30 @@ cleanup_stages() {
then
cleanup_icecream
fi
- rm -f /var/lib/portage/world
- touch /var/lib/portage/world
+ case ${clst_target} in
+ stage1|stage2|stage3)
+ rm -f /var/lib/portage/world
+ touch /var/lib/portage/world
+ ;;
+ *)
+ echo "Skipping removal of world file for ${clst_target}"
+ ;;
+ esac
rm -f /var/log/emerge.log /var/log/portage/elog/*
rm -rf /var/tmp/*
}
update_env_settings(){
- /usr/sbin/env-update
+ which env-update > /dev/null 2>&1
+ ret=$?
+ if [ $ret -eq 0 ]
+ then
+ ENV_UPDATE=`which env-update`
+ ${ENV_UPDATE}
+ else
+ echo "WARNING: env-update not found, skipping!"
+ fi
source /etc/profile
[ -f /tmp/envscript ] && source /tmp/envscript
}
@@ -265,7 +280,9 @@ run_emerge() {
show_debug() {
if [ "${clst_DEBUG}" = "1" ]
then
+ unset PACKAGES
echo "DEBUG:"
+ echo "Profile/target info:"
echo "Profile inheritance:"
python -c 'import portage; print portage.settings.profiles'
echo
@@ -287,6 +304,21 @@ show_debug() {
echo "KERNEL_ABI: $(portageq envvar KERNEL_ABI)"
echo "MULTILIB_ABIS: $(portageq envvar MULTILIB_ABIS)"
echo
+ ### XXX: This is temporary until we make --debug force-enable --verbose
+ if [ -n "${clst_buildpkgs}" ]
+ then
+ PACKAGES=${clst_buildpkgs}
+ elif [ -n "${clst_packages}" ]
+ then
+ PACKAGES=${clst_packages}
+ fi
+ if [ -n "${PACKAGES}" ]
+ then
+ echo "Packages:"
+ echo "${PACKAGES}"
+ echo
+ fi
+ ### XXX: end of section to remove
fi
}