From 2282d3f47fc9d54c0137e16dc1a2964b9ce150e1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Petr=20P=C3=ADsa=C5=99?= Date: Tue, 12 Dec 2017 13:56:59 +0100 Subject: [PATCH] Control test by a build condition perl-YAML tests have enormous dependency tree. We are not proud of it but when packaging a subset of Perl packages (e.g. into a Modalarity module), we need to cut off the dependency tree somewhere. Run-time dependencies of perl-Test-YAML is one of the place. --- perl-YAML.spec | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/perl-YAML.spec b/perl-YAML.spec index 23bbd33..438ef65 100644 --- a/perl-YAML.spec +++ b/perl-YAML.spec @@ -1,3 +1,6 @@ +# Run test +%bcond_without perl_YAML_enables_test + Name: perl-YAML Version: 1.24 Release: 1%{?dist} @@ -24,7 +27,7 @@ BuildRequires: perl(strict) BuildRequires: perl(warnings) # Test Suite # Avoid circular build deps Test::YAML → Test::Base → YAML when bootstrapping -%if !%{defined perl_bootstrap} +%if %{with perl_YAML_enables_test} && !%{defined perl_bootstrap} BuildRequires: perl(Data::Dumper) BuildRequires: perl(File::Find) BuildRequires: perl(IO::File) @@ -65,7 +68,7 @@ make install DESTDIR=%{buildroot} %check # Avoid circular build deps Test::YAML → Test::Base → YAML when bootstrapping -%if !%{defined perl_bootstrap} +%if %{with perl_YAML_enables_test} && !%{defined perl_bootstrap} make test %endif