forked from valhalla/valhalla
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathcircle.yml
39 lines (36 loc) · 2.11 KB
/
circle.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
checkout:
post:
- git submodule sync
- git submodule update --init
- bash -c '[[ $(grep -cE "^ " Makefile.am) -eq 0 ]]'
machine:
environment:
PATH: /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
LD_LIBRARY_PATH: /usr/local/lib:/lib/x86_64-linux-gnu:/usr/lib/x86_64-linux-gnu:/lib32:/usr/lib32
dependencies:
override:
# get some dependencies
- (if [[ $(grep -cF trusty /etc/lsb-release) > 0 ]]; then sudo add-apt-repository -y ppa:kevinkreiser/libsodium; sudo add-apt-repository -y ppa:kevinkreiser/libpgm; sudo add-apt-repository -y ppa:kevinkreiser/zeromq3; sudo add-apt-repository -y ppa:kevinkreiser/czmq; sudo add-apt-repository -y ppa:zerebubuth/ccache; fi)
- sudo add-apt-repository -y ppa:kevinkreiser/prime-server
- sudo apt-get update
- sudo apt-get install -y autoconf automake make libtool pkg-config g++ gcc jq lcov protobuf-compiler vim-common libboost1.54-all-dev libboost-all-dev libcurl4-openssl-dev libgeos-dev libgeos++-dev liblua5.2-dev libprime-server0.6.3-dev libprotobuf-dev libspatialite-dev libsqlite3-dev lua5.2 prime-server0.6.3-bin ccache
# test some easier stuff
- (rc=0; for f in *.json; do python -c "import json; json.load(open('$f'))" || rc=$?; done; exit $rc;)
- (rc=0; for f in lua/*.lua; do lua $f || rc=$?; done; exit $rc;)
- (rc=0; for f in locales/*.json; do python -c "import json; json.load(open('$f'))" || rc=$?; done; exit $rc;)
- scripts/valhalla_build_config
# great sadness: this has to go here if we want to have caching, as the cache is _only_ saved after the dependencies step.
- (mkdir -p ${HOME}/.ccache && echo "max_size = 2.5G" > ${HOME}/.ccache/ccache.conf)
- ./autogen.sh
- ./configure CC="ccache gcc" CXX="ccache g++" --enable-coverage
- ccache -z
- ccache -s
- (rc=0; make test -j$(nproc) || rc=$?; for f in test/*.log; do if [ $(grep -Fc FAIL $f) -ne 0 ]; then echo "----------${f}----------"; cat ${f}; fi; done; exit ${rc};)
- ccache -s
cache_directories:
- "~/.ccache"
test:
override:
- sudo make install
post:
- cp -rp config.log Makefile test/*.log ${CIRCLE_ARTIFACTS}