Add --no-dynamic-buildrequires options
And set Fedora's default behavior is to enable DynamicBuildRequires. All Fedora crates use dynamic BuildRequires and are built only in Rawhide and is unlikely that anybody is building hundreds of crates outside of Fedora infrastructure. Closes: https://pagure.io/fedora-rust/rust2rpm/issue/97 Signed-off-by: Igor Gnatenko <ignatenkobrain@fedoraproject.org>
This commit is contained in:
parent
a6bde5599a
commit
47c75b2078
1 changed files with 5 additions and 0 deletions
|
@ -239,6 +239,8 @@ def main():
|
|||
help="Activate all available features")
|
||||
parser.add_argument("--dynamic-buildrequires", action="store_true",
|
||||
help="Use dynamic BuildRequires feature")
|
||||
parser.add_argument("--no-dynamic-buildrequires", action="store_true",
|
||||
help="Do not use dynamic BuildRequires feature")
|
||||
parser.add_argument("--suffix", action="store",
|
||||
help="Package suffix")
|
||||
parser.add_argument("crate", help="crates.io name\n"
|
||||
|
@ -319,6 +321,9 @@ def main():
|
|||
else:
|
||||
kwargs["pkg_release"] = "1%{?dist}"
|
||||
|
||||
if args.target == "fedora" and not args.no_dynamic_buildrequires:
|
||||
args.dynamic_buildrequires = True
|
||||
|
||||
kwargs["generate_buildrequires"] = args.dynamic_buildrequires
|
||||
|
||||
if args.target in {"opensuse", "fedora"}:
|
||||
|
|
Loading…
Reference in a new issue