summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--.travis/Dockerfile2
-rwxr-xr-x.travis/epoxy-ci-linux.sh22
-rwxr-xr-x.travis/epoxy-ci-osx.sh14
3 files changed, 28 insertions, 10 deletions
diff --git a/.travis/Dockerfile b/.travis/Dockerfile
index 1764fd9..bd9b40a 100644
--- a/.travis/Dockerfile
+++ b/.travis/Dockerfile
@@ -27,5 +27,3 @@ ENV LANG=C.UTF-8 LANGUAGE=C.UTF-8 LC_ALL=C.UTF-8
RUN pip3 install meson
WORKDIR /root
-
-COPY epoxy-run-tests.sh .
diff --git a/.travis/epoxy-ci-linux.sh b/.travis/epoxy-ci-linux.sh
index 52f01ea..e95584f 100755
--- a/.travis/epoxy-ci-linux.sh
+++ b/.travis/epoxy-ci-linux.sh
@@ -1,5 +1,13 @@
#!/bin/bash
+dump_log_and_quit() {
+ local exitcode=$1
+
+ cat meson-logs/testlog.txt
+
+ exit $exitcode
+}
+
# Start Xvfb
XVFB_WHD=${XVFB_WHD:-1280x720x16}
@@ -8,13 +16,17 @@ xvfb=$!
export DISPLAY=:99
-mkdir _build
+srcdir=$( pwd )
+builddir=$( mktemp -d build_XXXXXX )
+
+meson --prefix /usr "$@" $builddir $srcdir || exit $?
+
+cd $builddir
-meson --prefix /usr "$@" _build . || exit $?
-ninja -C _build || exit $?
-meson test -C _build || exit $?
+ninja || exit $?
+meson test || dump_log_and_quit $?
-rm -rf _build
+cd ..
# Stop Xvfb
kill -9 ${xvfb}
diff --git a/.travis/epoxy-ci-osx.sh b/.travis/epoxy-ci-osx.sh
index 3e4021d..1a062a1 100755
--- a/.travis/epoxy-ci-osx.sh
+++ b/.travis/epoxy-ci-osx.sh
@@ -1,5 +1,13 @@
#!/bin/sh
+dump_log_and_quit() {
+ local exitcode=$1
+
+ cat meson-logs/testlog.txt
+
+ exit $exitcode
+}
+
export SDKROOT=$( xcodebuild -version -sdk macosx Path )
export CPPFLAGS=-I/usr/local/include
export LDFLAGS=-L/usr/local/lib
@@ -12,8 +20,8 @@ builddir=$( mktemp -d build_XXXXXX )
meson ${BUILDOPTS} $builddir $srcdir || exit $?
cd $builddir
+
ninja || exit $?
-meson test || exit $?
-cd ..
+meson test || dump_log_and_quit $?
-rm -rf $builddir
+cd ..