1
0
mirror of https://github.com/openSUSE/osc.git synced 2024-09-20 09:16:16 +02:00

* use a release number setting on local build, if it is given by the server.

Otherwise just use 0 as fallback
This commit is contained in:
Adrian Schröter 2009-08-20 10:45:39 +00:00
parent 2a180fa346
commit 090e79964c

View File

@ -54,7 +54,6 @@ class Buildinfo:
"""represent the contents of a buildinfo file"""
def __init__(self, filename, apiurl, buildtype = 'spec'):
try:
tree = ET.parse(filename)
except:
@ -82,6 +81,9 @@ class Buildinfo:
self.pacsuffix = 'deb'
self.buildarch = root.find('arch').text
self.release = "0"
if root.find('release') != None:
self.release = root.find('release').text
self.downloadurl = root.get('downloadurl')
self.debuginfo = 0
if root.find('debuginfo') != None:
@ -534,13 +536,14 @@ def main(opts, argv):
cmd = '%s --root=%s --rpmlist=%s --dist=%s %s --arch=%s %s %s %s' \
cmd = '%s --root=%s --rpmlist=%s --dist=%s %s --arch=%s --release=%s %s %s %s' \
% (config['build-cmd'],
config['build-root'],
rpmlist_file.name,
bc_file.name,
specialcmdopts,
bi.buildarch,
bi.release,
vm_options,
build_descr,
buildargs)