test: Handle srcdir != builddir in Xvfb testing

Reviewed-by: Adam Jackson <ajax@redhat.com>
Signed-off-by: Eric Anholt <eric@anholt.net>
This commit is contained in:
Eric Anholt 2016-09-25 13:30:16 -07:00 committed by Adam Jackson
parent add4979260
commit 8d5e0c07b9
2 changed files with 9 additions and 2 deletions

View File

@ -26,7 +26,8 @@ TESTS = \
$(NULL)
TESTS_ENVIRONMENT = \
XSERVER_DIR=$(abs_top_builddir) \
XSERVER_DIR=$(abs_top_srcdir) \
XSERVER_BUILDDIR=$(abs_top_builddir) \
$(XORG_MALLOC_DEBUG_ENV) \
$(NULL)

View File

@ -20,12 +20,18 @@ if test "x$XSERVER_DIR" = "x"; then
exit 1
fi
if test "x$XSERVER_BUILDDIR" = "x"; then
echo "XSERVER_BUILDDIR must be set to the build directory of the xserver repository."
# Exit as a real failure because it should always be set.
exit 1
fi
export PIGLIT_RESULTS_DIR=$PIGLIT_DIR/results/xvfb
startx \
$XSERVER_DIR/test/scripts/xinit-piglit-session.sh \
-- \
$XSERVER_DIR/hw/vfb/Xvfb \
$XSERVER_BUILDDIR/hw/vfb/Xvfb \
-noreset \
-screen scrn 1280x1024x24