debian/bin/gencontrol.py: Check unstable and experimental uploads.

svn path=/dists/trunk/linux-2.6/; revision=14672
This commit is contained in:
Bastian Blank 2009-11-24 18:30:52 +00:00
parent efe8b3659e
commit eb927a5fd2
1 changed files with 12 additions and 1 deletions

View File

@ -285,7 +285,7 @@ class Gencontrol(Base):
break
versions.append(i.version)
self.versions = versions
self.version = self.changelog[0].version
version = self.version = self.changelog[0].version
if self.version.linux_modifier is not None:
self.abiname = ''
else:
@ -299,6 +299,17 @@ class Gencontrol(Base):
}
self.config['version',] = {'source': self.version.complete, 'abiname': self.abiname}
distribution = self.changelog[0].distribution
if distribution in ('unstable', ):
if (version.linux_revision_experimental or
version.linux_revision_other):
raise RuntimeError("Can't upload to %s with a version of %s" %
(distribution, version))
if distribution in ('experimental', ):
if not version.linux_revision_experimental:
raise RuntimeError("Can't upload to %s with a version of %s" %
(distribution, version))
def process_real_image(self, entry, fields, vars):
entry = self.process_package(entry, vars)
for key, value in fields.iteritems():