3 # PlanetLab release build script. Intended to be used by scripts and
4 # crontabs to build nightly releases (default). Can also be invoked
5 # manually to build a tagged release (-r) in the current directory.
7 # $Id: build.sh,v 1.4 2004/05/26 18:50:15 mlh-pl_rpm Exp $
11 CVSROOT=pup-pl_rpm@cvs.planet-lab.org:/cvs
16 # Export certain variables
20 while getopts "d:r:" opt ; do
29 echo "usage: `basename $0` [-d $CVSROOT] [-r $TAG]"
35 # Create a unique build base
36 BASE=${TAG/HEAD/`date +%Y.%m.%d`}
38 while ! mkdir ${BASE}${i} 2>/dev/null ; do
39 [ -z ${i} ] && BASE=${BASE}.
41 if [ $i -gt 100 ] ; then
42 echo "$0: Failed to create release directory `pwd`/${BASE}${i}"
50 cvs -d ${CVSROOT} export -r ${TAG} -d ${BASE} ${MODULE}
55 if [ $? -ne 0 ] ; then
56 if [ -f ${BASE}/log ] ; then