-
Notifications
You must be signed in to change notification settings - Fork 64
/
Copy path.travis.yml
123 lines (110 loc) · 3.71 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
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
matrix:
include:
# linux native
- os: linux
addons:
apt:
sources:
- ubuntu-toolchain-r-test
- llvm-toolchain-trusty-5.0
packages:
- clang-5.0
- gcc-6
- g++-6
- cmake
env:
- MATRIX_EVAL="CC=clang && CXX=clang++"
- BUILD_TYPE=native
group: travis_latest
dist: trusty
# linux android
- os: linux
addons:
apt:
sources:
- ubuntu-toolchain-r-test
- llvm-toolchain-trusty-5.0
packages:
- clang-5.0
- gcc-6
- g++-6
- cmake
env:
- MATRIX_EVAL="CC=clang && CXX=clang++"
- BUILD_TYPE=android
group: travis_latest
dist: trusty
# linux emscripten
- os: linux
services:
- docker
addons:
apt:
sources:
- ubuntu-toolchain-r-test
- llvm-toolchain-trusty-5.0
env:
- BUILD_TYPE=emscripten
group: travis_latest
dist: trusty
# osx native
- os: osx
env:
- MATRIX_EVAL="CC=clang && CXX=clang++"
- BUILD_TYPE=native
# osx android
- os: osx
env:
- MATRIX_EVAL="CC=clang && CXX=clang++"
- BUILD_TYPE=android
language: cpp
compiler: clang
before_script:
- uname -a
- "if [ $TRAVIS_OS_NAME == osx ] && [ $BUILD_TYPE == android ]; then \
brew tap caskroom/cask;
brew update;
brew cask install caskroom/versions/java8;
brew install ant;
wget --quiet --continue http://dl.google.com/android/repository/android-ndk-r12b-darwin-x86_64.zip -O ndk.zip;
unzip -o -q ndk.zip;
export ANDROID_NDK=`pwd`/android-ndk-r12b;
wget --quiet --continue https://dl.google.com/android/android-sdk_r24.4.1-macosx.zip;
unzip -o -q android-sdk_r24.4.1-macosx.zip;
export ANDROID_SDK=`pwd`/android-sdk-macosx;
export ANDROID_HOME=$ANDROID_SDK;
export PATH=${ANDROID_SDK}/tools:${ANDROID_SDK}/platform-tools:${ANDROID_NDK}:${PATH};
echo \"y\" | android update sdk -a -u -s -t platform-tools,build-tools-24.0.1,android-22;
fi"
- "if [ $TRAVIS_OS_NAME == linux ] && [ $BUILD_TYPE == android ]; then \
wget --quiet --continue http://dl.google.com/android/repository/android-ndk-r12b-linux-x86_64.zip -O ndk.zip;
unzip -o -q ndk.zip;
export ANDROID_NDK=`pwd`/android-ndk-r12b;
wget --quiet --continue http://dl.google.com/android/android-sdk_r24.4.1-linux.tgz;
tar -xzf android-sdk_r24.4.1-linux.tgz;
export ANDROID_SDK=`pwd`/android-sdk-linux;
jdk_switcher use oraclejdk8;
export ANDROID_HOME=$ANDROID_SDK;
export PATH=${ANDROID_SDK}/tools:${ANDROID_SDK}/platform-tools:${ANDROID_NDK}:${PATH};
echo \"y\" | android update sdk -a -u -s -t platform-tools,build-tools-24.0.1,android-22;
fi"
- if [ $TRAVIS_OS_NAME == linux ] && [ $BUILD_TYPE == emscripten ]; then
docker run -dit --name emscripten -e TRAVIS_OS_NAME='linux' -e BUILD_TYPE='emscripten' -v `pwd`:/engine -w /engine trzeci/emscripten:sdk-incoming-64bit bash ;
docker exec -it emscripten apt-get update ;
docker exec -it emscripten apt-get install -y cmake wget ;
fi
script:
- if [ $TRAVIS_OS_NAME == linux ] && [ $BUILD_TYPE == emscripten ]; then
docker exec -it emscripten ./scripts/travis-build.sh ;
else
./scripts/travis-build.sh ;
fi
deploy:
provider: pages
skip-cleanup: true
github-token: $GITHUB_TOKEN # Set in travis-ci.org dashboard, marked secure
keep-history: false
local-dir: bin-emscripten/bin/
on:
branch: master
condition: $BUILD_TYPE = emscripten