101 lines
3 KiB
Python
Executable file
101 lines
3 KiB
Python
Executable file
#! /usr/bin/python
|
|
|
|
from buildbot.changes.svnpoller import SVNPoller
|
|
from buildbot.steps.source import SVN
|
|
from buildbot.process.factory import GNUAutoconf, s
|
|
from buildbot.status import html, mail, words
|
|
from buildbot import scheduler, locks
|
|
|
|
# This is a list of everyone who has volunteered to run a Ledger buildbot
|
|
slaves = [
|
|
(("johnw-ppc", "XXXXXXXX"), "darwin-ppc"),
|
|
(("johnw-x86", "XXXXXXXX"), "darwin-x86")
|
|
]
|
|
|
|
# There are times when the DNS lookup of this hostname on hcoop.net
|
|
# fails and then SVN polling stops.
|
|
repository = "https://ledger.svn.sourceforge.net/svnroot/ledger/trunk"
|
|
|
|
c = {
|
|
'bots': [item[0] for item in slaves],
|
|
'sources': [SVNPoller(svnbin="/usr/bin/svn", svnurl=repository)],
|
|
'builders': [],
|
|
'schedulers': [],
|
|
'status': [],
|
|
'slavePortnum': 8007
|
|
}
|
|
|
|
|
|
# Define all of the build targets that need testing on each platform
|
|
|
|
MY_CPPFLAGS = "-I/sw/include -I/opt/include -I/usr/local/include"
|
|
MY_LDFLAGS = "-L/sw/lib -L/opt/lib -L/usr/local/lib"
|
|
MY_FLAGS = "CPPFLAGS=\"%s\" LDFLAGS=\"%s\"" % (MY_CPPFLAGS, MY_LDFLAGS)
|
|
|
|
svnsource = s(SVN, svnurl=repository, mode="clobber")
|
|
|
|
builders = []
|
|
builders.append({
|
|
'name': 'distcheck',
|
|
'factory': GNUAutoconf(svnsource,
|
|
configure="chmod -R u+w .; ./acprep --local",
|
|
compile=None,
|
|
test=("make %s distcheck" % MY_FLAGS))
|
|
})
|
|
builders.append({
|
|
'name': 'normal',
|
|
'factory': GNUAutoconf(svnsource,
|
|
configure="./acprep --local",
|
|
test="make fullcheck")
|
|
})
|
|
builders.append({
|
|
'name': 'python',
|
|
'factory': GNUAutoconf(svnsource,
|
|
configure="./acprep --local --python",
|
|
test="make fullcheck")
|
|
})
|
|
builders.append({
|
|
'name': 'debug',
|
|
'factory': GNUAutoconf(svnsource,
|
|
configure="./acprep --local --debug",
|
|
test="make fullcheck")
|
|
})
|
|
builders.append({
|
|
'name': 'debug-python',
|
|
'factory': GNUAutoconf(svnsource,
|
|
configure="./acprep --local --debug --python",
|
|
test="make fullcheck")
|
|
})
|
|
|
|
|
|
# Add a builder for each build target on every platform
|
|
|
|
slow_lock = locks.SlaveLock("cpu", maxCount = 1)
|
|
|
|
for builder in builders:
|
|
for slave, arch in slaves:
|
|
c['builders'].append({
|
|
'name': arch + '-' + builder['name'],
|
|
'slavename': slave[0],
|
|
'builddir': arch + '-' + builder['name'],
|
|
'factory': builder['factory'],
|
|
'locks': [slow_lock]
|
|
})
|
|
|
|
|
|
c['schedulers'] = [
|
|
scheduler.Scheduler("full", None, 60,
|
|
[b['name'] for b in c['builders']])
|
|
]
|
|
|
|
c['status'] = [
|
|
html.Waterfall(http_port=9090, allowForce=False),
|
|
|
|
mail.MailNotifier(fromaddr="johnw@newartisans.com",
|
|
extraRecipients=["jwiegley@gmail.com"]),
|
|
|
|
words.IRC("irc.freenode.net", "ledgerbot", allowForce=False,
|
|
channels=["#ledger"])
|
|
]
|
|
|
|
BuildmasterConfig = c
|