From a27a9f9c173bf2a41ef0675a4b9f6d3e8dee263d Mon Sep 17 00:00:00 2001 From: Markus Lehtonen Date: Fri, 11 Jan 2013 16:43:32 +0200 Subject: rpm.SpecFile: drop the internal sources structure Get rid of duplicate data tracking. Signed-off-by: Markus Lehtonen Signed-off-by: Yigang Wen --- gbp/scripts/import_srpm.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'gbp/scripts/import_srpm.py') diff --git a/gbp/scripts/import_srpm.py b/gbp/scripts/import_srpm.py index 92bb022b..be03d187 100755 --- a/gbp/scripts/import_srpm.py +++ b/gbp/scripts/import_srpm.py @@ -327,9 +327,9 @@ def main(argv): # Need to copy files to the packaging directory given by caller files = [os.path.basename(patch.path) \ for patch in spec.patchseries(unapplied=True, ignored=True)] - for num, src in spec.sources.iteritems(): - if num != spec.orig_src_num: - files.append(src['filename']) + for num, filename in spec.sources().iteritems(): + if not spec.orig_src or num != spec.orig_src['num']: + files.append(os.path.basename(filename)) files.append(os.path.join(spec.specdir, spec.specfile)) for fname in files: fpath = os.path.join(dirs['src'], fname) -- cgit v1.2.3