aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--.travis.yml28
-rwxr-xr-xscripts/travis28
2 files changed, 55 insertions, 1 deletions
diff --git a/.travis.yml b/.travis.yml
index 36912d0..56b82da 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -5,4 +5,30 @@ compiler:
5os: 5os:
6 - linux 6 - linux
7 - osx 7 - osx
8script: "./dist.sh" 8env:
9 - ARCH=native
10 - ARCH=mingw32
11 - ARCH=mingw64
12matrix:
13 include:
14 - compiler: clang
15 os: osx
16 env: ARCH=native
17 - compiler: gcc
18 os: osx
19 env: ARCH=native
20 - compiler: clang
21 os: linux
22 env: ARCH=native
23 - compiler: gcc
24 os: linux
25 env: ARCH=native
26 - compiler: gcc
27 os: linux
28 env: ARCH=mingw32
29 - compiler: gcc
30 os: linux
31 env: ARCH=mingw64
32
33script:
34 "./scripts/travis"
diff --git a/scripts/travis b/scripts/travis
new file mode 100755
index 0000000..4d28782
--- /dev/null
+++ b/scripts/travis
@@ -0,0 +1,28 @@
1#!/bin/sh
2set -e
3
4./autogen.sh
5
6if [ "x$ARCH" = "xnative" ]; then
7 ./configure --enable-libtls
8 make clean
9 make -j distcheck
10else
11 CPU=i686
12 if [ "x$ARCH" = "xmingw64" ]; then
13 CPU=x86_64
14 fi
15 export CC=$CPU-w64-mingw32-gcc
16
17 if [ -z $(which $CC) ]; then
18 # Update Ubuntu 12.04 with current mingw toolchain
19 apt-get update && apt-get install -y python-software-properties
20 apt-add-repository -y ppa:tobydox/mingw-x-precise
21 apt-get update && apt-get install -y $ARCH-x-gcc make
22 export PATH=$PATH:/opt/$ARCH/bin
23 fi
24
25 ./configure --host=$CPU-w64-mingw32 --enable-libtls
26 make clean
27 make -j
28fi