Index: distutils/command/bdist_rpm.py =================================================================== RCS file: /cvsroot/python/distutils/distutils/command/bdist_rpm.py,v retrieving revision 1.37 diff -c -u -r1.37 bdist_rpm.py --- distutils/command/bdist_rpm.py 19 Nov 2002 13:12:28 -0000 1.37 +++ distutils/command/bdist_rpm.py 2 May 2003 12:47:17 -0000 @@ -302,20 +302,16 @@ self.spawn(rpm_cmd) # XXX this is a nasty hack -- we really should have a proper way to - # find out the names of the RPM files created; also, this assumes - # that RPM creates exactly one source and one binary RPM. + # find out the names of the RPM files created; also, this will + # copy all generated RPM's to dist_dir if not self.dry_run: if not self.binary_only: - srpms = glob.glob(os.path.join(rpm_dir['SRPMS'], "*.rpm")) - assert len(srpms) == 1, \ - "unexpected number of SRPM files found: %s" % srpms - self.move_file(srpms[0], self.dist_dir) + for srpmfile in glob.glob(os.path.join(rpm_dir['SRPMS'], "*.rpm")): + self.move_file(srpmfile, self.dist_dir) if not self.source_only: - rpms = glob.glob(os.path.join(rpm_dir['RPMS'], "*/*.rpm")) - assert len(rpms) == 1, \ - "unexpected number of RPM files found: %s" % rpms - self.move_file(rpms[0], self.dist_dir) + for rpmfile in glob.glob(os.path.join(rpm_dir['RPMS'], "*/*.rpm")): + self.move_file(rpmfile, self.dist_dir) # run()