blob: ca68c3548e9fca343ce50c22d0c30058e626ec2d [file] [log] [blame]
david_williams0d3f08d2010-08-19 04:49:50 +00001#!/usr/bin/env bash
2
3# remember to leave no slashes on filename in source command,
4# (the commonVariations.shsource file, that is)
5# so that users path is used to find it (first)
6if [ -z $BUILD_INITIALIZED ]
7then
8 source commonVariations.shsource
9 source ${RELENG_CONTROL}/commonComputedVariables.shsource
10fi
11
12if [ -z $DISPLAYNUMBER ]
13then
david_williamsa21bb7c2010-10-16 05:22:48 +000014DISPLAYNUMBER=9
david_williams0d3f08d2010-08-19 04:49:50 +000015fi
16
17if [ -z $XVFBFONTPATH ]
18then
19 XVFBFONTPATH=/usr/share/fonts/misc/
20fi
21
22
23# limit data space (ld) to 10m bytes.
24# limit stack space (ls) to 1m bytes.
25# limit number of open files (lf) to 20
26# set connection time out to 60 seconds
27XVFBSCREEN=${BUILD_HOME}/tmp
28mkdir -p ${XVFBSCREEN}
29
david_williams6f5a60f2010-09-20 15:00:05 +000030#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 &
david_williams34a9cb22010-10-15 02:31:56 +000031# be sure to see /etc/X11/xorg.conf to see what screens are supported
32Xvfb :$DISPLAYNUMBER -screen 0 1280x1024x24 -fbdir "${XVFBSCREEN}" -fp "${XVFBFONTPATH}" &
david_williams0e40ef82010-08-21 15:39:46 +000033
david_williams0d3f08d2010-08-19 04:49:50 +000034XVFBPID=$!
35echo $XVFBPID > ccxvfb.pid
36
david_williamse4d7ae32010-08-24 16:11:23 +000037#
david_williams727e04e2010-09-23 23:16:17 +000038DISPLAY=:$DISPLAYNUMBER metacity --display=:$DISPLAYNUMBER --replace --sm-disable >/dev/null 2>&1 &
39METACITYPID=$!
40echo $METACITYPID > ccmetacity.pid
david_williamse4d7ae32010-08-24 16:11:23 +000041
david_williams0d3f08d2010-08-19 04:49:50 +000042echo "DISPLAYNUMBER: " $DISPLAYNUMBER;
43echo "XVFBFONTPATH: " $XVFBFONTPATH;
44echo "XVFBSCREEN: " $XVFBSCREEN;
45echo "XVFBPID: " $XVFBPID;
david_williams727e04e2010-09-23 23:16:17 +000046echo "METACITYPID: " $METACITYPID;
david_williams0d3f08d2010-08-19 04:49:50 +000047
48