about summary refs log tree commit diff
path: root/.travis.ubuntu.sh
diff options
context:
space:
mode:
authorVincent Ambo <tazjin@google.com>2020-05-27T00·26+0100
committerVincent Ambo <tazjin@google.com>2020-05-27T00·26+0100
commitafe04691aca3f669f517adaeb5bd4a87a481fb4a (patch)
tree60ae6c91a3959b2f6486256e26ff126e598d1e5d /.travis.ubuntu.sh
Squashed 'third_party/glog/' content from commit 9ef754a3023
git-subtree-dir: third_party/glog
git-subtree-split: 9ef754a3023e6fd10f20fe53dfca96dd898182e3
Diffstat (limited to '.travis.ubuntu.sh')
-rwxr-xr-x.travis.ubuntu.sh18
1 files changed, 18 insertions, 0 deletions
diff --git a/.travis.ubuntu.sh b/.travis.ubuntu.sh
new file mode 100755
index 0000000000..1043f31ef9
--- /dev/null
+++ b/.travis.ubuntu.sh
@@ -0,0 +1,18 @@
+#!/bin/bash
+set -e
+set -x
+
+uname -a
+
+cmake -H. -B_build_${TOOLCHAIN} -DCMAKE_TOOLCHAIN_FILE="${PWD}/toolchains/${TOOLCHAIN}.cmake"
+cmake --build _build_${TOOLCHAIN} -- -j4
+
+if [ "$RUN_TESTS" = true ]; then
+	case "$TOOLCHAIN" in linux-mingw*)
+		echo "copy runtime libraries needed for tests into build directory"
+		cp /usr/x86_64-w64-mingw32/lib/libwinpthread-1.dll /usr/lib/gcc/x86_64-w64-mingw32/7.3-win32/{libstdc++-6.dll,libgcc_s_seh-1.dll} _build_${TOOLCHAIN}
+	esac
+	CTEST_OUTPUT_ON_FAILURE=1 cmake --build _build_${TOOLCHAIN} --target test
+fi
+
+