aboutsummaryrefslogtreecommitdiff
path: root/gbp/scripts/buildpackage_rpm.py
diff options
context:
space:
mode:
authorMarkus Lehtonen <markus.lehtonen@linux.intel.com>2015-10-05 15:28:59 +0300
committerGuido G√ľnther <agx@sigxcpu.org>2015-10-20 08:35:11 +0200
commitf157bfb3ef0aab201acdb8bb9b213922c7793ffe (patch)
treea2f455170f8432dba26a6be1abd499a09012a55e /gbp/scripts/buildpackage_rpm.py
parent34b4f6508230759246f0414161e22ef57bdac0c4 (diff)
buildpackage_rpm: fix crash when package has no source archive
Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
Diffstat (limited to 'gbp/scripts/buildpackage_rpm.py')
-rw-r--r--gbp/scripts/buildpackage_rpm.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/gbp/scripts/buildpackage_rpm.py b/gbp/scripts/buildpackage_rpm.py
index f34d6cd..7e90cee 100644
--- a/gbp/scripts/buildpackage_rpm.py
+++ b/gbp/scripts/buildpackage_rpm.py
@@ -531,7 +531,6 @@ def main(argv):
raise GbpError("Error exporting packaging files: %s" % err)
spec.specdir = os.path.abspath(spec_dir)
- orig_prefix = spec.orig_src['prefix']
# Get/build the orig tarball
if is_native(repo, options):
if spec.orig_src and not options.no_create_orig:
@@ -543,6 +542,7 @@ def main(argv):
"compression '%s -%s'" %
(spec.orig_src['compression'],
options.comp_level))
+ orig_prefix = spec.orig_src['prefix']
if not git_archive(repo, spec, source_dir, tree,
orig_prefix, options.comp_level,
options.with_submodules):