-
Notifications
You must be signed in to change notification settings - Fork 5
/
.travis.yml
80 lines (71 loc) · 3.65 KB
/
.travis.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
language: cpp
sudo: false
matrix:
include:
# Linux GCC Builds
- os: linux
compiler: gcc
addons: &gcc9
apt:
sources: ['ubuntu-toolchain-r-test']
packages: ['g++-9', 'gcc-9']
env: GCCVER='9' CXX_COMPILER='g++-9' C_COMPILER='gcc-9'
# 4/ OSX GCC Builds
- os: osx
compiler: gcc
osx_image: xcode11.2
addons:
homebrew:
packages:
- gcc
env: GCCVER='9' CXX_COMPILER='g++-9' C_COMPILER='gcc-9'
before_script:
## OSX
- cd ${TRAVIS_BUILD_DIR}
- export CXX=${CXX_COMPILER}
- export CC=${C_COMPILER}
- wget --progress=dot:mega https://gmplib.org/download/gmp/gmp-6.1.2.tar.bz2 ; tar xjf gmp-6.1.2.tar.bz2 ; cd gmp-6.1.2 ; ./configure --enable-cxx --enable-fat --prefix=$(pwd)/../usr/local ; make -j ; make install ; cd .. ;
- wget --progress=dot:mega https://github.com/libexpat/libexpat/archive/R_2_2_4.tar.gz ; tar xzf R_2_2_4.tar.gz ; cd libexpat-R_2_2_4/expat/ ; ./buildconf.sh ; ./configure --prefix=$(pwd)/../../usr/local --without-xmlwf ; make -j ; make install ; cd ../.. ;
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then export TARGETBRANCH=osx ; fi
# linux only
- if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then export AR=gcc-ar-${GCCVER} ; fi
- if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then export RANLIB=gcc-ranlib-${GCCVER} ; fi
- if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then export NM=gcc-nm-${GCCVER} ; fi
- if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then export TARGETBRANCH=gh-pages ; fi
script :
- /bin/bash ./antlr.sh
- /bin/sh ./tag.sh
- autoreconf -vfi
# - mkdir usr && mkdir usr/local
- if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then wget --progress=dot:mega https://lip6.github.io/libDDD/linux.tgz ; tar xzf linux.tgz ; fi
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then wget --progress=dot:mega https://github.com/lip6/libDDD/raw/osx/osx.tgz ; tar xzf osx.tgz ; fi
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then export LTO=--enable-nolto ; fi
- ./configure $LTO --prefix=$PWD/usr/local/ --with-libexpat=$PWD/usr/local/ --with-libddd=$PWD/usr/local/ --with-gmp=$PWD/usr/local/ --with-antlrc=$PWD/usr/local/ --with-antlrjar=$PWD/usr/local/lib/antlr-3.4-complete.jar CPPFLAGS="-I$(pwd)/usr/local/include -DNDEBUG" LDFLAGS="-L$(pwd)/usr/local/lib" || cat config.log ;
- make
- cd tests
- ( rc=0 ; for TEST in *.data ; do travis_wait ./run_test.pl $TEST || rc=$? ; done; exit $rc)
- cd ..
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then strip bin/its-reach ; fi
# linux only
- if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then strip -s bin/its-reach ; fi
- cp bin/its-reach website/its-reach
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then strip bin/gal2c ; fi
# linux only
- if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then strip -s bin/gal2c ; fi
- cp bin/gal2c website/gal2c
- make install
- tar cvzf $TRAVIS_OS_NAME.tgz usr/
- mv $TRAVIS_OS_NAME.tgz website/
- make dist
- mv its*.tar.gz website/
deploy:
provider: pages
skip_cleanup: true
github_token: $GITHUB_TOKEN # Set in travis-ci.org dashboard
local_dir: website/
target_branch: $TARGETBRANCH
on:
branch: master
after_deploy:
- curl -s -X POST -H "Content-Type:application/json" -H "Accept:application/json" -H "Travis-API-Version:3" -H "Authorization:token $APITOKEN" -d '{"request":{"message":"Triggered by LibITS build.","branch":"master"}}' https://api.travis-ci.org/repo/lip6%2FITS-CTL/requests
- curl -s -X POST -H "Content-Type:application/json" -H "Accept:application/json" -H "Travis-API-Version:3" -H "Authorization:token $APITOKEN" -d '{"request":{"message":"Triggered by LibITS build.","branch":"master"}}' https://api.travis-ci.org/repo/lip6%2FITS-LTL/requests