Add socketwrapper and cputime limit.
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@18399 ec53bebd-3082-4978-b11e-865c3cabbd6b
This commit is contained in:
@@ -11,6 +11,7 @@ keeptree=no
|
|||||||
passhrase=
|
passhrase=
|
||||||
builddir=
|
builddir=
|
||||||
noemail=
|
noemail=
|
||||||
|
cputimelimit=3600
|
||||||
|
|
||||||
# Add some bonus paths, to find sendmail and other tools
|
# Add some bonus paths, to find sendmail and other tools
|
||||||
# on interesting platforms.
|
# on interesting platforms.
|
||||||
@@ -19,7 +20,7 @@ PATH="${PATH}:/usr/local/bin:/usr/local/sbin"
|
|||||||
|
|
||||||
# no more use configurabled part below (hopefully)
|
# no more use configurabled part below (hopefully)
|
||||||
|
|
||||||
usage="[--current] [--release version] [--cvs SourceRepository] [--cvs-flags] [--result-directory dir] [--fetch-method wget|ftp|curl|cvs] --keep-tree] [--autotools] [--passhrase string] [--no-email] [--build-dir dir]"
|
usage="[--current] [--release version] [--cvs SourceRepository] [--cvs-flags] [--result-directory dir] [--fetch-method wget|ftp|curl|cvs] --keep-tree] [--autotools] [--passhrase string] [--no-email] [--build-dir dir] [--cputime]"
|
||||||
|
|
||||||
date=`date +%Y%m%d`
|
date=`date +%Y%m%d`
|
||||||
if [ "$?" != 0 ]; then
|
if [ "$?" != 0 ]; then
|
||||||
@@ -61,6 +62,10 @@ do
|
|||||||
hversion="heimdal-${date}"
|
hversion="heimdal-${date}"
|
||||||
shift
|
shift
|
||||||
;;
|
;;
|
||||||
|
--cputime)
|
||||||
|
cputimelimit="$2"
|
||||||
|
shift 2
|
||||||
|
;;
|
||||||
--release)
|
--release)
|
||||||
hversion="heimdal-$2"
|
hversion="heimdal-$2"
|
||||||
shift 2
|
shift 2
|
||||||
@@ -127,6 +132,9 @@ url="${baseurl}/${dir}${hfile}"
|
|||||||
afsfile="${afsdir}/${dir}${hfile}"
|
afsfile="${afsdir}/${dir}${hfile}"
|
||||||
unpack=yes
|
unpack=yes
|
||||||
|
|
||||||
|
# Limit cpu seconds this all can take
|
||||||
|
ulimit -t "$cputimelimit" > /dev/null 2>&1
|
||||||
|
|
||||||
if [ "X${builddir}" = X ]; then
|
if [ "X${builddir}" = X ]; then
|
||||||
echo "Changing build dir to ${builddir}"
|
echo "Changing build dir to ${builddir}"
|
||||||
cd "${builddir}"
|
cd "${builddir}"
|
||||||
@@ -185,8 +193,23 @@ fi
|
|||||||
|
|
||||||
cd ${hversion} || exit 1
|
cd ${hversion} || exit 1
|
||||||
|
|
||||||
|
mkdir socket_wrapper_dir
|
||||||
|
SOCKET_WRAPPER_DIR=./socket_wrapper_dir
|
||||||
|
export SOCKET_WRAPPER_DIR
|
||||||
|
|
||||||
echo "Configuring and building ($hversion)"
|
echo "Configuring and building ($hversion)"
|
||||||
(./configure ${confflags} && make all check) > ab.txt 2>&1
|
./configure --enable-socket-wrapper ${confflags} > ab.txt 2>&1
|
||||||
|
if [ $? != 0 ] ; then
|
||||||
|
echo Configure failed
|
||||||
|
fi
|
||||||
|
make all >> ab.txt 2>&1
|
||||||
|
if [ $? != 0 ] ; then
|
||||||
|
echo Make all failed
|
||||||
|
fi
|
||||||
|
make check >> ab.txt 2>&1
|
||||||
|
if [ $? != 0 ] ; then
|
||||||
|
echo Make all failed
|
||||||
|
fi
|
||||||
|
|
||||||
if [ "X${resultdir}" != X ] ; then
|
if [ "X${resultdir}" != X ] ; then
|
||||||
cp ab.txt "${resultdir}/ab-${hversion}-${hostname}-${date}.txt"
|
cp ab.txt "${resultdir}/ab-${hversion}-${hostname}-${date}.txt"
|
||||||
|
Reference in New Issue
Block a user