Lower debhelper compat for jessie
[xapian.git] / .travis.yml
blobd3ae9546d5571bbeda23163ae8b9fa06cd109d52
1 dist: trusty
2 sudo: false
3 language: cpp
4 notifications:
5   irc: "chat.freenode.net#xapian-devel"
6 env:
7   global:
8     # Tell bootstrap where to clone ./common from
9     - XAPIAN_COMMON_CLONE_URL=https://github.com/xapian/xapian.git
10     - HOMEBREW_PACKAGES='doxygen help2man graphviz pngcrush libmagic pcre lua mono python2 python'
11 matrix:
12   include:
13     - compiler: gcc
14       os: linux
15       addons:
16         apt:
17           sources:
18             - ubuntu-toolchain-r-test
19           packages:
20             - doxygen
21             - graphviz
22             - help2man
23             - python-docutils
24             - pngcrush
25             - python-sphinx
26             - uuid-dev
27             - libpcre3-dev
28             - libmagic-dev
29             - lua5.2
30             - liblua5.2-dev
31             - mono-devel
32             - python-dev
33             - python3-dev
34             - tcl
35             - gcc-4.7
36             - g++-4.7
37       env: USE_CC=gcc-4.7 USE_CXX=g++-4.7
38     - compiler: clang
39       os: linux
40       # Clang is already installed, but we want to build using the
41       # llvm c++ library, not the GCC one. (Otherwise, depending on
42       # the GCC version, there can be issues.)
43       addons:
44         apt:
45           packages:
46             - doxygen
47             - graphviz
48             - help2man
49             - python-docutils
50             - pngcrush
51             - python-sphinx
52             - uuid-dev
53             - libpcre3-dev
54             - libmagic-dev
55             - tcl
56             - libc++-dev
57       # We also have to disable an error, because (older?)
58       # perl header files don't play nicely with clang.
59       env: USE_CC=clang USE_CXX='clang++ -stdlib=libc++' CXXFLAGS=-Wno-error=reserved-user-defined-literal
60     - os: osx
61       before_install:
62         - brew update
63         # "brew install" unhelpfully errors out if any package listed is
64         # already installed and up-to-date, but travis change what's installed
65         # by default from time to time so it's brittle to just filter out those
66         # installed by default from the list we need.  Instead we ignore the
67         # exit status from "brew install", then check later that
68         # "brew list --versions" says all the packages requested are installed.
69         - brew install $HOMEBREW_PACKAGES || true
70         - brew list --versions $HOMEBREW_PACKAGES
71         - pip2 install sphinx docutils
72         - pip3 install sphinx
73       env: PYTHON2=/usr/local/bin/python2 CXXFLAGS=-Wno-error=reserved-user-defined-literal confargs=--prefix=/Users/travis/XapianInstall installcore='make -C xapian-core install'
74     - os: linux
75       # (Ab)use env to label this build:
76       env: dummy="Automated run of xapian-check-patch"
77       # Override before_script to do nothing
78       before_script:
79       # Override script to diff from against the branch point from:
80       # * for a PR, the branch the PR targets
81       # * otherwise, master
82       script:
83         - git diff `[ "$TRAVIS_PULL_REQUEST" = false ] && echo master || echo "$TRAVIS_BRANCH"`...|xapian-maintainer-tools/xapian-check-patch
86 before_script:
87   # Bootstrap everything, then configure using our chosen compiler.
88   - ./bootstrap
89   - ./configure $confargs CC="$USE_CC" CXX="$USE_CXX"
90 script:
91   - make
92   - $installcore
93   - make check VERBOSE=1 AUTOMATED_TESTING=1
94   # grep '^' passes through all input while giving a non-zero exit status if
95   # that input is empty.
96   - git status --porcelain|grep '^' && { echo "The generated files listed above are not in .gitignore" ; exit 1; }; true