-
Notifications
You must be signed in to change notification settings - Fork 21
/
.travis.yml
213 lines (195 loc) · 8.66 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
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
sudo: required
dist: bionic
language: cpp
#
# This is a "reduced" .travis.yml that bypasses building Qt dependencies, since the global timeout
# of travis-ci is too short to actually build that part. These pieces have been built offline and
# made available to the travis server. This can be either be compiled from Qt Source or run from
# their existing prebuilt binary package and applying the "Link Qt5 Source -> Qt4 Paths used in KJPBS"
# steps shown below.
#
env:
# ---------------------
# webchannel daemon build ( TODO: Rework this script to use these variables to create a build-matrix):
# ---------------------
- QT_DIR=$HOME/Qt/5.15.2 KJPBS_BUILD=Qt_5_15_2_gcc_64
compiler:
- gcc
# Handle git submodules ourselves (https://stackoverflow.com/questions/15674064/github-submodule-access-rights-travis-ci)
git:
submodules: false
before_install:
# ---------------------
- git submodule update --init --recursive
# ---------------------
# Install Dependencies:
# ---------------------
- sudo add-apt-repository -y ppa:maxmind/ppa
- sudo apt-get update -qq
- sudo apt-get install -qq --yes build-essential
- sudo apt-get install -qq --yes pkg-config
- sudo apt-get install -qq --yes cmake
- sudo apt-get install -qq --yes gperf bison
- sudo apt-get install -qq --yes libmaxminddb0 libmaxminddb-dev mmdb-bin geoipupdate
- sudo apt-get install -qq --yes libgl1-mesa-dev
# Easiest to slurp in Qt5 build dependencies, since we are building Qt5 as a pre-requisite:
# sudo apt-get build-dep -qq --yes libqt5core5a libqt5gui5 libqt5widgets5 libqt5network5 libqt5webchannel5 libqt5sql5 libqt5webengine5
- sudo apt-get install -qq --yes libqt5core5a libqt5gui5 libqt5widgets5 libqt5network5 libqt5webchannel5 libqt5sql5 libqt5webengine5
# A few helpers:
- sudo apt-get install -qq --yes perl python
- sudo apt-get install -qq --yes binfmt-support
- sudo apt-get install -qq --yes wget
install:
# ---------------------
# Source linkage:
# ---------------------
- mkdir -p ~/Documents/programs/Bible
- ln -s $TRAVIS_BUILD_DIR ~/Documents/programs/Bible/KingJamesPureBibleSearch
# ---------------------
# Get prebuilt Qt:
# ---------------------
# From: http://download.qt-project.org/official_releases/qt/5.15/5.15.2/
# Or: https://download.qt.io/official_releases/qt/5.15/5.15.2/
- cd ~/
- wget -nc http://vnc.purebiblesearch.com/ebe899bf-1dff-4b04-8e1b-8e63895a963d/Qt_5.15.2_18.04_bionic_gcc_64.tar.xz
- echo '8287879f0bd6233a050befb3b3f893cf12a6d0cb Qt_5.15.2_18.04_bionic_gcc_64.tar.xz' | sha1sum -c
- tar -Jxf Qt_5.15.2_18.04_bionic_gcc_64.tar.xz
- sudo chown -R $USER:$USER Qt/
# ---------------------
# Link Qt5 Source -> Qt4 Paths used in KJPBS:
# This has already been applied to the prebuilt binary
# above. If building a custom Qt, apply the follow to
# copy the 3rdparty/zlib* source folders (from the Qt
# source code) to the Qt binary folder.
# ---------------------
#- cd $$[QT_INSTALL_PREFIX]
#- mkdir -p src/3rdparty
#- cd src/3rdparty/
#- cp -r $QT_SRC/qtbase/src/3rdparty/zlib* .
# ---------------------
# Build QtStylePlugins:
# ---------------------
- cd ~/Documents/programs/Bible/KingJamesPureBibleSearch/programs
- mkdir -p build-qtstyleplugins-$KJPBS_BUILD
- cd build-qtstyleplugins-$KJPBS_BUILD
- $QT_DIR/bin/qmake CONFIG+=static CONFIG+=release CONFIG+=force-debug-info ../qtstyleplugins/qtstyleplugins.pro
- cp $TRAVIS_BUILD_DIR/travis_make_helper.sh .
# make -j 4
- ./travis_make_helper.sh
- make install
# ---------------------
# Build wwWidgets:
# ---------------------
- cd $HOME/Qt
- mkdir -p build-wwwidgets4-$KJPBS_BUILD/Release
- cd build-wwwidgets4-$KJPBS_BUILD/Release
- $QT_DIR/bin/qmake CONFIG+=release ~/Documents/programs/Bible/KingJamesPureBibleSearch/support/wwWidgets/wwwidgets4.pro
- cp $TRAVIS_BUILD_DIR/travis_make_helper.sh .
# make -j 4
- ./travis_make_helper.sh
- make install
- cp ~/Documents/programs/Bible/KingJamesPureBibleSearch/support/wwWidgets/translations/wwwidgets_*.qm $QT_DIR/translations/
before_script:
# ---------------------
# Setup KJPBS Build Folders:
# ---------------------
- cd ~/Documents/programs/Bible/KingJamesPureBibleSearch/programs/
- mkdir -p build-KJVCanOpener-$KJPBS_BUILD/Release
- mkdir -p build-KJVCanOpener_webchannel-$KJPBS_BUILD/Release
- mkdir -p build-KJVDataParse-$KJPBS_BUILD/Release
- mkdir -p build-KJVDictWord-$KJPBS_BUILD/Release
- mkdir -p build-KJVDiff-$KJPBS_BUILD/Release
- mkdir -p build-KJVLookup-$KJPBS_BUILD/Release
- mkdir -p build-KJVPhraseSearch-$KJPBS_BUILD/Release
- mkdir -p build-KJVSearch-$KJPBS_BUILD/Release
- mkdir -p build-KJVSumThing-$KJPBS_BUILD/Release
script:
# ---------------------
# Configure and Build KJPBS GUI:
# ---------------------
- cd ~/Documents/programs/Bible/KingJamesPureBibleSearch/programs/build-KJVCanOpener-$KJPBS_BUILD/Release
- $QT_DIR/bin/qmake CONFIG+=release CONFIG+=nospeech ../../KJVCanOpener/KJVCanOpener.pro
- cp $TRAVIS_BUILD_DIR/travis_make_helper.sh .
# make -j 4
- ./travis_make_helper.sh
# Don't run the GUI version on Travis as there is no display for QXcbConnection to connect to
# ./KingJamesPureBibleSearch --help
# ---------------------
# Configure and Build KJPBS WebChannel:
# ---------------------
- cd ~/Documents/programs/Bible/KingJamesPureBibleSearch/programs/build-KJVCanOpener_webchannel-$KJPBS_BUILD/Release
- $QT_DIR/bin/qmake CONFIG+=release CONFIG+=console CONFIG+=nospeech CONFIG+=webchannel ../../KJVCanOpener/KJVCanOpener.pro
- cp $TRAVIS_BUILD_DIR/travis_make_helper.sh .
# make -j 4
- ./travis_make_helper.sh
- ./KingJamesPureBibleSearch --help
# ---------------------
# Configure and Build KJVDataParse:
# ---------------------
- cd ~/Documents/programs/Bible/KingJamesPureBibleSearch/programs/build-KJVDataParse-$KJPBS_BUILD/Release
- $QT_DIR/bin/qmake CONFIG+=release ../../KJVDataParse/KJVDataParse.pro
- cp $TRAVIS_BUILD_DIR/travis_make_helper.sh .
# make -j 4
- ./travis_make_helper.sh
# Don't actually run this on Travis yet, as usage output is to stderr and return code is -1
# ./KJVDataParse
# ---------------------
# Configure and Build KJVDictWord:
# ---------------------
- cd ~/Documents/programs/Bible/KingJamesPureBibleSearch/programs/build-KJVDictWord-$KJPBS_BUILD/Release
- $QT_DIR/bin/qmake CONFIG+=release ../../KJVDictWord/KJVDictWord.pro
- cp $TRAVIS_BUILD_DIR/travis_make_helper.sh .
# make -j 4
- ./travis_make_helper.sh
# Don't actually run this on Travis yet, as usage output is to stderr and return code is -1
# ./KJVDictWord
# ---------------------
# Configure and Build KJVDiff:
# ---------------------
- cd ~/Documents/programs/Bible/KingJamesPureBibleSearch/programs/build-KJVDiff-$KJPBS_BUILD/Release
- $QT_DIR/bin/qmake CONFIG+=release ../../KJVDiff/KJVDiff.pro
- cp $TRAVIS_BUILD_DIR/travis_make_helper.sh .
# make -j 4
- ./travis_make_helper.sh
# Don't actually run this on Travis yet, as usage output is to stderr and return code is -1
# ./KJVDiff
# ---------------------
# Configure and Build KJVLookup:
# ---------------------
- cd ~/Documents/programs/Bible/KingJamesPureBibleSearch/programs/build-KJVLookup-$KJPBS_BUILD/Release
- $QT_DIR/bin/qmake CONFIG+=release ../../KJVLookup/KJVLookup.pro
- cp $TRAVIS_BUILD_DIR/travis_make_helper.sh .
# make -j 4
- ./travis_make_helper.sh
# Don't actually run this on Travis yet, as usage output is to stderr and return code is -1
# ./KJVLookup
# ---------------------
# Configure and Build KJVPhraseSearch:
# ---------------------
- cd ~/Documents/programs/Bible/KingJamesPureBibleSearch/programs/build-KJVPhraseSearch-$KJPBS_BUILD/Release
- $QT_DIR/bin/qmake CONFIG+=release ../../KJVPhraseSearch/KJVPhraseSearch.pro
- cp $TRAVIS_BUILD_DIR/travis_make_helper.sh .
# make -j 4
- ./travis_make_helper.sh
# Don't actually run this on Travis yet, as usage output is to stderr and return code is -1
# ./KJVPhraseSearch
# ---------------------
# Configure and Build KJVSearch:
# ---------------------
- cd ~/Documents/programs/Bible/KingJamesPureBibleSearch/programs/build-KJVSearch-$KJPBS_BUILD/Release
- $QT_DIR/bin/qmake CONFIG+=release ../../KJVSearch/KJVSearch.pro
- cp $TRAVIS_BUILD_DIR/travis_make_helper.sh .
# make -j 4
- ./travis_make_helper.sh
# Don't actually run this on Travis yet, as usage output is to stderr and return code is -1
# ./KJVSearch
# ---------------------
# Configure and Build KJVSumThing:
# ---------------------
- cd ~/Documents/programs/Bible/KingJamesPureBibleSearch/programs/build-KJVSumThing-$KJPBS_BUILD/Release
- $QT_DIR/bin/qmake CONFIG+=release ../../KJVSumThing/KJVSumThing.pro
- cp $TRAVIS_BUILD_DIR/travis_make_helper.sh .
# make -j 4
- ./travis_make_helper.sh
# Don't actually run this on Travis yet, as usage output is to stderr and return code is -1
# ./KJVSumThing