README: Remove project leaders, history.
[cvc5.git] / .travis.yml
1 # Fix Travis write errors on Clang builds. These write errors occurred after
2 # a Travis update to new Trusty images on Dec. 12th 2017. The reason for these
3 # write errors is unknown. Using the deprecated builds did not fix the problem.
4 # Setting 'filter_secrets: false' as suggested here
5 # https://github.com/travis-ci/travis-ci/issues/4704#issuecomment-321777557
6 # fixes the problem.
7 filter_secrets: false
8
9 language: cpp
10 cache:
11 - apt
12 - ccache
13
14 sudo: false
15 dist: trusty
16
17 env:
18 global:
19 - CCACHE_COMPRESS=1
20 addons:
21 apt:
22 sources:
23 - ubuntu-toolchain-r-test
24 packages: &common_deps
25 - antlr3
26 - cmake
27 - cxxtest
28 - junit4
29 - libantlr3c-dev
30 - libcln-dev
31 - libgmp-dev
32 - libhamcrest-java
33 - openjdk-7-jdk
34 - swig3.0
35 before_install:
36 - eval "${MATRIX_EVAL}"
37 # Clang does not play nice with ccache (at least the versions offered by
38 # Travis), use a workaround:
39 # https://github.com/travis-ci/travis-ci/issues/5383#issuecomment-224630584
40 - |
41 if [ "$TRAVIS_OS_NAME" == "linux" ] && [ "$CXX" == "clang++" ]; then
42 export CFLAGS="-Qunused-arguments"
43 export CXXFLAGS="-Qunused-arguments"
44 sudo ln -s $(which ccache) /usr/lib/ccache/clang
45 sudo ln -s $(which ccache) /usr/lib/ccache/clang++
46 fi
47 before_script:
48 export JAVA_HOME=/usr/lib/jvm/java-7-openjdk-amd64
49 script:
50 - ccache -M 1G
51 - ccache -z
52 - ${CC} --version
53 - ${CXX} --version
54 - |
55 echo "travis_fold:start:load_script"
56 normal="$(echo -e '\033[0m')" red="$normal$(echo -e '\033[01;31m')" green="$normal$(echo -e '\033[01;32m')"
57 configureCVC4() {
58 echo "CVC4 config - $TRAVIS_CVC4_CONFIG";
59 ./configure.sh --name=build --prefix=$(pwd)/build/install --unit-testing $TRAVIS_CVC4_CONFIG
60 }
61 error() {
62 echo;
63 echo "${red}${1}${normal}";
64 echo;
65 exit 1;
66 }
67 makeCheck() {
68 cd build
69 make -j2 check ARGS='-LE regress[1-4]' CVC4_REGRESSION_ARGS='--no-early-exit' || error "BUILD/UNIT/SYSTEM/REGRESSION TEST FAILED"
70 ctest -j2 -L example || error "RUNNING EXAMPLES FAILED"
71 }
72 makeInstallCheck() {
73 cd build
74 make install -j2
75 echo -e "#include <cvc4/cvc4.h>\nint main() { CVC4::ExprManager em; return 0; }" > /tmp/test.cpp
76 $CXX -std=c++11 /tmp/test.cpp -I install/include -L install/lib -lcvc4 -lcln || exit 1
77 }
78 run() {
79 echo "travis_fold:start:$1"
80 echo "Running $1"
81 $1 || exit 1
82 echo "travis_fold:end:$1"
83 }
84 [ -n "$TRAVIS_CVC4" ] && [ -n "$TRAVIS_WITH_LFSC" ] && run contrib/get-lfsc-checker
85 [ -n "$TRAVIS_CVC4" ] && run configureCVC4
86 [ -n "$TRAVIS_CVC4" ] && run makeCheck && run makeInstallCheck
87 [ -z "$TRAVIS_CVC4" ] && error "Unknown Travis-CI configuration"
88 echo "travis_fold:end:load_script"
89 - echo; echo "${green}EVERYTHING SEEMED TO PASS!${normal}"
90 - ccache -s
91 matrix:
92 fast_finish: true
93 include:
94 # Test with GCC
95 - compiler: gcc
96 env:
97 - TRAVIS_CVC4=yes TRAVIS_WITH_LFSC=yes TRAVIS_CVC4_CONFIG='production --language-bindings=java --lfsc'
98 - compiler: gcc
99 env:
100 - TRAVIS_CVC4=yes TRAVIS_WITH_LFSC=yes TRAVIS_CVC4_CONFIG='debug --lfsc --no-debug-symbols'
101
102 #
103 # Test with Clang
104 - compiler: clang
105 env:
106 - TRAVIS_CVC4=yes TRAVIS_WITH_LFSC=yes TRAVIS_CVC4_CONFIG='debug --cln --gpl --no-debug-symbols --no-proofs'
107 notifications:
108 email:
109 on_success: change
110 on_failure: always