forked from quassel/quassel
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.travis.yml
73 lines (65 loc) · 1.63 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
os:
- linux
sudo: required
dist: trusty
language: cpp
cache: ccache
compiler:
- gcc
- clang
env:
- QT_VERSION=qt4
- QT_VERSION=qt5
matrix:
include:
- os: osx
compiler: gcc
env: QT_VERSION=qt5
exclude:
- compiler: clang
env: QT_VERSION=qt4
install: |-
if [ "$TRAVIS_OS_NAME" == "linux" ]
then
sudo apt-get -qy install libqt5webkit5-dev qttools5-dev qtscript5-dev
sudo apt-get -qy install libdbusmenu-qt-dev libdbusmenu-qt5-dev
sudo apt-get -qy install libphonon-dev libphonon4qt5-dev
sudo apt-get -qy install libqca2-dev
sudo apt-get -qy install qt4-dev-tools qttools5-dev-tools
sudo apt-get -qy install libphonon4qt5experimental4 # https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=805096
elif [ "$TRAVIS_OS_NAME" == "osx" ]
then
brew update
brew install ninja qt5
fi
script: |-
mkdir build
cd build
if [ "$TRAVIS_OS_NAME" == "linux" ]
then
if [ "$QT_VERSION" = "qt4" ]; then cmake -DUSE_QT4=ON ..; fi
if [ "$QT_VERSION" = "qt5" ]; then cmake ..; fi
make
elif [ "$TRAVIS_OS_NAME" == "osx" ]
then
PATH=$PATH:/usr/local/opt/qt5/bin
if [[ "$TRAVIS_TAG" != "" && "$GH_TOKEN" != "" ]]
then
cmake -G"Ninja" .. -DCMAKE_BUILD_TYPE=Release -DDEPLOY=ON
else
cmake -G"Ninja" .. -DCMAKE_BUILD_TYPE=Release
fi
ninja install
fi
deploy:
provider: releases
api_key: "${GH_TOKEN}"
file_glob: true
file:
- "QuasselClient_MacOSX-x86_64_*.dmg"
- "QuasselCore_MacOSX-x86_64_*.dmg"
- "QuasselMono_MacOSX-x86_64_*.dmg"
skip_cleanup: true
on:
tags: true
condition: "$TRAVIS_OS_NAME == 'osx' && $GH_TOKEN != ''"