Skip to content

Commit

Permalink
Enable osx in Travis
Browse files Browse the repository at this point in the history
Newer xcode doesn't include pip, so we have to use get-pip to install
pip for sphinx on OSX.
  • Loading branch information
SpamapS committed Dec 11, 2017
1 parent 8da9ee1 commit 97e714f
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 11 deletions.
15 changes: 4 additions & 11 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
os:
- linux
- osx
language: cpp
dist: trusty
sudo: required
Expand Down Expand Up @@ -26,17 +29,7 @@ matrix:
env: COMPILER=g++-5

before_install:
- sudo apt-get update -qq
- if [ "$COMPILER" = "g++-4.9" ]; then sudo apt-get install -qq g++-4.9; fi
- if [ "$COMPILER" = "g++-4.9" ]; then export CXX="g++-4.9" CC="gcc-4.9"; fi
- if [ "$COMPILER" = "g++-5" ]; then sudo apt-get install -qq g++-5; fi
- if [ "$COMPILER" = "g++-5" ]; then export CXX="g++-5" CC="gcc-5"; fi
- sudo apt-get install -y libboost-all-dev
- sudo apt-get install -y gperf
- sudo apt-get install -y libevent-dev
- sudo apt-get install -y uuid-dev
- sudo apt-get install -y python-sphinx
- sudo apt-get install -y libhiredis-dev
- . scripts/travis-$TRAVIS_OS_NAME.sh

script:
- ./bootstrap.sh -a
Expand Down
7 changes: 7 additions & 0 deletions scripts/travis-linux.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
sudo apt-get update -qq
COMPILER_PACKAGE=""
if [ "$COMPILER" = "g++-4.9" ]; then COMPILER_PACKAGE=g++-4.9
elif [ "$COMPILER" = "g++-5" ]; then COMPILER_PACKAGE=g++-5; fi
sudo apt-get install -y libboost-all-dev gperf libevent-dev uuid-dev python-sphinx libhiredis-dev $COMPILER_PACKAGE
if [ "$COMPILER" = "g++-4.9" ]; then export CXX="g++-4.9" CC="gcc-4.9"
elif [ "$COMPILER" = "g++-5" ]; then export CXX="g++-5" CC="gcc-5"; fi
7 changes: 7 additions & 0 deletions scripts/travis-osx.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
#brew install boost
wget https://bootstrap.pypa.io/get-pip.py
sudo -H python get-pip.py
sudo -H pip install virtualenv
virtualenv sphinx
. sphinx/bin/activate
pip install sphinx

0 comments on commit 97e714f

Please sign in to comment.