Re: missing perl test modules in postgresqlXX-devel ? - Mailing list pgsql-pkg-yum

From Craig Ringer
Subject Re: missing perl test modules in postgresqlXX-devel ?
Date
Msg-id CAGRY4nwhfqJm=fqwhkhqK8u=2FxS+m4h2HNLNtp8bKS=MQ-hyA@mail.gmail.com
Whole thread Raw
In response to Re: missing perl test modules in postgresqlXX-devel ?  (Jehan-Guillaume de Rorthais <jgdr@dalibo.com>)
Responses Re: missing perl test modules in postgresqlXX-devel ?  (Jehan-Guillaume de Rorthais <jgdr@dalibo.com>)
Re: missing perl test modules in postgresqlXX-devel ?  (Devrim Gündüz <devrim@gunduz.org>)
List pgsql-pkg-yum
On Thu, Nov 12, 2020 at 6:36 PM Jehan-Guillaume de Rorthais <jgdr@dalibo.com> wrote:
 
I fired the vagrant generic/rhel7 box and registered it using my dev account:


Thanks.

Note that the package came from rhel-7-server-rpms:

  $ sudo yum history packages-info perl-Test-Simple|grep ^From
  From repo      : rhel-7-server-rpms

RHEL official documentation confirm the package is available in base repository:

  https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/7/html/package_manifest/package_lists_base_repository


Based on this, I think it's appropriate to modify the EL-7 spec file for all Pg versions (example patch is for -10) something like the following.

Note that I removed a duplicate guard for "&& 0%{?suse_version} >= 1315" where the test for "enabletaptests" already excluded that. And I made sure that both fedora and rhel require both IPC::Run and Test::More ; I don't see why that was ever not be the case.


--- a/rpm/redhat/master/non-common/postgresql-10/master/postgresql-10.spec
+++ b/rpm/redhat/master/non-common/postgresql-10/master/postgresql-10.spec
@@ -12,7 +12,7 @@
 %{!?kerbdir:%global kerbdir "/usr"}
 %{!?disablepgfts:%global disablepgfts 0}
 
-%if 0%{?rhel} || 0%{?suse_version} >= 1315
+%if (0%{?rhel} && 0%{?rhel} <= 6) || 0%{?suse_version} >= 1315
 %{!?enabletaptests:%global enabletaptests 0}
 %else
 %{!?enabletaptests:%global enabletaptests 1}
@@ -367,17 +367,13 @@ Requires: libicu-devel
 %endif
 
 %if %enabletaptests
-%if 0%{?suse_version} && 0%{?suse_version} >= 1315
+%if 0%{?suse_version}
 Requires:  perl-IPC-Run
 BuildRequires: perl-IPC-Run
 %endif
-%if 0%{?rhel} && 0%{?rhel} <= 7
-Requires:  perl-Test-Simple
-BuildRequires: perl-Test-Simple
-%endif
-%if 0%{?fedora}
-Requires:  perl-IPC-Run
-BuildRequires: perl-IPC-Run
+%if 0%{?rhel} || 0%{?fedora}
+Requires:  perl(Test::More) perl(IPC::Run)
+BuildRequires: perl(Test::More) perl(IPC::Run)
 %endif
 %endif

pgsql-pkg-yum by date:

Previous
From: Devrim Gündüz
Date:
Subject: Re: pg13.1 and llvm on centos8
Next
From: Jehan-Guillaume de Rorthais
Date:
Subject: Re: missing perl test modules in postgresqlXX-devel ?