@@ -11,41 +11,27 @@ sudo: false
1111
1212addons :
1313 apt :
14+ sources :
15+ - sourceline : ppa:xapian-backports/ppa
16+
1417 packages :
15- # required for install of xapian-bindings-1.2.16
18+ # Required to build/ install the xapian-binding
1619 - libxapian-dev
17- # required for install of 1.3.7 version of xapian
18- - python-sphinx
1920 # Required to install pyme
2021 - libgpgme11-dev
2122 - swig
2223
2324before_install :
25+ # Sphinx required to build the xapian python bindings
26+ - pip install sphinx
27+ - XAPIAN_VER=$(dpkg -l libxapian-dev | tail -n 1 | awk '{print $3}' | cut -d '-' -f 1)
2428 - cd /tmp
25- # commented out section of xapian installing core and bindings.
26- # install core 1.3.7 as version in trusty deb is 1.2. need 1.3 for python 3.
27- # - curl -s -O https://oligarchy.co.uk/xapian/1.3.7/xapian-core-1.3.7.tar.xz
28- # - tar -Jxvf xapian-core-1.3.7.tar.xz
29- # - cd xapian-core-1.3.7/
30- # - ./configure && make && sudo make install
31- # - cd /tmp
32- # - curl -s -O https://oligarchy.co.uk/xapian/1.3.7/xapian-bindings-1.3.7.tar.xz
33- # - tar -Jxvf xapian-bindings-1.3.7.tar.xz
34- # - cd xapian-bindings-1.3.7/
35- # - ./configure --prefix=$VIRTUAL_ENV --with-python && make && make install
36- # the above fails on python 2.7 with:
37- # ImportError: libxapian-1.3.so.8: cannot open shared object file:
38- # No such file or directory
39- # That library is installed by xapian-core-1.3.7 above. My guess
40- # is that the virtualenv is created by travis software before
41- # before_install is called and xapian-core is installed.
42- # So libxapian is not present in the virtualenv python install.
43- # See https://travis-ci.org/roundup-tracker/roundup/builds/406481321
44- # Install 1.2.16 xapian-bindings compatible with xapian-dev in ubuntu trusty
45- - curl -s -O https://oligarchy.co.uk/xapian/1.2.16/xapian-bindings-1.2.16.tar.xz
46- - tar -Jxvf xapian-bindings-1.2.16.tar.xz
47- - cd xapian-bindings-1.2.16/
48- - ./configure --prefix=$VIRTUAL_ENV --with-python && make && make install
29+ - curl -s -O https://oligarchy.co.uk/xapian/$XAPIAN_VER/xapian-bindings-$XAPIAN_VER.tar.xz
30+ - tar -Jxvf xapian-bindings-$XAPIAN_VER.tar.xz
31+ - cd xapian-bindings-$XAPIAN_VER/
32+ - if [[ $TRAVIS_PYTHON_VERSION == "2."* ]]; then ./configure --prefix=$VIRTUAL_ENV --with-python; fi
33+ - if [[ $TRAVIS_PYTHON_VERSION == "3."* ]]; then ./configure --prefix=$VIRTUAL_ENV --with-python3; fi
34+ - make && make install
4935
5036 # change back to the checked out repository directory
5137 - cd $TRAVIS_BUILD_DIR
0 commit comments