nim-eth/.travis.yml

46 lines
1.6 KiB
YAML
Raw Normal View History

2019-06-17 15:08:03 +00:00
language: c
2019-02-05 10:10:36 +00:00
# https://docs.travis-ci.com/user/caching/
cache:
directories:
2019-06-17 15:08:03 +00:00
- NimBinaries
- rocksdbCache
git:
# when multiple CI builds are queued, the tested commit needs to be in the last X commits cloned with "--depth X"
depth: 10
2019-02-05 10:10:36 +00:00
2019-02-05 12:01:10 +00:00
matrix:
include:
- os: linux
sudo: required
before_install:
2019-06-17 15:08:03 +00:00
- export LD_LIBRARY_PATH="$LD_LIBRARY_PATH:/usr/local/lib"
2019-02-05 12:01:10 +00:00
- os: osx
before_install:
2019-06-17 15:08:03 +00:00
- launchctl setenv LIBRARY_PATH /usr/local/lib # for RocksDB
2019-02-05 10:10:36 +00:00
install:
# build nim from our own branch - this to avoid the day-to-day churn and
# regressions of the fast-paced Nim development while maintaining the
# flexibility to apply patches
2019-06-17 15:08:03 +00:00
- curl -O -L -s -S https://raw.githubusercontent.com/status-im/nimbus/devel/build_nim.sh
- env MAKE="make -j2" bash build_nim.sh Nim csources dist/nimble NimBinaries
- export PATH=$PWD/Nim/bin:$PATH
2019-02-05 10:10:36 +00:00
2019-02-05 12:01:10 +00:00
# build our own rocksdb to test with a fixed version that we think works
2019-06-17 15:08:03 +00:00
- curl -O -L -s -S https://raw.githubusercontent.com/status-im/nimbus/devel/build_rocksdb.sh
- bash build_rocksdb.sh rocksdbCache
2019-02-05 12:01:10 +00:00
2019-06-17 15:08:03 +00:00
# no need to cache, lmdb is small and compiles very fast
- export LMDBVER="0.9.22"
- "wget https://github.com/LMDB/lmdb/archive/LMDB_$LMDBVER.tar.gz && tar xzf LMDB_$LMDBVER.tar.gz;"
- cd lmdb-LMDB_$LMDBVER/libraries/liblmdb && make -j2
2019-02-05 12:01:10 +00:00
- if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then sed -i 's| liblmdb.a||' Makefile && sudo make prefix=/usr install; fi
2019-06-17 15:08:03 +00:00
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then sudo cp -a liblmdb.so /usr/local/lib/liblmdb.dylib; fi
2019-02-05 12:01:10 +00:00
- cd ../../..
2019-02-05 10:10:36 +00:00
script:
- nimble install -y
- nimble test