Hi,

if rpmbuild doesn't create any RPMs, at the moment "rpm
--addsign" is called without any arguments and thus fails
with "no arguments given".  The attached patch fixes this.

HTH,
Tim
>From 02e24b6d7bd161b6ad66dd35e3f6366e9f4c4a77 Mon Sep 17 00:00:00 2001
From: Tim Landscheidt <t...@tim-landscheidt.de>
Date: Wed, 24 Oct 2012 23:18:57 +0000
Subject: [PATCH] Don't call "rpm --addsign" if rpmbuild didn't create RPMs.

---
 rpmpopt.in |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/rpmpopt.in b/rpmpopt.in
index 146c0ce..7a92ae5 100644
--- a/rpmpopt.in
+++ b/rpmpopt.in
@@ -174,7 +174,7 @@ rpmbuild alias --buildpolicy --define '__os_install_post %{_rpmconfigdir}/brp-!#
 	--POPTargs=$"<policy>"
 # Minimally preserve rpmbuild's --sign functionality
 rpmbuild alias --sign \
-	--pipe "grep '.*: .*\.rpm$'|cut -d: -f2|xargs rpm --addsign" \
+	--pipe "grep '.*: .*\.rpm$'|cut -d: -f2|xargs -r rpm --addsign" \
 	--POPTdesc=$"generate GPG signature"
 
 rpmsign alias --key-id  --define '_gpg_name !#:+' \
-- 
1.7.7.6

_______________________________________________
Rpm-maint mailing list
Rpm-maint@lists.rpm.org
http://lists.rpm.org/mailman/listinfo/rpm-maint

Reply via email to