Mercurial > octave-buildbot
annotate master.cfg @ 17:cfa6aaf2a7eb
use --without-fontconfig and --without-freetype for no-extras builds
author | John W. Eaton <jwe@octave.org> |
---|---|
date | Fri, 05 Jun 2020 16:04:08 +0000 |
parents | b2e9c6f7d3e5 |
children | 27f9d077b8b5 |
rev | line source |
---|---|
0 | 1 ## -*- python -*- |
2 ## ex: set syntax=python: | |
3 | |
4 ## This is a sample buildmaster config file. It must be installed as | |
5 ## 'master.cfg' in your buildmaster's base directory. | |
6 | |
7 ## This is the dictionary that the buildmaster pays attention to. We | |
8 ## also use a shorter alias to save typing. | |
9 | |
10 c = BuildmasterConfig = {} | |
11 | |
12 ## WORKERS | |
13 | |
14 ## The 'worker' list defines the set of recognized workers. Each | |
15 ## element is a Worker object, specifying a unique worker name and | |
16 ## password. The same worker name and password must be configured on | |
17 ## the worker. | |
18 | |
19 from buildbot.worker import Worker | |
20 | |
8
e02079ee69d1
master.cfg: add info about config file
John W. Eaton <jwe@octave.org>
parents:
6
diff
changeset
|
21 ## The octave_buildbot_config file imported below is not in hg archive because |
e02079ee69d1
master.cfg: add info about config file
John W. Eaton <jwe@octave.org>
parents:
6
diff
changeset
|
22 ## it contains password and system configuration info. |
e02079ee69d1
master.cfg: add info about config file
John W. Eaton <jwe@octave.org>
parents:
6
diff
changeset
|
23 ## |
e02079ee69d1
master.cfg: add info about config file
John W. Eaton <jwe@octave.org>
parents:
6
diff
changeset
|
24 ## This file defines two variables, workers and master_id_and_pass, with |
e02079ee69d1
master.cfg: add info about config file
John W. Eaton <jwe@octave.org>
parents:
6
diff
changeset
|
25 ## the following format: |
e02079ee69d1
master.cfg: add info about config file
John W. Eaton <jwe@octave.org>
parents:
6
diff
changeset
|
26 ## |
e02079ee69d1
master.cfg: add info about config file
John W. Eaton <jwe@octave.org>
parents:
6
diff
changeset
|
27 ## workers = {"worker-name-0": |
e02079ee69d1
master.cfg: add info about config file
John W. Eaton <jwe@octave.org>
parents:
6
diff
changeset
|
28 ## {"pass": "worker-0-password", |
e02079ee69d1
master.cfg: add info about config file
John W. Eaton <jwe@octave.org>
parents:
6
diff
changeset
|
29 ## "max_builds": 3, |
e02079ee69d1
master.cfg: add info about config file
John W. Eaton <jwe@octave.org>
parents:
6
diff
changeset
|
30 ## "desc": "info about worker-0"}, |
e02079ee69d1
master.cfg: add info about config file
John W. Eaton <jwe@octave.org>
parents:
6
diff
changeset
|
31 ## "worker-name-1": |
e02079ee69d1
master.cfg: add info about config file
John W. Eaton <jwe@octave.org>
parents:
6
diff
changeset
|
32 ## {"pass": "worker-1-password", |
e02079ee69d1
master.cfg: add info about config file
John W. Eaton <jwe@octave.org>
parents:
6
diff
changeset
|
33 ## "max_builds": 3, |
e02079ee69d1
master.cfg: add info about config file
John W. Eaton <jwe@octave.org>
parents:
6
diff
changeset
|
34 ## "desc": "info about worker-1"}, |
e02079ee69d1
master.cfg: add info about config file
John W. Eaton <jwe@octave.org>
parents:
6
diff
changeset
|
35 ## ...} |
e02079ee69d1
master.cfg: add info about config file
John W. Eaton <jwe@octave.org>
parents:
6
diff
changeset
|
36 ## |
e02079ee69d1
master.cfg: add info about config file
John W. Eaton <jwe@octave.org>
parents:
6
diff
changeset
|
37 ## master_id_and_pass = {"master-login-id" : "master-password"} |
e02079ee69d1
master.cfg: add info about config file
John W. Eaton <jwe@octave.org>
parents:
6
diff
changeset
|
38 |
0 | 39 import octave_buildbot_config |
40 | |
41 c["workers"] = [] | |
42 | |
14
24e67c30e215
syntax update for buildbot 2.7
John W. Eaton <jwe@octave.org>
parents:
13
diff
changeset
|
43 for worker, info in octave_buildbot_config.workers.items (): |
0 | 44 c["workers"].append (Worker (worker, info["pass"], max_builds = info["max_builds"])) |
45 | |
46 ## 'protocols' contains information about protocols which master will | |
47 ## use for communicating with workers. You must define at least 'port' | |
48 ## option that workers could connect to your master with this protocol. | |
49 ## 'port' must match the value configured into the workers (with | |
50 ## their --master option) | |
51 | |
52 c["protocols"] = { "pb" : { "port" : 9990 }} | |
53 | |
54 ## SOURCES | |
55 | |
56 ## The main mercurial repository server. This machines pings the | |
57 ## PBChangeSource. The workers should pull from it, to make | |
58 ## sure they are in sync. | |
59 | |
60 octave_hg_repo = "https://hg.savannah.gnu.org/hgweb/octave" | |
16
b2e9c6f7d3e5
use savannah for both stable and default branches of octave
John W. Eaton <jwe@octave.org>
parents:
15
diff
changeset
|
61 stable_octave_hg_repo = "https://hg.savannah.gnu.org/hgweb/octave" |
0 | 62 mxe_octave_hg_repo = "http://hg.octave.org/mxe-octave" |
63 | |
64 ## CHANGESOURCES | |
65 | |
66 ## the 'change_source' setting tells the buildmaster how it should | |
67 ## find out about source code changes. Here we point to the buildbot | |
68 ## clone of Octave. | |
69 | |
70 from buildbot.changes.hgpoller import HgPoller | |
71 | |
72 c["change_source"] = [] | |
73 | |
74 c["change_source"].append (HgPoller (project = "octave", | |
75 repourl = octave_hg_repo, | |
76 workdir = "octave-hg-repo", | |
77 pollinterval = 5*60)) | |
78 | |
79 c["change_source"].append (HgPoller (project = "stable octave", | |
80 branch = "stable", | |
81 repourl = stable_octave_hg_repo, | |
82 workdir = "stable-octave-hg-repo", | |
83 pollinterval = 5*60)) | |
84 | |
85 c["change_source"].append (HgPoller (project = "mxe-octave", | |
86 repourl = mxe_octave_hg_repo, | |
87 workdir = "mxe-octave-hg-repo", | |
88 pollinterval = 15*60)) | |
89 | |
90 ## FILTERS | |
91 | |
92 from buildbot.changes import filter | |
93 | |
94 octave_default_filter = filter.ChangeFilter (project = "octave", branch = "default") | |
95 | |
96 octave_stable_filter = filter.ChangeFilter (project = "stable octave", branch = "stable") | |
97 | |
98 mxe_octave_default_filter = filter.ChangeFilter (project = "mxe-octave", branch = "default") | |
99 | |
100 ## SCHEDULERS | |
101 | |
102 ## Configure the Schedulers, which decide how to react to incoming | |
103 ## changes. | |
104 | |
105 from buildbot.schedulers.basic import SingleBranchScheduler | |
106 from buildbot.schedulers.forcesched import ForceScheduler | |
107 from buildbot.schedulers import timed | |
108 | |
109 all_default_octave_builders = []; | |
110 #all_default_octave_builders.append ("gcc-4.9-debian") | |
111 #all_default_octave_builders.append ("gcc-5-debian") | |
112 all_default_octave_builders.append ("gcc-6-debian") # mtmx | |
9 | 113 all_default_octave_builders.append ("gcc-7-debian") # jwe 2 |
114 all_default_octave_builders.append ("gcc-7-lto-debian") # jwe 3 | |
0 | 115 all_default_octave_builders.append ("gcc-fedora") # das |
116 all_default_octave_builders.append ("gcc-lto-fedora") # das | |
9 | 117 all_default_octave_builders.append ("no-extras-debian") # jwe 2 |
0 | 118 all_default_octave_builders.append ("clang-3.9-debian") # mtmx |
9 | 119 all_default_octave_builders.append ("clang-4.0-debian") # jwe 1 |
120 all_default_octave_builders.append ("clang-5.0-debian") # jwe 0 | |
0 | 121 all_default_octave_builders.append ("clang-fedora") # das |
122 all_default_octave_builders.append ("clang-osx") # simone | |
123 | |
124 all_stable_octave_builders = []; | |
9 | 125 all_stable_octave_builders.append ("stable-gcc-7-debian") # jwe 2 |
126 all_stable_octave_builders.append ("stable-gcc-7-lto-debian") # jwe 3 | |
0 | 127 all_stable_octave_builders.append ("stable-gcc-fedora") # das |
9 | 128 all_stable_octave_builders.append ("stable-no-extras-debian") # jwe 2 |
129 all_stable_octave_builders.append ("stable-clang-4.0-debian") # jwe 1 | |
130 all_stable_octave_builders.append ("stable-clang-5.0-debian") # jwe 0 | |
13
9f694d100a7b
new stable-clang-fedora builder
John W. Eaton <jwe@octave.org>
parents:
12
diff
changeset
|
131 all_stable_octave_builders.append ("stable-clang-fedora") # das |
0 | 132 all_stable_octave_builders.append ("stable-clang-osx") # simone |
133 | |
134 all_mxe_octave_builders = []; | |
9 | 135 all_mxe_octave_builders.append ("w32-on-debian") # jwe 0 |
136 all_mxe_octave_builders.append ("w64-32-on-debian") # jwe 1 | |
137 all_mxe_octave_builders.append ("w64-64-on-debian") # jwe 3 | |
138 all_mxe_octave_builders.append ("w32-release-on-debian") # jwe 0 | |
139 all_mxe_octave_builders.append ("w64-32-release-on-debian") # jwe 1 | |
140 all_mxe_octave_builders.append ("w64-64-release-on-debian") # jwe 3 | |
141 all_mxe_octave_builders.append ("w32-stable-on-debian") # jwe 0 | |
142 all_mxe_octave_builders.append ("w64-32-stable-on-debian") # jwe 1 | |
143 all_mxe_octave_builders.append ("w64-64-stable-on-debian") # jwe 3 | |
144 all_mxe_octave_builders.append ("mxe-native-on-debian") # jwe 1 | |
145 all_mxe_octave_builders.append ("mxe-native-all-on-debian") # jwe 3 | |
0 | 146 |
147 c["schedulers"] = [] | |
148 | |
149 c["schedulers"].append (SingleBranchScheduler (name = "default octave", | |
150 change_filter = octave_default_filter, | |
151 treeStableTimer = 5*60, | |
152 builderNames = all_default_octave_builders)) | |
153 | |
154 c["schedulers"].append (ForceScheduler (name = "force_default_octave", builderNames = all_default_octave_builders)) | |
155 | |
156 c["schedulers"].append (SingleBranchScheduler (name = "stable octave", | |
157 change_filter = octave_stable_filter, | |
158 treeStableTimer = 5*60, | |
159 builderNames = all_stable_octave_builders)) | |
160 | |
161 c["schedulers"].append (ForceScheduler (name = "force_stable_octave", builderNames = all_stable_octave_builders)) | |
162 | |
163 ## Here, branch is the mxe-octave branch. | |
164 c["schedulers"].append (timed.Nightly (name = "periodic mxe-octave-w32", | |
165 branch = "default", | |
166 change_filter = mxe_octave_default_filter, | |
167 builderNames = ["w32-on-debian"], | |
168 hour = 0)) | |
169 | |
170 ## Here, branch is the mxe-octave branch. | |
171 c["schedulers"].append (timed.Nightly (name = "periodic mxe-octave-w64-32", | |
172 branch = "default", | |
173 change_filter = mxe_octave_default_filter, | |
174 builderNames = ["w64-32-on-debian"], | |
3
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
175 hour = 0)) |
0 | 176 |
177 ## Here, branch is the mxe-octave branch. | |
178 c["schedulers"].append (timed.Nightly (name = "periodic mxe-octave-w64-64", | |
179 branch = "default", | |
180 change_filter = mxe_octave_default_filter, | |
181 builderNames = ["w64-64-on-debian"], | |
3
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
182 hour = 0)) |
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
183 |
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
184 ## Here, branch is the mxe-octave branch. |
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
185 c["schedulers"].append (timed.Nightly (name = "periodic mxe-octave-w32-release", |
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
186 branch = "default", |
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
187 change_filter = mxe_octave_default_filter, |
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
188 builderNames = ["w32-release-on-debian"], |
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
189 hour = 8)) |
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
190 |
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
191 ## Here, branch is the mxe-octave branch. |
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
192 c["schedulers"].append (timed.Nightly (name = "periodic mxe-octave-w64-32-release", |
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
193 branch = "default", |
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
194 change_filter = mxe_octave_default_filter, |
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
195 builderNames = ["w64-32-release-on-debian"], |
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
196 hour = 6)) |
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
197 |
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
198 ## Here, branch is the mxe-octave branch. |
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
199 c["schedulers"].append (timed.Nightly (name = "periodic mxe-octave-w64-64-release", |
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
200 branch = "default", |
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
201 change_filter = mxe_octave_default_filter, |
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
202 builderNames = ["w64-64-release-on-debian"], |
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
203 hour = 6)) |
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
204 |
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
205 ## Here, branch is the mxe-octave branch. |
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
206 c["schedulers"].append (timed.Nightly (name = "periodic mxe-octave-w32-stable", |
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
207 branch = "default", |
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
208 change_filter = mxe_octave_default_filter, |
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
209 builderNames = ["w32-stable-on-debian"], |
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
210 hour = 16)) |
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
211 |
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
212 ## Here, branch is the mxe-octave branch. |
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
213 c["schedulers"].append (timed.Nightly (name = "periodic mxe-octave-w64-32-stable", |
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
214 branch = "default", |
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
215 change_filter = mxe_octave_default_filter, |
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
216 builderNames = ["w64-32-stable-on-debian"], |
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
217 hour = 12)) |
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
218 |
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
219 ## Here, branch is the mxe-octave branch. |
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
220 c["schedulers"].append (timed.Nightly (name = "periodic mxe-octave-w64-64-stable", |
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
221 branch = "default", |
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
222 change_filter = mxe_octave_default_filter, |
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
223 builderNames = ["w64-64-stable-on-debian"], |
0 | 224 hour = 12)) |
225 | |
226 ## Here, branch is the mxe-octave branch. | |
227 c["schedulers"].append (timed.Nightly (name = "periodic mxe-octave-native", | |
228 branch = "default", | |
229 change_filter = mxe_octave_default_filter, | |
230 builderNames = ["mxe-native-on-debian"], | |
231 hour = 18)) | |
232 | |
233 ## Here, branch is the mxe-octave branch. | |
234 c["schedulers"].append (timed.Nightly (name = "periodic mxe-octave-native-all", | |
235 branch = "default", | |
236 change_filter = mxe_octave_default_filter, | |
237 builderNames = ["mxe-native-all-on-debian"], | |
3
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
238 hour = 18)) |
0 | 239 |
240 c["schedulers"].append (ForceScheduler (name = "force_mxe_octave", builderNames = all_mxe_octave_builders)) | |
241 | |
242 ## BUILDERS | |
243 | |
244 ## The 'builders' list defines the Builders, which tell Buildbot how | |
245 ## to perform a build: what steps, and which workers can execute them. | |
246 ## Note that any particular build will only take place on one worker. | |
247 | |
248 from buildbot.process.factory import BuildFactory | |
249 from buildbot.steps.source.mercurial import Mercurial | |
250 from buildbot.steps.shell import ShellCommand | |
251 from buildbot.steps.shell import Configure | |
252 from buildbot.steps.shell import Compile | |
253 from buildbot.steps.shell import Test | |
254 | |
255 ## Steps we may use in more than one build factory. | |
256 | |
257 def build_cmd_list (cmd, nice = 0, opts = []): | |
258 cmd_list = [] | |
259 | |
260 if nice != 0: | |
261 cmd_list.extend (["nice", "-n", str (nice)]) | |
262 | |
263 if isinstance (cmd, list): | |
264 cmd_list.extend (cmd) | |
265 else: | |
266 cmd_list.append (cmd) | |
267 | |
268 if isinstance (opts, list): | |
269 cmd_list.extend (opts) | |
270 else: | |
271 cmd_list.append (opts) | |
272 | |
273 return cmd_list | |
274 | |
275 | |
276 build_env = { "PATH" : "${HOME}/bin:${PATH}" }; | |
277 | |
278 def mk_octave_hg_update_step (repo, branch): | |
279 return Mercurial (repourl = repo, | |
280 defaultBranch = branch, branchType = "inrepo", | |
281 workdir = "src", mode = "full", method = "fresh", | |
282 haltOnFailure = True) | |
283 | |
284 def mk_octave_bootstrap_step (nice = 0): | |
285 boot_cmd = build_cmd_list ("./bootstrap", nice = nice) | |
286 return ShellCommand (command = boot_cmd, workdir = "src", env = build_env, | |
287 description = "bootstrap") | |
288 | |
289 sh_rm_build_dir = ShellCommand (command = ["rm", "-rf", "build"], workdir = ".", | |
290 env = build_env, description = "clean build dir") | |
291 | |
292 sh_mk_build_dir = ShellCommand (command = ["mkdir", "build"], | |
293 description = "create build dir") | |
294 | |
295 def mk_octave_configure_step (nice = 0, opts = []): | |
296 conf_cmd = build_cmd_list ("../src/configure", nice = nice, opts = opts) | |
297 return Configure (command = conf_cmd, workdir = "build", env = build_env) | |
298 | |
299 | |
300 def mk_octave_compile_step (nice = 0, opts = []): | |
301 make_cmd = build_cmd_list (["make", "V=1"], nice = nice, opts = opts) | |
302 return Compile (command = make_cmd, workdir = "build", env = build_env, | |
303 warningPattern = ":[0-9][0-9]*:[0-9][0-9]*:warning: ") | |
304 | |
305 import re | |
1
97e7b7963dc9
make test log filtering work again
John W. Eaton <jwe@octave.org>
parents:
0
diff
changeset
|
306 from buildbot.process import logobserver |
0 | 307 from buildbot.process.results import SUCCESS |
308 from buildbot.process.results import FAILURE | |
309 from buildbot.process.results import WARNINGS | |
310 | |
1
97e7b7963dc9
make test log filtering work again
John W. Eaton <jwe@octave.org>
parents:
0
diff
changeset
|
311 class octave_test_observer (logobserver.LogLineObserver): |
97e7b7963dc9
make test log filtering work again
John W. Eaton <jwe@octave.org>
parents:
0
diff
changeset
|
312 |
97e7b7963dc9
make test log filtering work again
John W. Eaton <jwe@octave.org>
parents:
0
diff
changeset
|
313 def __init__ (self, warningPattern): |
97e7b7963dc9
make test log filtering work again
John W. Eaton <jwe@octave.org>
parents:
0
diff
changeset
|
314 logobserver.LogLineObserver.__init__ (self) |
97e7b7963dc9
make test log filtering work again
John W. Eaton <jwe@octave.org>
parents:
0
diff
changeset
|
315 if warningPattern: |
97e7b7963dc9
make test log filtering work again
John W. Eaton <jwe@octave.org>
parents:
0
diff
changeset
|
316 self.warningPattern = re.compile (warningPattern) |
97e7b7963dc9
make test log filtering work again
John W. Eaton <jwe@octave.org>
parents:
0
diff
changeset
|
317 else: |
97e7b7963dc9
make test log filtering work again
John W. Eaton <jwe@octave.org>
parents:
0
diff
changeset
|
318 self.warningPattern = None |
97e7b7963dc9
make test log filtering work again
John W. Eaton <jwe@octave.org>
parents:
0
diff
changeset
|
319 self.rc = SUCCESS |
97e7b7963dc9
make test log filtering work again
John W. Eaton <jwe@octave.org>
parents:
0
diff
changeset
|
320 self.total = 0 |
2 | 321 self.passed = 0 |
1
97e7b7963dc9
make test log filtering work again
John W. Eaton <jwe@octave.org>
parents:
0
diff
changeset
|
322 self.failed = 0 |
97e7b7963dc9
make test log filtering work again
John W. Eaton <jwe@octave.org>
parents:
0
diff
changeset
|
323 self.warnings = 0 |
12
318c34f152fb
attempt to also notice segfaults as errors
Markus Mützel <markus.muetzel@gmx.de>
parents:
11
diff
changeset
|
324 self.errors = 0 |
2 | 325 self.summary_found = False |
1
97e7b7963dc9
make test log filtering work again
John W. Eaton <jwe@octave.org>
parents:
0
diff
changeset
|
326 self.complete = False |
97e7b7963dc9
make test log filtering work again
John W. Eaton <jwe@octave.org>
parents:
0
diff
changeset
|
327 |
2 | 328 summaryRe = re.compile (r"^Summary: *$") |
329 testsRe = re.compile (r"^ *(PASS|FAIL|REGRESSION|XFAIL|SKIP)[^\d]*(\d+)") | |
1
97e7b7963dc9
make test log filtering work again
John W. Eaton <jwe@octave.org>
parents:
0
diff
changeset
|
330 |
97e7b7963dc9
make test log filtering work again
John W. Eaton <jwe@octave.org>
parents:
0
diff
changeset
|
331 def outLineReceived (self, line): |
97e7b7963dc9
make test log filtering work again
John W. Eaton <jwe@octave.org>
parents:
0
diff
changeset
|
332 if self.warningPattern.match (line): |
97e7b7963dc9
make test log filtering work again
John W. Eaton <jwe@octave.org>
parents:
0
diff
changeset
|
333 self.warnings += 1 |
2 | 334 |
335 if not self.summary_found: | |
336 mo = self.summaryRe.search (line) | |
337 if mo: | |
338 self.summary_found = True | |
339 return | |
340 | |
1
97e7b7963dc9
make test log filtering work again
John W. Eaton <jwe@octave.org>
parents:
0
diff
changeset
|
341 mo = self.testsRe.search (line) |
97e7b7963dc9
make test log filtering work again
John W. Eaton <jwe@octave.org>
parents:
0
diff
changeset
|
342 if mo: |
2 | 343 typ = mo.group(1) |
344 num = int (mo.group(2)) | |
1
97e7b7963dc9
make test log filtering work again
John W. Eaton <jwe@octave.org>
parents:
0
diff
changeset
|
345 self.total += num |
2 | 346 if typ == "PASS": |
347 self.passed += num | |
348 if typ == "FAIL" or typ == "REGRESSION": | |
349 if num > 0: | |
1
97e7b7963dc9
make test log filtering work again
John W. Eaton <jwe@octave.org>
parents:
0
diff
changeset
|
350 self.rc = FAILURE |
2 | 351 self.failed += num |
1
97e7b7963dc9
make test log filtering work again
John W. Eaton <jwe@octave.org>
parents:
0
diff
changeset
|
352 |
13
9f694d100a7b
new stable-clang-fedora builder
John W. Eaton <jwe@octave.org>
parents:
12
diff
changeset
|
353 def errLineReceived (self, line): |
12
318c34f152fb
attempt to also notice segfaults as errors
Markus Mützel <markus.muetzel@gmx.de>
parents:
11
diff
changeset
|
354 self.total += 1 |
318c34f152fb
attempt to also notice segfaults as errors
Markus Mützel <markus.muetzel@gmx.de>
parents:
11
diff
changeset
|
355 self.errors += 1 |
318c34f152fb
attempt to also notice segfaults as errors
Markus Mützel <markus.muetzel@gmx.de>
parents:
11
diff
changeset
|
356 self.rc = FAILURE |
1
97e7b7963dc9
make test log filtering work again
John W. Eaton <jwe@octave.org>
parents:
0
diff
changeset
|
357 |
0 | 358 class octave_test (Test): |
359 | |
1
97e7b7963dc9
make test log filtering work again
John W. Eaton <jwe@octave.org>
parents:
0
diff
changeset
|
360 def __init__ (self, *args, **kwargs): |
97e7b7963dc9
make test log filtering work again
John W. Eaton <jwe@octave.org>
parents:
0
diff
changeset
|
361 Test.__init__ (self, *args, **kwargs) |
97e7b7963dc9
make test log filtering work again
John W. Eaton <jwe@octave.org>
parents:
0
diff
changeset
|
362 self.observer = octave_test_observer (warningPattern = self.warningPattern) |
97e7b7963dc9
make test log filtering work again
John W. Eaton <jwe@octave.org>
parents:
0
diff
changeset
|
363 self.addLogObserver ('stdio', self.observer) |
97e7b7963dc9
make test log filtering work again
John W. Eaton <jwe@octave.org>
parents:
0
diff
changeset
|
364 |
0 | 365 def evaluateCommand (self, cmd): |
1
97e7b7963dc9
make test log filtering work again
John W. Eaton <jwe@octave.org>
parents:
0
diff
changeset
|
366 if self.observer.total: |
97e7b7963dc9
make test log filtering work again
John W. Eaton <jwe@octave.org>
parents:
0
diff
changeset
|
367 passed = self.observer.total - self.observer.failed |
0 | 368 |
1
97e7b7963dc9
make test log filtering work again
John W. Eaton <jwe@octave.org>
parents:
0
diff
changeset
|
369 self.setTestResults (total = self.observer.total, |
12
318c34f152fb
attempt to also notice segfaults as errors
Markus Mützel <markus.muetzel@gmx.de>
parents:
11
diff
changeset
|
370 failed = self.observer.failed + self.observer.errors, |
2 | 371 passed = self.observer.passed, |
1
97e7b7963dc9
make test log filtering work again
John W. Eaton <jwe@octave.org>
parents:
0
diff
changeset
|
372 warnings = self.observer.warnings) |
0 | 373 |
1
97e7b7963dc9
make test log filtering work again
John W. Eaton <jwe@octave.org>
parents:
0
diff
changeset
|
374 rc = self.observer.rc |
97e7b7963dc9
make test log filtering work again
John W. Eaton <jwe@octave.org>
parents:
0
diff
changeset
|
375 if rc == SUCCESS and self.observer.warnings: |
97e7b7963dc9
make test log filtering work again
John W. Eaton <jwe@octave.org>
parents:
0
diff
changeset
|
376 rc = WARNINGS |
0 | 377 return rc |
378 | |
1
97e7b7963dc9
make test log filtering work again
John W. Eaton <jwe@octave.org>
parents:
0
diff
changeset
|
379 |
0 | 380 def mk_octave_test_step (nice = 0, xvfb = True): |
381 if xvfb: | |
382 cmd = ["xvfb-run", "-a", "-s", "-screen 0 640x480x24"] | |
383 else: | |
384 cmd = [] | |
385 cmd.extend (["make", "V=1", "check"]) | |
386 test_cmd = build_cmd_list (cmd, nice = nice) | |
387 return octave_test (command = test_cmd, workdir = "build", env = build_env) | |
388 | |
1
97e7b7963dc9
make test log filtering work again
John W. Eaton <jwe@octave.org>
parents:
0
diff
changeset
|
389 |
0 | 390 def mk_octave_factory (nice, configure_opts, compile_opts, branch, xvfb = True): |
391 factory = BuildFactory () | |
392 | |
393 factory.addStep (mk_octave_hg_update_step (octave_hg_repo, branch)) | |
394 factory.addStep (mk_octave_bootstrap_step (nice = nice)) | |
395 factory.addStep (sh_rm_build_dir) | |
396 factory.addStep (sh_mk_build_dir) | |
397 factory.addStep (mk_octave_configure_step (nice = nice, opts = configure_opts)) | |
398 factory.addStep (mk_octave_compile_step (nice = nice, opts = compile_opts)) | |
399 factory.addStep (mk_octave_test_step (nice = nice, xvfb = xvfb)) | |
400 | |
401 return factory | |
402 | |
1
97e7b7963dc9
make test log filtering work again
John W. Eaton <jwe@octave.org>
parents:
0
diff
changeset
|
403 |
0 | 404 def mk_gcc_factory (nice, compile_opts, branch): |
405 return mk_octave_factory (nice, [], compile_opts, branch) | |
406 | |
407 | |
408 def mk_gcc_4_9_factory (nice, compile_opts, branch): | |
409 return mk_octave_factory (nice, | |
410 ["CC=gcc-4.9", "CXX=g++-4.9", "F77=gfortran-4.9", "--without-magick"], | |
411 compile_opts, branch) | |
412 | |
413 | |
414 ## Default build. | |
415 def mk_gcc_5_factory (nice, compile_opts, branch): | |
416 return mk_octave_factory (nice, | |
417 ["CC=gcc-5", "CXX=g++-5", "F77=gfortran-5"], | |
418 compile_opts, branch) | |
419 | |
420 | |
421 def mk_gcc_6_factory (nice, compile_opts, branch): | |
422 return mk_octave_factory (nice, | |
423 ["CC=gcc-6", "CXX=g++-6", "F77=gfortran-6"], | |
424 compile_opts, branch) | |
425 | |
426 | |
427 def mk_gcc_7_factory (nice, compile_opts, branch): | |
428 return mk_octave_factory (nice, | |
429 ["CC=gcc-7", "CXX=g++-7", "F77=gfortran-7"], | |
430 compile_opts, branch) | |
431 | |
432 | |
433 def mk_gcc_7_lto_factory (nice, compile_opts, branch): | |
434 return mk_octave_factory (nice, | |
435 ["CC=gcc-7", "CXX=g++-7", "F77=gfortran-7", | |
436 "CFLAGS=-O2 -flto=4 -ffat-lto-objects", | |
437 "CXXFLAGS=-O2 -flto=4 -ffat-lto-objects", | |
438 "FFLAGS=-O2 -flto=4 -ffat-lto-objects", | |
439 "LDFLAGS=-flto=4", | |
440 "NM=gcc-nm-7", "AR=gcc-ar-7", "RANLIB=gcc-ranlib-7"], | |
441 compile_opts, branch) | |
442 | |
443 | |
444 def mk_gcc_lto_factory (nice, compile_opts, branch): | |
445 return mk_octave_factory (nice, | |
446 ["CFLAGS=-O2 -flto=4 -ffat-lto-objects", | |
447 "CXXFLAGS=-O2 -flto=4 -ffat-lto-objects", | |
448 "FFLAGS=-O2 -flto=4 -ffat-lto-objects", | |
449 "LDFLAGS=-flto=4", | |
450 "NM=gcc-nm", "AR=gcc-ar", "RANLIB=gcc-ranlib"], | |
451 compile_opts, branch) | |
452 | |
453 | |
454 no_extras = ["--disable-docs", | |
455 "--disable-fftw-threads", | |
456 "--disable-java", | |
457 "--disable-jit", | |
458 "--disable-openmp", | |
459 "--disable-readline", | |
460 "--without-osmesa", | |
461 "--without-amd", | |
462 "--without-arpack", | |
463 "--without-bz2", | |
464 "--without-camd", | |
465 "--without-ccolamd", | |
466 "--without-cholmod", | |
467 "--without-colamd", | |
468 "--without-curl", | |
469 "--without-cxsparse", | |
470 "--without-fftw3", | |
471 "--without-fftw3f", | |
472 "--without-fltk", | |
17
cfa6aaf2a7eb
use --without-fontconfig and --without-freetype for no-extras builds
John W. Eaton <jwe@octave.org>
parents:
16
diff
changeset
|
473 "--without-fontconfig", |
0 | 474 "--without-framework-opengl", |
17
cfa6aaf2a7eb
use --without-fontconfig and --without-freetype for no-extras builds
John W. Eaton <jwe@octave.org>
parents:
16
diff
changeset
|
475 "--without-freetype", |
0 | 476 "--without-glpk", |
477 "--without-hdf5", | |
478 "--without-klu", | |
479 "--without-sundials-ida", | |
480 "--without-sundials_nvecserial", | |
481 "--without-magick", | |
482 "--without-opengl", | |
483 "--without-openssl", | |
484 "--without-portaudio", | |
485 "--without-qhull", | |
486 "--without-qrupdate", | |
487 "--without-qscintilla", | |
488 "--without-qt", | |
489 "--without-sndfile", | |
490 "--without-sundials_ida", | |
491 "--without-sundials_nvecserial", | |
492 "--without-umfpack", | |
493 "--without-x", | |
494 "--without-z"] | |
495 | |
496 def mk_no_extras_factory (nice, compile_opts, branch): | |
497 return mk_octave_factory (nice, no_extras, compile_opts, branch) | |
498 | |
499 | |
500 def mk_clang_3_8_factory (nice, compile_opts, branch): | |
501 return mk_octave_factory (nice, | |
502 ["CC=clang-3.8", "CXX=clang++-3.8"], | |
503 compile_opts, branch) | |
504 | |
505 | |
506 def mk_clang_3_9_factory (nice, compile_opts, branch): | |
507 return mk_octave_factory (nice, | |
508 ["CC=clang-3.9", "CXX=clang++-3.9"], | |
509 compile_opts, branch) | |
510 | |
511 def mk_clang_4_0_factory (nice, compile_opts, branch): | |
512 return mk_octave_factory (nice, | |
513 ["CC=clang-4.0", "CXX=clang++-4.0"], | |
514 compile_opts, branch) | |
515 | |
516 def mk_clang_5_0_factory (nice, compile_opts, branch): | |
517 return mk_octave_factory (nice, | |
518 ["CC=clang-5.0", "CXX=clang++-5.0"], | |
519 compile_opts, branch) | |
520 | |
521 def mk_clang_factory (nice, compile_opts, branch): | |
522 return mk_octave_factory (nice, | |
523 ["CC=clang", "CXX=clang++"], | |
524 compile_opts, branch) | |
525 | |
526 def mk_clang_osx_factory (nice, compile_opts, branch): | |
527 ## The linker does search /usr/local/lib, but it does so after | |
528 ## searching /usr/lib. That selects a readline library that is not | |
529 ## fully compatible with GNU readline. | |
530 return mk_octave_factory (nice, | |
531 ["CC=clang", | |
532 "CXX=clang++", | |
533 "CPPFLAGS=-I/opt/X11/include -I/usr/local/opt/gettext/include -I/usr/local/opt/icu4c/include -I/usr/local/opt/openssl/include -I/usr/local/opt/readline/include -I/usr/local/opt/sqlite/include", | |
534 "LDFLAGS=-L/usr/local/lib -L/opt/X11/lib -L/usr/local/opt/qt/lib -L/usr/local/opt/readline/lib -L/usr/local/opt/texinfo/lib -L/usr/local/opt/bison/lib -L/usr/local/opt/gettext/lib -L/usr/local/opt/icu4c/lib -L/usr/local/opt/libffi/lib -L/usr/local/opt/openblas/lib -L/usr/local/opt/openssl/lib -L/usr/local/opt/sqlite/lib", | |
535 "PKG_CONFIG_PATH=/usr/local/opt/icu4c/lib/pkgconfig:/usr/local/opt/qt/lib/pkgconfig", | |
536 "--enable-link-all-dependencies", | |
537 "--with-x=no", | |
538 "--without-osmesa", | |
539 "--with-blas=openblas"], | |
540 compile_opts, branch, xvfb = False) | |
541 | |
542 from buildbot.config import BuilderConfig | |
543 | |
544 c["builders"] = [] | |
545 | |
546 #c["builders"].append (BuilderConfig (name = "gcc-4.9-debian", | |
9 | 547 # workernames = ["jwe-debian-x86_64-1"], |
0 | 548 # factory = mk_gcc_4_9_factory (19, "-j8", "default"))) |
549 | |
550 #c["builders"].append (BuilderConfig (name = "gcc-5-debian", | |
9 | 551 # workernames = ["jwe-debian-x86_64-1"], |
0 | 552 # factory = mk_gcc_5_factory (19, "-j8", "default"))) |
553 | |
554 c["builders"].append (BuilderConfig (name = "gcc-6-debian", | |
555 workernames = ["mtmx-debian-x86_64"], | |
556 factory = mk_gcc_6_factory (10, "-j2", "default"))) | |
557 | |
558 c["builders"].append (BuilderConfig (name = "gcc-7-debian", | |
9 | 559 workernames = ["jwe-debian-x86_64-2"], |
0 | 560 factory = mk_gcc_7_factory (19, "-j8", "default"))) |
561 | |
562 c["builders"].append (BuilderConfig (name = "stable-gcc-7-debian", | |
9 | 563 workernames = ["jwe-debian-x86_64-2"], |
0 | 564 factory = mk_gcc_7_factory (19, "-j8", "stable"))) |
565 | |
566 c["builders"].append (BuilderConfig (name = "gcc-7-lto-debian", | |
9 | 567 workernames = ["jwe-debian-x86_64-3"], |
0 | 568 factory = mk_gcc_7_lto_factory (19, "-j8", "default"))) |
569 | |
570 c["builders"].append (BuilderConfig (name = "stable-gcc-7-lto-debian", | |
9 | 571 workernames = ["jwe-debian-x86_64-3"], |
0 | 572 factory = mk_gcc_7_lto_factory (19, "-j8", "stable"))) |
573 | |
574 c["builders"].append (BuilderConfig (name = "gcc-fedora", | |
575 workernames = ["das_fc25-x86_64"], | |
11 | 576 factory = mk_gcc_factory (0, "-j4", "default"))) |
0 | 577 |
578 c["builders"].append (BuilderConfig (name = "stable-gcc-fedora", | |
579 workernames = ["das_fc25-x86_64"], | |
11 | 580 factory = mk_gcc_factory (0, "-j4", "stable"))) |
0 | 581 |
582 c["builders"].append (BuilderConfig (name = "gcc-lto-fedora", | |
583 workernames = ["das_fc25-x86_64"], | |
11 | 584 factory = mk_gcc_lto_factory (10, "-j4", "default"))) |
0 | 585 |
586 c["builders"].append (BuilderConfig (name = "no-extras-debian", | |
9 | 587 workernames = ["jwe-debian-x86_64-2"], |
0 | 588 factory = mk_no_extras_factory (19, "-j8", "default"))) |
589 | |
590 c["builders"].append (BuilderConfig (name = "stable-no-extras-debian", | |
9 | 591 workernames = ["jwe-debian-x86_64-2"], |
0 | 592 factory = mk_no_extras_factory (19, "-j8", "stable"))) |
593 | |
594 ##c["builders"].append (BuilderConfig (name = "clang-3.8-debian", | |
9 | 595 ## workernames = ["jwe-debian-x86_64-3"], |
0 | 596 ## factory = mk_clang_3_8_factory (19, "-j8", "default"))) |
597 | |
598 c["builders"].append (BuilderConfig (name = "clang-3.9-debian", | |
599 workernames = ["mtmx-debian-x86_64"], | |
600 factory = mk_clang_3_9_factory (19, "-j2", "default"))) | |
601 | |
602 c["builders"].append (BuilderConfig (name = "clang-4.0-debian", | |
9 | 603 workernames = ["jwe-debian-x86_64-1"], |
0 | 604 factory = mk_clang_4_0_factory (19, "-j8", "default"))) |
605 | |
606 c["builders"].append (BuilderConfig (name = "stable-clang-4.0-debian", | |
9 | 607 workernames = ["jwe-debian-x86_64-1"], |
0 | 608 factory = mk_clang_4_0_factory (19, "-j8", "stable"))) |
609 | |
610 c["builders"].append (BuilderConfig (name = "clang-5.0-debian", | |
9 | 611 workernames = ["jwe-debian-x86_64-0"], |
0 | 612 factory = mk_clang_5_0_factory (19, "-j8", "default"))) |
613 | |
614 c["builders"].append (BuilderConfig (name = "stable-clang-5.0-debian", | |
9 | 615 workernames = ["jwe-debian-x86_64-0"], |
0 | 616 factory = mk_clang_5_0_factory (19, "-j8", "stable"))) |
617 | |
618 c["builders"].append (BuilderConfig (name = "clang-fedora", | |
619 workernames = ["das_fc25-x86_64"], | |
11 | 620 factory = mk_clang_factory (19, "-j4", "default"))) |
0 | 621 |
622 | |
13
9f694d100a7b
new stable-clang-fedora builder
John W. Eaton <jwe@octave.org>
parents:
12
diff
changeset
|
623 c["builders"].append (BuilderConfig (name = "stable-clang-fedora", |
9f694d100a7b
new stable-clang-fedora builder
John W. Eaton <jwe@octave.org>
parents:
12
diff
changeset
|
624 workernames = ["das_fc25-x86_64"], |
9f694d100a7b
new stable-clang-fedora builder
John W. Eaton <jwe@octave.org>
parents:
12
diff
changeset
|
625 factory = mk_clang_factory (19, "-j4", "stable"))) |
9f694d100a7b
new stable-clang-fedora builder
John W. Eaton <jwe@octave.org>
parents:
12
diff
changeset
|
626 |
9f694d100a7b
new stable-clang-fedora builder
John W. Eaton <jwe@octave.org>
parents:
12
diff
changeset
|
627 |
0 | 628 c["builders"].append (BuilderConfig (name = "clang-osx", |
629 workernames = ["epfl-elcapitan-x86_64"], | |
630 factory = mk_clang_osx_factory (0, "-j4", "default"))) | |
631 | |
632 c["builders"].append (BuilderConfig (name = "stable-clang-osx", | |
633 workernames = ["epfl-elcapitan-x86_64"], | |
634 factory = mk_clang_osx_factory (0, "-j4", "stable"))) | |
635 | |
636 | |
637 def mk_mxe_octave_hg_update_step (repo): | |
638 return Mercurial (repourl = repo, | |
639 defaultBranch = "default", branchType = "inrepo", | |
640 workdir = "src", mode = "full", method = "fresh", | |
641 haltOnFailure = True) | |
642 | |
643 | |
644 def mk_mxe_octave_bootstrap_step (nice = 0): | |
10
c1bb39356540
master.cfg: Run bootstrap script for MXE Octave builders (bug #55802).
Markus Mützel <markus.muetzel@gmx.de>
parents:
9
diff
changeset
|
645 boot_cmd = build_cmd_list ("./bootstrap", nice = nice) |
0 | 646 return ShellCommand (command = boot_cmd, workdir = "src", env = build_env, |
647 description = "bootstrap") | |
648 | |
649 | |
650 def mk_mxe_octave_configure_step (nice = 0, branch = "default", opts = []): | |
651 conf_cmd = build_cmd_list (["./configure", | |
652 "--with-pkg-dir=../../mxe-pkg-src", | |
653 "--with-ccache", "--enable-octave=" + branch, | |
654 "--enable-binary-packages"], | |
655 nice = nice, opts = opts) | |
656 return Configure (command = conf_cmd, workdir = "src", env = build_env) | |
657 | |
658 | |
659 def mk_mxe_octave_clean_step (nice = 0): | |
660 boot_cmd = build_cmd_list (["make", "clean"], nice = nice) | |
661 return ShellCommand (command = boot_cmd, workdir = "src", env = build_env, | |
662 description = "clean") | |
663 | |
664 | |
665 ## Timeout is large for these steps because mxe-octave currently only | |
666 ## prints a status update for each package, not detailed output from | |
667 ## make. The way the dependencies currently work, making | |
668 ## hg-octave-dist will also cause all the build tools to be updated, | |
669 ## and some of those make take significant time to build, especially | |
670 ## if the build is running on a heavily loaded system and this step | |
671 ## has a high nice value. | |
672 | |
673 def mk_mxe_octave_hg_tarball_step (nice = 0, jobs = 8, branch = "default"): | |
3
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
674 |
4
5d2e18ee2b92
mxe-octave: don't build tarball from hg for "release" branch
John W. Eaton <jwe@octave.org>
parents:
3
diff
changeset
|
675 make_cmd = build_cmd_list (["make", "JOBS=" + str (jobs), "hg-octave-dist", "hg-octave-branch=" + branch], |
0 | 676 nice = nice) |
677 return Compile (command = make_cmd, workdir = "src", env = build_env, | |
678 timeout = 14400) | |
679 | |
680 | |
681 def mk_mxe_octave_compile_step (nice = 0, jobs = 8, opts = []): | |
682 make_cmd = build_cmd_list (["make", "JOBS=" + str (jobs)], | |
683 nice = nice, opts = opts) | |
684 return Compile (command = make_cmd, workdir = "src", env = build_env, | |
685 timeout = 14400) | |
686 | |
687 | |
688 def mk_mxe_octave_factory (nice, jobs, branch, configure_opts, compile_opts): | |
689 factory = BuildFactory () | |
690 | |
691 factory.addStep (mk_mxe_octave_hg_update_step (mxe_octave_hg_repo)) | |
692 factory.addStep (mk_mxe_octave_bootstrap_step (nice = nice)) | |
693 ## Must run configure to ensure clean target will work, then must | |
694 ## run configure again to recreate makefile. | |
695 factory.addStep (mk_mxe_octave_configure_step (nice = nice, branch = branch, | |
696 opts = configure_opts)) | |
697 factory.addStep (mk_mxe_octave_clean_step (nice = nice)) | |
698 factory.addStep (mk_mxe_octave_configure_step (nice = nice, branch = branch, | |
699 opts = configure_opts)) | |
3
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
700 |
6
c8ce098ecc08
mxe-octave: update build rules
John W. Eaton <jwe@octave.org>
parents:
5
diff
changeset
|
701 factory.addStep (mk_mxe_octave_compile_step (nice = nice, jobs = jobs, |
c8ce098ecc08
mxe-octave: update build rules
John W. Eaton <jwe@octave.org>
parents:
5
diff
changeset
|
702 opts = "prerequisites")) |
c8ce098ecc08
mxe-octave: update build rules
John W. Eaton <jwe@octave.org>
parents:
5
diff
changeset
|
703 |
4
5d2e18ee2b92
mxe-octave: don't build tarball from hg for "release" branch
John W. Eaton <jwe@octave.org>
parents:
3
diff
changeset
|
704 if branch != "release": |
5d2e18ee2b92
mxe-octave: don't build tarball from hg for "release" branch
John W. Eaton <jwe@octave.org>
parents:
3
diff
changeset
|
705 ## Create a tarball file from an hg checkout, then build from that. |
5d2e18ee2b92
mxe-octave: don't build tarball from hg for "release" branch
John W. Eaton <jwe@octave.org>
parents:
3
diff
changeset
|
706 ## This also builds all dependencies for Octave, so it can take a |
5d2e18ee2b92
mxe-octave: don't build tarball from hg for "release" branch
John W. Eaton <jwe@octave.org>
parents:
3
diff
changeset
|
707 ## while. Using ccache should help us significantly since we are |
5d2e18ee2b92
mxe-octave: don't build tarball from hg for "release" branch
John W. Eaton <jwe@octave.org>
parents:
3
diff
changeset
|
708 ## typically rebuilding the same sets of packages repeatedly. |
5d2e18ee2b92
mxe-octave: don't build tarball from hg for "release" branch
John W. Eaton <jwe@octave.org>
parents:
3
diff
changeset
|
709 |
5d2e18ee2b92
mxe-octave: don't build tarball from hg for "release" branch
John W. Eaton <jwe@octave.org>
parents:
3
diff
changeset
|
710 factory.addStep (mk_mxe_octave_hg_tarball_step (nice = nice, jobs = jobs, |
5d2e18ee2b92
mxe-octave: don't build tarball from hg for "release" branch
John W. Eaton <jwe@octave.org>
parents:
3
diff
changeset
|
711 branch = branch)) |
5d2e18ee2b92
mxe-octave: don't build tarball from hg for "release" branch
John W. Eaton <jwe@octave.org>
parents:
3
diff
changeset
|
712 |
0 | 713 factory.addStep (mk_mxe_octave_compile_step (nice = nice, jobs = jobs, |
714 opts = compile_opts)) | |
4
5d2e18ee2b92
mxe-octave: don't build tarball from hg for "release" branch
John W. Eaton <jwe@octave.org>
parents:
3
diff
changeset
|
715 |
0 | 716 ## factory.addStep (mk_mxe_octave_test_step (nice = nice)) |
717 | |
718 return factory | |
719 | |
720 | |
721 def mk_w32_factory (nice, jobs, branch, compile_opts): | |
722 return mk_mxe_octave_factory (nice, jobs, branch, | |
723 ["--enable-qt5", | |
724 "--enable-devel-tools", | |
725 "--disable-windows-64", | |
3
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
726 "--disable-64", |
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
727 "--disable-fortran-int64", |
0 | 728 "--disable-system-opengl"], |
729 compile_opts) | |
730 | |
731 | |
732 def mk_w64_32_factory (nice, jobs, branch, compile_opts): | |
733 return mk_mxe_octave_factory (nice, jobs, branch, | |
3
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
734 ["--enable-qt5", |
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
735 "--enable-devel-tools", |
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
736 "--enable-windows-64", |
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
737 "--enable-64", |
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
738 "--disable-fortran-int64", |
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
739 "--disable-system-opengl"], |
0 | 740 compile_opts) |
741 | |
742 | |
743 def mk_w64_64_factory (nice, jobs, branch, compile_opts): | |
744 return mk_mxe_octave_factory (nice, jobs, branch, | |
745 ["--enable-qt5", | |
746 "--enable-devel-tools", | |
3
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
747 "--enable-windows-64", |
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
748 "--enable-64", |
0 | 749 "--enable-fortran-int64", |
3
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
750 "--disable-system-opengl"], |
0 | 751 compile_opts) |
752 | |
753 | |
754 def mk_native_factory (nice, jobs, branch, compile_opts): | |
755 return mk_mxe_octave_factory (nice, jobs, branch, | |
756 ["--enable-native-build", | |
757 "--enable-qt5", | |
758 "--enable-lib64-directory", | |
759 "--enable-pic-flag", | |
760 "--disable-devel-tools", | |
761 "--enable-system-x11-libs", | |
762 "--enable-system-fontconfig", | |
763 "--enable-system-gcc", | |
764 "gnu-linux"], | |
765 compile_opts) | |
766 | |
767 | |
768 def mk_native_all_factory (nice, jobs, branch, compile_opts): | |
769 return mk_mxe_octave_factory (nice, jobs, branch, | |
770 ["--enable-native-build", | |
771 "--enable-qt5", | |
772 "--enable-lib64-directory", | |
773 "--enable-pic-flag", | |
774 "--disable-devel-tools", | |
775 "--disable-system-x11-libs", | |
776 "--disable-system-fontconfig", | |
777 "--disable-system-gcc", | |
778 "--disable-system-opengl", | |
779 "gnu-linux"], | |
780 compile_opts) | |
781 | |
782 | |
783 c["builders"].append (BuilderConfig (name = "w32-on-debian", | |
9 | 784 workernames = ["jwe-debian-x86_64-0"], |
6
c8ce098ecc08
mxe-octave: update build rules
John W. Eaton <jwe@octave.org>
parents:
5
diff
changeset
|
785 factory = mk_w32_factory (19, 8, "default", |
c8ce098ecc08
mxe-octave: update build rules
John W. Eaton <jwe@octave.org>
parents:
5
diff
changeset
|
786 ["nsis-installer", "7z-dist"]))) |
0 | 787 |
788 c["builders"].append (BuilderConfig (name = "w64-32-on-debian", | |
9 | 789 workernames = ["jwe-debian-x86_64-1"], |
6
c8ce098ecc08
mxe-octave: update build rules
John W. Eaton <jwe@octave.org>
parents:
5
diff
changeset
|
790 factory = mk_w64_32_factory (19, 8, "default", |
c8ce098ecc08
mxe-octave: update build rules
John W. Eaton <jwe@octave.org>
parents:
5
diff
changeset
|
791 ["nsis-installer", "7z-dist"]))) |
0 | 792 |
793 c["builders"].append (BuilderConfig (name = "w64-64-on-debian", | |
9 | 794 workernames = ["jwe-debian-x86_64-3"], |
6
c8ce098ecc08
mxe-octave: update build rules
John W. Eaton <jwe@octave.org>
parents:
5
diff
changeset
|
795 factory = mk_w64_64_factory (19, 8, "default", |
c8ce098ecc08
mxe-octave: update build rules
John W. Eaton <jwe@octave.org>
parents:
5
diff
changeset
|
796 ["nsis-installer", "7z-dist"]))) |
3
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
797 |
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
798 c["builders"].append (BuilderConfig (name = "w32-release-on-debian", |
9 | 799 workernames = ["jwe-debian-x86_64-0"], |
6
c8ce098ecc08
mxe-octave: update build rules
John W. Eaton <jwe@octave.org>
parents:
5
diff
changeset
|
800 factory = mk_w32_factory (19, 8, "release", |
c8ce098ecc08
mxe-octave: update build rules
John W. Eaton <jwe@octave.org>
parents:
5
diff
changeset
|
801 ["nsis-installer", "7z-dist"]))) |
3
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
802 |
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
803 c["builders"].append (BuilderConfig (name = "w64-32-release-on-debian", |
9 | 804 workernames = ["jwe-debian-x86_64-1"], |
6
c8ce098ecc08
mxe-octave: update build rules
John W. Eaton <jwe@octave.org>
parents:
5
diff
changeset
|
805 factory = mk_w64_32_factory (19, 8, "release", |
c8ce098ecc08
mxe-octave: update build rules
John W. Eaton <jwe@octave.org>
parents:
5
diff
changeset
|
806 ["nsis-installer", "7z-dist"]))) |
3
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
807 |
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
808 c["builders"].append (BuilderConfig (name = "w64-64-release-on-debian", |
9 | 809 workernames = ["jwe-debian-x86_64-3"], |
6
c8ce098ecc08
mxe-octave: update build rules
John W. Eaton <jwe@octave.org>
parents:
5
diff
changeset
|
810 factory = mk_w64_64_factory (19, 8, "release", |
c8ce098ecc08
mxe-octave: update build rules
John W. Eaton <jwe@octave.org>
parents:
5
diff
changeset
|
811 ["nsis-installer", "7z-dist"]))) |
3
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
812 |
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
813 |
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
814 c["builders"].append (BuilderConfig (name = "w32-stable-on-debian", |
9 | 815 workernames = ["jwe-debian-x86_64-0"], |
6
c8ce098ecc08
mxe-octave: update build rules
John W. Eaton <jwe@octave.org>
parents:
5
diff
changeset
|
816 factory = mk_w32_factory (19, 8, "stable", |
c8ce098ecc08
mxe-octave: update build rules
John W. Eaton <jwe@octave.org>
parents:
5
diff
changeset
|
817 ["nsis-installer", "7z-dist"]))) |
3
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
818 |
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
819 c["builders"].append (BuilderConfig (name = "w64-32-stable-on-debian", |
9 | 820 workernames = ["jwe-debian-x86_64-1"], |
6
c8ce098ecc08
mxe-octave: update build rules
John W. Eaton <jwe@octave.org>
parents:
5
diff
changeset
|
821 factory = mk_w64_32_factory (19, 8, "stable", |
c8ce098ecc08
mxe-octave: update build rules
John W. Eaton <jwe@octave.org>
parents:
5
diff
changeset
|
822 ["nsis-installer", "7z-dist"]))) |
3
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
823 |
7a07ae3068be
add mxe-octave 'release' builds and rebalance worker loads
John W. Eaton <jwe@octave.org>
parents:
2
diff
changeset
|
824 c["builders"].append (BuilderConfig (name = "w64-64-stable-on-debian", |
9 | 825 workernames = ["jwe-debian-x86_64-3"], |
6
c8ce098ecc08
mxe-octave: update build rules
John W. Eaton <jwe@octave.org>
parents:
5
diff
changeset
|
826 factory = mk_w64_64_factory (19, 8, "stable", |
c8ce098ecc08
mxe-octave: update build rules
John W. Eaton <jwe@octave.org>
parents:
5
diff
changeset
|
827 ["nsis-installer", "7z-dist"]))) |
0 | 828 |
829 c["builders"].append (BuilderConfig (name = "mxe-native-on-debian", | |
9 | 830 workernames = ["jwe-debian-x86_64-1"], |
0 | 831 factory = mk_native_factory (19, 8, "default", "tar-dist"))) |
832 | |
833 c["builders"].append (BuilderConfig (name = "mxe-native-all-on-debian", | |
9 | 834 workernames = ["jwe-debian-x86_64-3"], |
0 | 835 factory = mk_native_all_factory (19, 8, "default", "tar-dist"))) |
836 | |
837 | |
838 ## PROJECT IDENTITY | |
839 | |
840 ## the 'title' string will appear at the top of this buildbot | |
841 ## installation's html.WebStatus home page (linked to the 'titleURL') | |
842 ## and is embedded in the title of the waterfall HTML page. | |
843 | |
844 c["title"] = "GNU Octave Buildbot" | |
845 c["titleURL"] = "https://octave.org" | |
846 | |
847 # The 'buildbotURL' string should point to the location where the buildbot's | |
848 # internal web server is visible. This typically uses the port number set in | |
849 # the 'www' entry below, but with an externally-visible host name which the | |
850 # buildbot cannot figure out without some help. | |
851 | |
5
0b956eea0df3
move master web server back to port 8010
John W. Eaton <jwe@octave.org>
parents:
4
diff
changeset
|
852 c['buildbotURL'] = "http://buildbot.octave.org:8010/" |
0 | 853 |
854 ## Minimalistic config to activate new web UI | |
855 | |
856 from buildbot.plugins import util | |
857 | |
858 c['www'] = { | |
5
0b956eea0df3
move master web server back to port 8010
John W. Eaton <jwe@octave.org>
parents:
4
diff
changeset
|
859 "port" : 8010, |
0b956eea0df3
move master web server back to port 8010
John W. Eaton <jwe@octave.org>
parents:
4
diff
changeset
|
860 "auth" : util.UserPasswordAuth (octave_buildbot_config.master_id_and_pass), |
0 | 861 "plugins" : { "waterfall_view" : True } |
862 } | |
863 | |
15 | 864 c['www']['ui_default_config'] = { |
865 "Waterfall.scaling_waterfall": 0.02, | |
866 "Waterfall.lazy_limit_waterfall": 400 | |
867 } | |
868 | |
0 | 869 ## DB URL |
870 | |
871 ## This specifies what database buildbot uses to store its state. You | |
872 ## can leave this at its default for all but the largest installations. | |
873 | |
874 c["db"] = { "db_url" : "sqlite:///state.sqlite" } | |
875 | |
876 ## NOTIFICATIONS | |
877 | |
878 from buildbot.plugins import reporters | |
879 | |
880 c["services"] = [] | |
881 | |
882 m = reporters.MailNotifier (fromaddr = "NO-REPLY@octave.org", | |
883 sendToInterestedUsers = False, | |
884 extraRecipients = ["octave-buildbot@gnu.org"], | |
885 mode = "failing") | |
886 c["services"].append (m) |