summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlexis Hildebrandt <afh@surryhill.net>2014-04-21 12:35:54 +0200
committerAlexis Hildebrandt <afh@surryhill.net>2014-04-23 11:30:44 +0200
commit4c4367fe6b7f184605c900735fc5b646f45311c1 (patch)
treeabcd2570eef45b492f4b7396d74ed8d03ff2211e
parent4707122eede9746b36bbaa0dab0b419e11b0433b (diff)
downloadfork-ledger-4c4367fe6b7f184605c900735fc5b646f45311c1.tar.gz
fork-ledger-4c4367fe6b7f184605c900735fc5b646f45311c1.tar.bz2
fork-ledger-4c4367fe6b7f184605c900735fc5b646f45311c1.zip
Fix Travis CI build
- Install and use GNU GCC 4.8 to support required C++11 standard - Build Boost (1.55.0) libraries needed by ledger - Export build and cmake variables to find locally built Boost
-rw-r--r--.travis.yml39
-rwxr-xr-xacprep1
2 files changed, 32 insertions, 8 deletions
diff --git a/.travis.yml b/.travis.yml
index eefc1859..29a4b246 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -1,18 +1,41 @@
+# Since the Travis CI environment (URL) provides GNU GCC 4.6, which does not
+# support -std=c++11 GNU GCC 4.8 is installed. Additionally boost 1.55.0 is
+# compiled from source, since in the Travis CI environment only boost 1.46 is
+# available and no backported package was found on the net.
+
language: cpp
compiler:
- clang
- gcc
+
+before_install:
+ # Add software package repository, containing updated build toochain, i.e. GNU GCC 4.8
+ - sudo add-apt-repository ppa:ubuntu-toolchain-r/test --yes
+ - sudo apt-get update -qq
+ # Download boost 1.55 and extract the source archive
+ - wget --no-verbose --output-document=boost-trunk.tar.bz2 http://sourceforge.net/projects/boost/files/boost/1.55.0/boost_1_55_0.tar.bz2/download
+ - export BOOST_ROOT="$TRAVIS_BUILD_DIR/../boost-trunk"
+ - export CMAKE_MODULE_PATH="$BOOST_ROOT"
+ - mkdir -p $BOOST_ROOT
+ - tar jxf boost-trunk.tar.bz2 --strip-components=1 -C $BOOST_ROOT
+
install:
- - "./acprep dependencies"
- - wget http://sourceforge.net/projects/boost/files/boost/1.55.0/boost_1_55_0.tar.bz2/download
- - tar jxf download
- - mv boost_1_55_0 $HOME/boost-trunk
+ # Install GNU GCC 4.8 required by use of C++11
+ - sudo apt-get install -qq g++-4.8 gcc-4.8
+ - export CXX="g++-4.8" CC="gcc-4.8"
+ # Build boost libraries required by ledger
+ - (cd $BOOST_ROOT; ./bootstrap.sh --with-libraries=date_time,filesystem,system,iostreams,regex,python,test)
+ - (cd $BOOST_ROOT; ./b2 threading=multi --prefix=$BOOST_ROOT -d0 install)
+ # Install further dependencies
+ - ./acprep dependencies
+
before_script:
- - BOOST="$HOME/boost-trunk"
- - "./acprep opt make --python"
+ - ./acprep opt make --python --boost=$BOOST_ROOT
+
script:
- - "./acprep check -- --output-on-failure"
- - "PYTHONPATH=. python python/demo.py"
+ - ./acprep check -- --output-on-failure
+ - PYTHONPATH=. python python/demo.py
+
notifications:
email:
on_success: change
diff --git a/acprep b/acprep
index dde3e62f..754a2427 100755
--- a/acprep
+++ b/acprep
@@ -868,6 +868,7 @@ class PrepareBuild(CommandLineApp):
if self.options.boost_root:
conf_args.append('-DBOOST_ROOT=%s' %
self.options.boost_root)
+ conf_args.append('-DBoost_NO_SYSTEM_PATHS=TRUE')
if self.options.boost_suffix:
conf_args.append('-DBoost_COMPILER=%s' %
self.options.boost_suffix)