py2rpm: add --binary-only option
Change-Id: I78b43e499747b085b3b2e5398b7647f958afdb3c
This commit is contained in:
parent
0b10346479
commit
6b3c4292cd
@ -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="<dir>",
|
||||
@ -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(
|
||||
|
Loading…
Reference in New Issue
Block a user