| message -- explanation of why the specific transition is not allowed |
message -- explanation of why the specific transition is not allowed |
| """ |
""" |
| |
|
| def __init__(self, previous, next, message): |
def __init__(self, message): |
| self.message = message |
self.message = message |
| |
|
| def printverbose(myoutput): |
def printverbose(myoutput): |
| gkb_getsource(kinfo) |
gkb_getsource(kinfo) |
| |
|
| # go into the work directory |
# go into the work directory |
| chdir(workdir) |
chdir(workdir, kinfo) |
| |
|
| # archive the clean source for later uploading |
# archive the clean source for later uploading |
| os.spawnlp(os.P_WAIT, "tar xjf " + kinfo["mastertree"] + ".tar.bz2 " + kinfo["mastertree"]) |
log("archiving source to " + kinfo["mastertree"] + ".tar.bz2", kinfo) |
| |
os.spawnlp(os.P_WAIT, "tar cjf " + kinfo["mastertree"] + ".tar.bz2 " + kinfo["mastertree"]) |
| |
|
| # now we'll go into the tree's work dir |
# now we'll go into the tree's work dir |
| chdir(kinfo["workdir"],kinfo) |
chdir(kinfo["workdir"],kinfo) |
| verifydir("%s/work" % buildroot) # build dir, make sure it exists |
verifydir("%s/work" % buildroot) # build dir, make sure it exists |
| |
|
| # download the build jobs from the master site |
# download the build jobs from the master site |
| if os.spawnlp(os.P_WAIT, "wget --quiet --output-document=gkb.xml \"%s/manager.php?cmd=getjobs&host=%s&pass=%s\"" % (msite,host,passwd)): |
if os.spawnlp(os.P_WAIT, "wget", "wget", "--quiet", "--output-document=gkb.xml", "%s/manager.php?cmd=getjobs&host=%s&pass=%s" % (msite,host,passwd)) != 0: |
| deathbyerror("Unable to download build config from master site %s, aborting." % msite) |
raise FatalError, "Unable to download build config from master site %s, aborting." % msite |
| |
|
| # sets up 'mastertrees' and 'builds' dicts |
# sets up 'mastertrees' and 'builds' dicts |
| gkb_parsexml('gkb.xml') |
gkb_parsexml('gkb.xml') |
| gkb_build(root, bdict) |
gkb_build(root, bdict) |
| except BuildError, e: |
except BuildError, e: |
| log(e.message, bdict) |
log(e.message, bdict) |
| |
except KeyboardInterrupt, e: |
| |
log("Caught keyboard interrupt, exiting...") |
| |
break |
| |
except: |
| |
log("Caught unknown exception, exiting...") |
| |
break |
| |
|
| endtime=getoutput("date +'%R:%S %Z'") |
endtime=getoutput("date +'%R:%S %Z'") |
| |
|