mypack=self.settings["livecd/packages"][:]
for x in range(0,len(mypack)):
#surround args with quotes for passing to bash, allows things like "<" to remain intact
- mypack[x]='"'+mypack[x]+'"'
+ mypack[x]="'"+mypack[x]+"'"
mypack=string.join(mypack)
try:
cmd("/bin/bash "+self.settings["sharedir"]+"/targets/livecd-stage1/livecd-stage1.sh run "+mypack)
myunmerge=self.settings["livecd/unmerge"][:]
for x in range(0,len(myunmerge)):
#surround args with quotes for passing to bash, allows things like "<" to remain intact
- myunmerge[x]='"'+myunmerge[x]+'"'
+ myunmerge[x]="'"+myunmerge[x]+"'"
myunmerge=string.join(myunmerge)
#before cleaning, unmerge stuff:
cmd("/bin/bash "+self.settings["sharedir"]+"/targets/"+self.settings["target"]+"/unmerge.sh "+myunmerge,"unmerge script failed.")
# Copyright 1999-2003 Gentoo Technologies, Inc.
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo/src/catalyst/targets/livecd-stage1/Attic/livecd-stage1.sh,v 1.2 2003/12/23 06:36:52 drobbins Exp $
+# $Header: /var/cvsroot/gentoo/src/catalyst/targets/livecd-stage1/Attic/livecd-stage1.sh,v 1.3 2004/01/12 06:20:33 drobbins Exp $
case $1 in
enter)
;;
run)
shift
- export clst_packages="$*"
$clst_CHROOT $clst_chroot_path /bin/bash << EOF
env-update
source /etc/profile
USE="build" emerge portage
#turn off auto-use:
export USE_ORDER="env:conf:defaults"
- if [ -n "${clst_PKGCACHE}" ]
- then
- emerge --usepkg --buildpkg --noreplace $clst_packages || exit 1
- else
- emerge --noreplace $clst_packages || exit 1
- fi
+ for x in $*
+ do
+ if [ -n "${clst_PKGCACHE}" ]
+ then
+ emerge --usepkg --buildpkg --noreplace "\$x" || exit 1
+ else
+ emerge --noreplace "\$x" || exit 1
+ fi
+ done
EOF
[ $? -ne 0 ] && exit 1
;;