2 # ex: set syntax=python:
4 ###################################################################################
5 # This is the file configuration of the buildmaster used in the Simgrid project.
7 # The buildmaster configuration object.
9 c = BuildmasterConfig = {}
11 # Gets bot from account module
12 from account import bots
16 # Port number used by slaves
17 c['slavePortnum'] = 9989
22 # the 'sources' list tells the buildmaster how it should find out about
23 # source code changes. Any class which implements IChangeSource can be added
24 # to this list: there are several in buildbot/changes/*.py to choose from.
28 # For example, if you had CVSToys installed on your repository, and your
29 # CVSROOT/freshcfg file had an entry like this:
30 #pb = ConfigurationSet([
31 # (None, None, None, PBService(userpass=('foo', 'bar'), port=4519)),
34 # then you could use the following buildmaster Change Source to subscribe to
35 # the FreshCVS daemon and be notified on every commit:
37 #from buildbot.changes.freshcvs import FreshCVSSource
38 #fc_source = FreshCVSSource("cvs.example.com", 4519, "foo", "bar")
39 #c['sources'].append(fc_source)
41 # or, use a PBChangeSource, and then have your repository's commit script run
42 # 'buildbot sendchange', or contrib/svn_buildbot.py, or
43 # contrib/arch_buildbot.py :
45 #from buildbot.changes.pb import PBChangeSource
46 #c['sources'].append(PBChangeSource())
50 ####################################################################################
51 ## Scheduler configuration
53 # We use only one scheduling right now, a nightly one, which reruns everything
55 # TODO: setup a rebuilder in response to CVS commits
56 # TODO: Define a list of all slaves and use it here and in the definition of c['builders']
58 from buildbot.scheduler import Scheduler, Nightly, Periodic
60 nightly_scheduler = Nightly(
62 ["linux_amd64_pthreads_O3",
63 "linux_amd64_ucontext_O3",
64 "linux_i386_pthreads_O3",
65 "linux_i386_ucontext_O3",
74 c['schedulers'] = [nightly_scheduler]
76 now = Periodic("now", [
77 "linux_amd64_pthreads_O3",
78 "linux_amd64_ucontext_O3",
79 "linux_i386_pthreads_O3",
80 "linux_i386_ucontext_O3",
85 c['schedulers'] = [nightly_scheduler]
89 ####################################################################################
90 # builders declarations
92 from buildbot import locks
93 from buildbot.process import step, factory
94 from extensions import CustomConfigure
95 from buildbot.process.step import ShellCommand, CVS
98 # the following lock manages the builds of the machine bob
99 bob_lock = locks.MasterLock("bob_lock")
101 # the following lock manages the builds of the machine artimon
102 artimon_lock = locks.MasterLock("artimon_lock")
104 # the following lock manages the builds of the machine blase
105 blaise_lock = locks.MasterLock("blaise_lock")
107 # the following lock manages the builds of the machine fastnet
108 fastnet_lock = locks.MasterLock("fastnet_lock")
112 pthreads_factory= factory.BuildFactory()
113 pthreads_factory.addStep(step.SVN, name ="{svn update}",baseURL='svn://scm.gforge.inria.fr/svn/simgrid/simgrid/', defaultBranch='trunk', mode="update")
114 pthreads_factory.addStep(step.ShellCommand,name = "{svn revert}",description = "running svn revert",descriptionDone = "svn revert",haltOnFailure = 1,command=["svn" ,"revert","-R","build"])
115 pthreads_factory.addStep(step.ShellCommand,name = "{configure}",command=["./configure", "--with-pthread", "--enable-botbuild"])
116 pthreads_factory.addStep(step.ShellCommand,name = "{make clean}",command=["make", "clean"])
117 pthreads_factory.addStep(step.ShellCommand,name = "{make}",command=["make","-j","4"])
118 pthreads_factory.addStep(step.ShellCommand,name ="{check all}",command=["./checkall"])
119 #pthreads_factory.addStep(step.ShellCommand,name ="{make distcheck}",command=["make", "distcheck"])
121 ucontext_factory= factory.BuildFactory()
122 ucontext_factory.addStep(step.SVN, name ="{svn update}",baseURL='svn://scm.gforge.inria.fr/svn/simgrid/simgrid/', defaultBranch='trunk', mode="update")
123 ucontext_factory.addStep(step.ShellCommand,name = "{svn revert}",description = "running svn revert",descriptionDone = "svn revert",haltOnFailure = 1,command=["svn" ,"revert","-R","build"])
124 ucontext_factory.addStep(CustomConfigure,name ="{configure}",command=["./configure", " --with-context=ucontext","--enable-botbuild"]) # Main difference with pthread_factory
125 ucontext_factory.addStep(step.ShellCommand,name = "{make clean}",command=["make", "clean"])
126 ucontext_factory.addStep(step.ShellCommand,name = "{make}",command=["make","-j","4"])
127 ucontext_factory.addStep(step.ShellCommand,name = "{check all}",command=["./checkall"])
128 #ucontext_factory.addStep(step.ShellCommand,name = "{make distcheck}",command=["make", "distcheck"])
131 pthreads_factory_O3= factory.BuildFactory()
132 pthreads_factory_O3.addStep(step.SVN, name ="{svn update}",baseURL='svn://scm.gforge.inria.fr/svn/simgrid/simgrid/', defaultBranch='trunk', mode="update")
133 pthreads_factory_O3.addStep(step.ShellCommand,name = "{svn revert}",description = "running svn revert",descriptionDone = "svn revert",haltOnFailure = 1,command=["svn" ,"revert","-R","build"])
134 pthreads_factory_O3.addStep(step.ShellCommand,name = "{configure}",description="running configure",descriptionDone="configure",haltOnFailure = 1,command=["./configure", "--with-pthread","--enable-compile-optimizations","--enable-botbuild"])
135 pthreads_factory_O3.addStep(step.ShellCommand,name = "{make clean}",description = "running make clean",descriptionDone = "make clean",haltOnFailure = 1,command=["make", "clean"])
136 pthreads_factory_O3.addStep(step.ShellCommand,name = "{make}",description = "running make",descriptionDone = "make",haltOnFailure = 1,command=["make","-j","4"])
137 pthreads_factory_O3.addStep(step.ShellCommand,name ="{check all}",description = "running check all",descriptionDone ="check all",haltOnFailure = 1,command=["./checkall"])
138 #pthreads_factory_O3.addStep(step.ShellCommand,name ="{make distcheck}",description="running make distcheck",descriptionDone="make distcheck",haltOnFailure = 1,command=["make", "distcheck"])
140 ucontext_factory_O3= factory.BuildFactory()
141 ucontext_factory_O3.addStep(step.SVN, name ="{svn update}",baseURL='svn://scm.gforge.inria.fr/svn/simgrid/simgrid/', defaultBranch='trunk', mode="update")
142 ucontext_factory_O3.addStep(step.ShellCommand,name = "{svn revert}",description = "running svn revert",descriptionDone = "svn revert",haltOnFailure = 1,command=["svn" ,"revert","-R","build"])
143 ucontext_factory_O3.addStep(CustomConfigure,name ="{configure}",description="running configure",descriptionDone="configure",haltOnFailure = 1,command=["./configure", "--with-context=ucontext","--enable-compile-optimizations","--enable-botbuild"]) # Main difference with pthread_factory
144 ucontext_factory_O3.addStep(step.ShellCommand,name = "{make}",description = "running make",descriptionDone = "make",haltOnFailure = 1,command=["make"])
145 ucontext_factory_O3.addStep(step.ShellCommand,name = "{check all}",description = "running check all",descriptionDone ="check all",haltOnFailure = 1,command=["./checkall"])
146 #ucontext_factory_O3.addStep(step.ShellCommand,name = "{make distcheck}",description="running make distcheck",descriptionDone="make distcheck",haltOnFailure = 1,command=["make", "distcheck"])
150 windows_factory= factory.BuildFactory()
151 windows_factory.addStep(step.SVN, name ="{svn update}",baseURL='svn://scm.gforge.inria.fr/svn/simgrid/simgrid/', defaultBranch='trunk', mode="update")
152 windows_factory.addStep(step.ShellCommand,name = "{make}",description = "running make",descriptionDone = "make",haltOnFailure = 1,command=["C:\\buildslave\\projects\\simgrid\\builddir\\buildMake", "C:\\buildslave\\projects\\simgrid\\builddir\\make_all.tst"])
153 windows_factory.addStep(step.ShellCommand,name = "{test suite}",description= "running test suite",descriptionDone ="test suite",haltOnFailure = 1,command=["C:\\buildslave\\projects\\simgrid\\builddir\\Test", "C:\\buildslave\\projects\\simgrid\\builddir\\test_all.tst"])
159 {'name':'linux_amd64_pthreads_O3',
160 'slavename':'bob_pthreads',
161 'builddir':'/var/lib/buildbot/simgrid/linux_amd64_pthreads/builddir_O3',
162 'factory':pthreads_factory_O3,
163 'locks': [bob_lock]},
167 {'name':'linux_amd64_ucontext_O3',
168 'slavename':'bob_ucontext',
169 'builddir':'/var/lib/buildbot/simgrid/linux_amd64_ucontext/builddir_O3',
170 'factory':ucontext_factory_O3,
171 'locks': [bob_lock]},
174 {'name':'mac_os_x_pthreads',
175 'slavename':'fastnet_pthreads',
176 'builddir':'/var/buildbot/simgrid/mac_os_x_pthreads/builddir',
177 'factory':pthreads_factory_O3,
178 'locks': [fastnet_lock]},
180 {'name':'mac_os_x_ucontext',
181 'slavename':'fastnet_ucontext',
182 'factory':ucontext_factory_O3,
183 'builddir':'/var/buildbot/simgrid/mac_os_x_ucontext/builddir',
184 'locks': [fastnet_lock]},
187 {'name':'windows_builder',
188 'slavename':'windows_slave',
189 'builddir':"C:\\buildslave\\projects\\simgrid\\builddir",
190 'factory':windows_factory},
193 {'name':'linux_i386_pthreads_O3',
194 'slavename':'artimon_pthreads',
195 'builddir':'/var/lib/buildbot/simgrid/linux_i386_pthreads/builddir_O3',
196 'factory':pthreads_factory_O3,
197 'locks': [artimon_lock]},
200 {'name':'linux_i386_ucontext_O3',
201 'slavename':'artimon_ucontext',
202 'builddir':'/var/lib/buildbot/simgrid/linux_i386_ucontext/builddir_O3',
203 'factory':ucontext_factory_O3,
204 'locks': [artimon_lock]}
212 from buildbot.status import html
213 w = html.Waterfall(http_port=8010)
215 c['status'].append(w)
217 # status smtp request
219 from buildbot.status import mail
222 c['status'].append(mail.MailNotifier(builders=['mac_os_x_pthreads'],
223 fromaddr="bob@loria.fr",relayhost="smtp.loria.fr",mode="failing",
224 subject = "Error occured during pthread build of SimGrid on fastnet",
225 extraRecipients=["malek.cherier@loria.fr","martin.quinson@loria.fr"],
226 sendToInterestedUsers=True))
228 c['status'].append(mail.MailNotifier(builders=['mac_os_x_ucontext'],
229 fromaddr="bob@loria.fr",relayhost="smtp.loria.fr",mode="failing",
230 subject = "Error occured during ucontext build of SimGrid on fastnet",
231 extraRecipients=["malek.cherier@loria.fr",
232 "martin.quinson@loria.fr"],sendToInterestedUsers=True))
235 c['status'].append(mail.MailNotifier(builders=['linux_amd64_pthreads'],
236 fromaddr="bob@loria.fr",relayhost="smtp.loria.fr",mode="failing",
237 subject = "Error occured during pthread build of SimGrid on bob",
238 extraRecipients=["malek.cherier@loria.fr",
239 "martin.quinson@loria.fr"],
240 sendToInterestedUsers=True))
242 c['status'].append(mail.MailNotifier(builders=['linux_amd64_pthreads_O0'],
243 fromaddr="bob@loria.fr",relayhost="smtp.loria.fr",mode="failing",
244 subject = "Error occured during pthread build of SimGrid on bob (compiler optimizations O0 enabled)",
245 extraRecipients=["malek.cherier@loria.fr",
246 "martin.quinson@loria.fr"],
247 sendToInterestedUsers=True))
249 c['status'].append(mail.MailNotifier(builders=['linux_amd64_pthreads_O3'],
250 fromaddr="bob@loria.fr",relayhost="smtp.loria.fr",mode="failing",
251 subject = "Error occured during pthread build of SimGrid on bob (compiler optimizations O3 enabled)",
252 extraRecipients=["malek.cherier@loria.fr",
253 "martin.quinson@loria.fr"],
254 sendToInterestedUsers=True))
256 c['status'].append(mail.MailNotifier(builders=['linux_amd64_ucontext'],
257 fromaddr="bob@loria.fr",relayhost="smtp.loria.fr",mode="failing",
258 subject = "Error occured during ucontext build of SimGrid on bob",
259 extraRecipients=["malek.cherier@loria.fr",
260 "martin.quinson@loria.fr"],
261 sendToInterestedUsers=True))
263 c['status'].append(mail.MailNotifier(builders=['linux_amd64_ucontext_O0'],
264 fromaddr="bob@loria.fr",relayhost="smtp.loria.fr",mode="failing (compiler optimizations O0 enabled)",
265 subject = "Error occured during ucontext build of SimGrid on bob",
266 extraRecipients=["malek.cherier@loria.fr",
267 "martin.quinson@loria.fr"],
268 sendToInterestedUsers=True))
270 c['status'].append(mail.MailNotifier(builders=['linux_amd64_ucontext_O3'],
271 fromaddr="bob@loria.fr",relayhost="smtp.loria.fr",mode="failing",
272 subject = "Error occured during ucontext build of SimGrid on bob (compiler optimizations O3 enabled)",
273 extraRecipients=["malek.cherier@loria.fr",
274 "martin.quinson@loria.fr"],
275 sendToInterestedUsers=True))
277 c['status'].append(mail.MailNotifier(builders=['windows_builder'],
278 fromaddr="bob@loria.fr",relayhost="smtp.loria.fr",mode="failing",
279 subject = "An error occurs during the build of SimGRID on Windows platform",
280 extraRecipients=["malek.cherier@loria.fr",
281 "martin.quinson@loria.fr"],
282 sendToInterestedUsers=True))
284 c['status'].append(mail.MailNotifier(builders=['linux_i386_pthreads'],
285 fromaddr="bob@loria.fr",relayhost="smtp.loria.fr",mode="failing",
286 subject = "An error occurs during the build of SimGRID on artimon platform",
287 extraRecipients=["malek.cherier@loria.fr",
288 "martin.quinson@loria.fr"],
289 sendToInterestedUsers=True))
292 c['status'].append(mail.MailNotifier(builders=['linux_i386_pthreads_O0'],
293 fromaddr="bob@loria.fr",relayhost="smtp.loria.fr",mode="failing",
294 subject = "An error occurs during the build of SimGRID on artimon platform (compiler optimizations O0 enabled)" ,
295 extraRecipients=["malek.cherier@loria.fr",
296 "martin.quinson@loria.fr"],
297 sendToInterestedUsers=True))
299 c['status'].append(mail.MailNotifier(builders=['linux_i386_pthreads_O3'],
300 fromaddr="bob@loria.fr",relayhost="smtp.loria.fr",mode="failing",
301 subject = "An error occurs during the build of SimGRID on artimon platform (compiler optimizations O3 enabled)" ,
302 extraRecipients=["malek.cherier@loria.fr",
303 "martin.quinson@loria.fr"],
304 sendToInterestedUsers=True))
307 c['status'].append(mail.MailNotifier(builders=['linux_i386_ucontext'],
308 fromaddr="bob@loria.fr",relayhost="smtp.loria.fr",mode="failing",
309 subject = "An error occurs during the build of SimGRID on artimon platform",
310 extraRecipients=["malek.cherier@loria.fr",
311 "martin.quinson@loria.fr"],
312 sendToInterestedUsers=True))
314 c['status'].append(mail.MailNotifier(builders=['linux_i386_ucontext_O0'],
315 fromaddr="bob@loria.fr",relayhost="smtp.loria.fr",mode="failing",
316 subject = "An error occurs during the build of SimGRID on artimon platform (compiler optimizations O0 enabled)",
317 extraRecipients=["malek.cherier@loria.fr",
318 "martin.quinson@loria.fr"],
319 sendToInterestedUsers=True))
321 c['status'].append(mail.MailNotifier(builders=['linux_i386_ucontext_O3'],
322 fromaddr="bob@loria.fr",relayhost="smtp.loria.fr",mode="failing",
323 subject = "An error occurs during the build of SimGRID on artimon platform (compiler optimizations O3 enabled)",
324 extraRecipients=["malek.cherier@loria.fr",
325 "martin.quinson@loria.fr"],
326 sendToInterestedUsers=True))
332 # Project informations
334 c['projectName'] = "SimGrid compilation status"
335 c['projectURL']= "http://simgrid.gforge.inria.fr/"
336 #c['projectURL'] = "http://bob.loria.fr:8010/"
337 c['buildbotURL'] = "http://bob.loria.fr:8010/"