# -*-Shell-script-*-
#
# Common functions for build scripts used by various packages
-# incorporated (e.g., build, myplc, myplc-devel, vserver-reference)
+# incorporated (e.g., build, bootcd, nodeimage, sliceimage)
#
# Marc E. Fiuczynski <mef@cs.princeton.edu>
# Copyright (C) 2007 The Trustees of Princeton University
return 0
}
-# returns stuff for vserver, i.e. something like 'f8' or 'centos5'
+# returns distro shortname, something like 'f8' or 'centos5'
function pl_getReleaseName () {
distro=$1; shift
release=$1; shift
type -p pkgs.py >& /dev/null || export PATH=$builddir:$PATH
# parse it
- pl_parsePkgs keyword $fcdistro $pldistro $yumexclude_file || \
+ pl_parsePkgs $keyword $fcdistro $pldistro $yumexclude_file || \
{ echo pl_yumexclude failed with fcdistro=$fcdistro and pldistro=$pldistro; return 1 ; }
}
# the release number (plain number)
pl_DISTRO_RELEASE=$(pl_getRelease)
-# the release name - for vserver build ...
+# the release name - something like 'f8' or 'sl6'
pl_DISTRO_NAME=$(pl_getReleaseName $pl_DISTRO $pl_DISTRO_RELEASE)
# get path to appropriate yumgroups.xml file
# For pseudo ttys
mkdir -p $vroot/dev/pts
- # (Might have to remove the following for vserver-reference.)
-
# for tmpfs mount
mkdir -p $vroot/dev/shm
mknod -m 600 $vroot/dev/net/tun c 10 200
# For mkinitrd (in case a kernel is being installed)
- # As well as for loop back mounting within a vserver.
+ # As well as for loop back mounting within a vm.
for i in $(seq 0 255) ; do
mknod -m 640 $vroot/dev/loop$i b 7 $i
done
echo " Defaults are searched in <pldistro>.mirrors"
echo " -v Be verbose"
echo " -h This message"
- echo " target selection (defaults based on current build vserver)"
+ echo " target selection (defaults based on current build VM context)"
echo " -r release Fedora release number (default: $releasever)"
echo " -a arch Fedora architecture (default: $basearch)"
exit 1
# Verbosity
verbose=0
-# Release and architecture to install : defaults to current vserver's settings or previously parsed fedora_options
+# Release and architecture to install : defaults to current vm settings or previously parsed fedora_options
releasever=$pl_DISTRO_RELEASE
basearch=$pl_DISTRO_ARCH
#
# values can contain @arch@, @fcdistro@ or @pldistro@ that are replaced with the current values
#
-# the reason for the -a option is for when we build the build vserver itself; in this case
+# the reason for the -a option is for when we build the build vm itself; in this case
# pl_DISTRO_ARCH is the one we obtain from the root context, and that's wrong
# specify -sa arch AFTER keyword, so as to keep pl_getPackages and pl_getGroups simple
#