From 6b3c4292cdb48dbc949dab457956a9c27b79faed Mon Sep 17 00:00:00 2001 From: Alessio Ababilov Date: Tue, 25 Jun 2013 10:26:01 +0300 Subject: [PATCH] py2rpm: add --binary-only option Change-Id: I78b43e499747b085b3b2e5398b7647f958afdb3c --- tools/py2rpm | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/tools/py2rpm b/tools/py2rpm index 02bba739..f85e30c2 100755 --- a/tools/py2rpm +++ b/tools/py2rpm @@ -180,6 +180,11 @@ def create_parser(): action="store_true", default=False, help="Only generate source RPM") + parser.add_argument( + "--binary-only", "-b", + action="store_true", + default=False, + help="Only generate binary RPM") parser.add_argument( "--rpm-base", metavar="", @@ -473,6 +478,8 @@ def build_rpm(options, filename): if options.source_only: rpmbuild_what = "-bs" + elif options.binary_only: + rpmbuild_what = "-bb" else: rpmbuild_what = "-ba" call_subprocess(