-
Notifications
You must be signed in to change notification settings - Fork 55
/
.travis.yml
75 lines (64 loc) · 2.32 KB
/
.travis.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
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
language: generic
notifications:
email: false
os:
- linux
sudo: true #for beineri qt561
dist: trusty
before_install:
- sudo add-apt-repository --yes ppa:beineri/opt-qt562-trusty
- sudo add-apt-repository --yes ppa:ubuntu-toolchain-r/test
- sudo apt-get -qq update
- sudo apt-get -qq install ${AF} qt56base qt56tools qt56svg # qttools5-dev
- sudo apt-get -qq install ${AF} cmake libhidapi-dev ${COMP}
- sudo apt-get -qq remove gcc-4.8 g++-4.8 --purge
#cache:
# - apt
before_cache:
- brew cleanup
cache:
directories:
# https://stackoverflow.com/questions/39930171/cache-brew-builds-with-travis-ci
- $HOME/Library/Caches/Homebrew
- /usr/local/Homebrew/
script: |
echo "${TRAVIS_OS_NAME}"
if [ "${TRAVIS_OS_NAME}" == "linux" ]; then
source /opt/qt56/bin/qt56-env.sh ;
export QMAKE=/opt/qt56/bin/qmake;
fi
if [ "$builder" == "qmake" ]; then
${QMAKE}
if [ "${TRAVIS_OS_NAME}" == "osx" ]; then make || exit 1; fi
if [ "${TRAVIS_OS_NAME}" == "linux" ]; then make CXX=${CXX} CC=${CC} LINK=${CXX} || exit 1 ; fi
elif [ "$builder" == "cmake" ]; then
cmake -DERROR_ON_WARNING=ON . && make VERBOSE=1 || exit 1;
fi
env:
matrix:
- builder=cmake CXX=clang++-3.8 CC=clang-3.8 COMP="clang-3.8 g++-5"
- builder=qmake CXX=clang++-3.8 CC=clang-3.8 COMP="clang-3.8 g++-5"
- builder=cmake CXX=g++-5 CC=gcc-5 COMP=g++-5
- builder=qmake CXX=g++-5 CC=gcc-5 COMP=g++-5
- builder=qmake CXX=g++-6 CC=gcc-6 COMP=g++-6
global:
- AF="-yq --no-install-suggests --no-install-recommends --force-yes" QMAKE=qmake
matrix:
include:
- os: osx
osx_image: xcode8.3 #default
before_install: &before
- brew update
- brew install qt5
- brew unlink cmake
- brew install cmake
- export
env: builder=cmake PATH="/usr/local/opt/qt5/bin:$PATH" CMAKE_PREFIX_PATH=/usr/local/lib/cmake MACOS_DEPLOYMENT_TARGET=10.9
- os: osx
osx_image: xcode8.3 #default
before_install: *before
env: builder=qmake PATH="/usr/local/opt/qt5/bin:$PATH" CMAKE_PREFIX_PATH=/usr/local/lib/cmake MACOS_DEPLOYMENT_TARGET=10.9
- os: osx
osx_image: xcode9.1
before_install: *before
env: builder=qmake PATH="/usr/local/opt/qt5/bin:$PATH" CMAKE_PREFIX_PATH=/usr/local/lib/cmake MACOS_DEPLOYMENT_TARGET=10.9