blob: 10654f550ae9d65a900e46396defab4c9edc9ac1 [file] [log] [blame]
#!/usr/bin/env bash
# remember to leave no slashes on filename in source command,
# (the commonVariations.shsource file, that is)
# so that users path is used to find it (first)
if [ -z $BUILD_INITIALIZED ]
then
source commonVariations.shsource
source ${RELENG_CONTROL}/commonComputedVariables.shsource
fi
if [ -z $DISPLAYNUMBER ]
then
DISPLAYNUMBER=1001
fi
if [ -z $XVFBFONTPATH ]
then
XVFBFONTPATH=/usr/share/fonts/misc/
fi
# limit data space (ld) to 10m bytes.
# limit stack space (ls) to 1m bytes.
# limit number of open files (lf) to 20
# set connection time out to 60 seconds
XVFBSCREEN=${BUILD_HOME}/tmp
mkdir -p ${XVFBSCREEN}
Xvfb :$DISPLAYNUMBER -screen 0 1600x1200x16 -fbdir "${XVFBSCREEN}" -fp "${XVFBFONTPATH}" -ld 5120 -ls 512 -lf 20 -to 60 -reset -bs -auth ${RELENG_CONTROL}/xvfb-auth.cfg &
#Xvfb :$DISPLAYNUMBER -screen 0 1280x1024x24 -fbdir "${XVFBSCREEN}" -fp "${XVFBFONTPATH}" &
XVFBPID=$!
echo $XVFBPID > ccxvfb.pid
#
DISPLAY=:$DISPLAYNUMBER metacity --display=:$DISPLAYNUMBER --replace --sm-disable >/dev/null 2>&1 &
METACITYPID=$!
echo $METACITYPID > ccmetacity.pid
echo "DISPLAYNUMBER: " $DISPLAYNUMBER;
echo "XVFBFONTPATH: " $XVFBFONTPATH;
echo "XVFBSCREEN: " $XVFBSCREEN;
echo "XVFBPID: " $XVFBPID;
echo "METACITYPID: " $METACITYPID;