travis update (osx + linux) (#3041)

This commit is contained in:
tooomm 2018-01-21 23:07:25 +01:00 committed by Zach H
parent da7c7c1f83
commit 14a0c53fc1
3 changed files with 40 additions and 49 deletions

28
.ci/travis-compile.sh Normal file
View file

@ -0,0 +1,28 @@
#!/bin/bash
set -e
./servatrice/check_schema_version.sh
mkdir -p build
cd build
prefix=""
if [[ $TRAVIS_OS_NAME == "osx" ]]; then
export PATH="/usr/local/opt/ccache/libexec:$PATH"
prefix="-DCMAKE_PREFIX_PATH=$(echo /usr/local/opt/qt*/)"
fi
if [[ $TRAVIS_OS_NAME == "linux" ]]; then
prefix="-DCMAKE_PREFIX_PATH=$(echo /opt/qt5*/lib/cmake/)"
export LD_LIBRARY_PATH="$LD_LIBRARY_PATH:$(echo /opt/qt5*/lib/)"
fi
if [[ $BUILDTYPE == "Debug" ]]; then
cmake .. -DWITH_SERVER=1 -DCMAKE_BUILD_TYPE=$BUILDTYPE $prefix -DTEST=1
make -j2
make test
fi
if [[ $BUILDTYPE == "Release" ]]; then
cmake .. -DWITH_SERVER=1 -DCMAKE_BUILD_TYPE=$BUILDTYPE $prefix
make package -j2
fi

View file

@ -0,0 +1,10 @@
#!/bin/bash
if [[ $TRAVIS_OS_NAME == "osx" ]] ; then
brew install ccache # enable caching on mac (PATH only set in travis-compile.sh)
brew install --force qt@5.7
brew install protobuf
fi
if [[ $TRAVIS_OS_NAME == "linux" ]] ; then
echo Skipping... packages are installed with the Travis apt addon for sudo disabled container builds
fi