summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJason Pepas <cell@ices.utexas.edu>2006-07-19 18:04:33 +0000
committerJason Pepas <cell@ices.utexas.edu>2006-07-19 18:04:33 +0000
commit714beece4603247a5008002922eb7072e0066f2b (patch)
treea2392e588d8c7885cf31575a37995aa5da56db3a
parent8b6165750d99fef457b5c55364cdd9398230b09f (diff)
downloadbcfg2-714beece4603247a5008002922eb7072e0066f2b.tar.gz
bcfg2-714beece4603247a5008002922eb7072e0066f2b.tar.bz2
bcfg2-714beece4603247a5008002922eb7072e0066f2b.zip
Updated rpmlisting.py to disable mtime verification for all multiarch packages.
git-svn-id: https://svn.mcs.anl.gov/repos/bcfg/trunk/bcfg2@1972 ce84e21b-d406-0410-9b95-82705330c041
-rw-r--r--tools/rpmlisting.py7
1 files changed, 5 insertions, 2 deletions
diff --git a/tools/rpmlisting.py b/tools/rpmlisting.py
index a189195c1..f2dc47fec 100644
--- a/tools/rpmlisting.py
+++ b/tools/rpmlisting.py
@@ -184,18 +184,21 @@ def scan_rpm_dir(rpmdir, uri, group, priority=0, output=sys.stdout):
pkgs = prune_archs(prune_pkgs(get_pkgs(rpmdir)))
for rpmblobs in pkgs.values():
if len(rpmblobs) == 1:
+ # regular pkgmgr entry
rpmblob = rpmblobs[0]
output.write(' <Package name="%s" simplefile="%s" version="%s-%s"/>\n' %
(rpmblob['name'], rpmblob['file'], rpmblob['version'], rpmblob['release']))
else:
+ # multiarch pkgmgr entry
rpmblob = rpmblobs[0]
archs = [blob['arch'] for blob in rpmblobs]
archs.sort()
multiarch_string = ' '.join(archs)
pattern_string = '\.(%s)\.rpm$' % '|'.join(archs) # e.g., '\.(i386|x86_64)\.rpm$'
pattern = re.compile(pattern_string)
- multiarch_file = pattern.sub('.%s.rpm', rpmblob['file']) # e.g., 'foo-1.0-1.%s.rpm'
- output.write(' <Package name="%s" file="%s" version="%s-%s" multiarch="%s"/>\n' %
+ multiarch_file = pattern.sub('.%(arch)s.rpm', rpmblob['file']) # e.g., 'foo-1.0-1.%(arch)s.rpm'
+ # hack! we must include verify="nomtime" for all multiarch packages on a fedora system.
+ output.write(' <Package name="%s" file="%s" version="%s-%s" multiarch="%s" verify="nomtime"/>\n' %
(rpmblob['name'], multiarch_file, rpmblob['version'], rpmblob['release'], multiarch_string))
output.write(' </Group>\n')
output.write('</PackageList>\n')