public inbox for [email protected]  
help / color / mirror / Atom feed
missing perl test modules in postgresqlXX-devel ?
16+ messages / 4 participants
[nested] [flat]

* missing perl test modules in postgresqlXX-devel ?
@ 2020-11-05 18:02 Jehan-Guillaume de Rorthais <[email protected]>
  2020-11-09 02:29 ` Re: missing perl test modules in postgresqlXX-devel ? Craig Ringer <[email protected]>
  0 siblings, 1 reply; 16+ messages in thread

From: Jehan-Guillaume de Rorthais @ 2020-11-05 18:02 UTC (permalink / raw)
  To: pgsql-pkg-yum

Hi,

I noticed the perl test modules from PostgreSQL source tree, eg.
PostgresNode, are not installed with package "postgresqlXX-devel". Only
pg_regress is installed.

Looking at the web, I can find old memories [1] where postgresql12-devel
installed them in /usr/pgsql-12/lib/pgxs/src/test/perl/

Comparing with Debian packages, they install both pg_regress and perl modules
with the client package under:

  $(pg_config --pkglibdir)/pgxs/src/test/perl/
  $(pg_config --pkglibdir)/pgxs/src/test/regress

Is it on purpose?

Regards,


[1] eg.:
https://fedora.pkgs.org/31/postgresql-12-x86_64/postgresql12-devel-12.3-1PGDG.f31.x86_64.rpm.html







^ permalink  raw  reply  [nested|flat] 16+ messages in thread

* Re: missing perl test modules in postgresqlXX-devel ?
  2020-11-05 18:02 missing perl test modules in postgresqlXX-devel ? Jehan-Guillaume de Rorthais <[email protected]>
@ 2020-11-09 02:29 ` Craig Ringer <[email protected]>
  2020-11-09 02:33   ` Re: missing perl test modules in postgresqlXX-devel ? Craig Ringer <[email protected]>
  2020-11-09 10:40   ` Re: missing perl test modules in postgresqlXX-devel ? Jehan-Guillaume de Rorthais <[email protected]>
  0 siblings, 2 replies; 16+ messages in thread

From: Craig Ringer @ 2020-11-09 02:29 UTC (permalink / raw)
  To: Jehan-Guillaume de Rorthais <[email protected]>; +Cc: pgsql-pkg-yum

On Fri, Nov 6, 2020 at 2:02 AM Jehan-Guillaume de Rorthais <[email protected]>
wrote:

> Hi,
>
> I noticed the perl test modules from PostgreSQL source tree, eg.
> PostgresNode, are not installed with package "postgresqlXX-devel". Only
> pg_regress is installed.
>
> Looking at the web, I can find old memories [1] where postgresql12-devel
> installed them in /usr/pgsql-12/lib/pgxs/src/test/perl/
>

We really need some consistency and cross checks between the RPMs and debs.
But it seems fine to me in the -12 and -13 packages for Fedora 32. So
please provide some more specifics about exactly what OS, yum repo
configuration, metadata version, etc you are using.

0 ~$ sudo dnf repoquery -f /usr/pgsql-12/bin/postgres
Last metadata expiration check: 0:00:49 ago on Mon 09 Nov 2020 10:25:05.
postgresql12-server-0:12.2-3PGDG.f32.x86_64
postgresql12-server-0:12.3-1PGDG.f32.x86_64
postgresql12-server-0:12.3-4PGDG.f32.x86_64
postgresql12-server-0:12.3-5PGDG.f32.x86_64
postgresql12-server-0:12.4-1PGDG.f32.x86_64

$ sudo dnf repoquery -f /usr/pgsql-13/bin/postgres
Last metadata expiration check: 0:00:55 ago on Mon 09 Nov 2020 10:25:05.
postgresql13-server-0:13.0-1PGDG.f32.x86_64

$ sudo dnf repoquery -f /usr/pgsql-12/lib/pgxs/src/test/perl/PostgresNode.pm
Last metadata expiration check: 0:01:06 ago on Mon 09 Nov 2020 10:25:05.
postgresql12-devel-0:12.2-3PGDG.f32.x86_64
postgresql12-devel-0:12.3-1PGDG.f32.x86_64
postgresql12-devel-0:12.3-4PGDG.f32.x86_64
postgresql12-devel-0:12.3-5PGDG.f32.x86_64
postgresql12-devel-0:12.4-1PGDG.f32.x86_64

$ sudo dnf repoquery -f /usr/pgsql-13/lib/pgxs/src/test/perl/PostgresNode.pm
Last metadata expiration check: 0:01:15 ago on Mon 09 Nov 2020 10:25:05.
postgresql13-devel-0:13.0-1PGDG.f32.x86_64


$ head -2 /etc/os-release
NAME=Fedora
VERSION="32 (Workstation Edition)"

$ sudo dnf repolist --enabled pgdg*
repo id
  repo name
pgdg-common
  PostgreSQL common RPMs for Fedora 32 - x86_64
pgdg10
   PostgreSQL 10 for Fedora 32 - x86_64
pgdg11
   PostgreSQL 11 for Fedora 32 - x86_64
pgdg12
   PostgreSQL 12 for Fedora 32 - x86_64
pgdg13
   PostgreSQL 13 for Fedora 32 - x86_64
pgdg95
   PostgreSQL 9.5 for Fedora 32 - x86_64
pgdg96
   PostgreSQL 9.6 for Fedora 32 - x86_64


^ permalink  raw  reply  [nested|flat] 16+ messages in thread

* Re: missing perl test modules in postgresqlXX-devel ?
  2020-11-05 18:02 missing perl test modules in postgresqlXX-devel ? Jehan-Guillaume de Rorthais <[email protected]>
  2020-11-09 02:29 ` Re: missing perl test modules in postgresqlXX-devel ? Craig Ringer <[email protected]>
@ 2020-11-09 02:33   ` Craig Ringer <[email protected]>
  2020-11-09 10:50     ` Re: missing perl test modules in postgresqlXX-devel ? Jehan-Guillaume de Rorthais <[email protected]>
  1 sibling, 1 reply; 16+ messages in thread

From: Craig Ringer @ 2020-11-09 02:33 UTC (permalink / raw)
  To: Jehan-Guillaume de Rorthais <[email protected]>; +Cc: pgsql-pkg-yum

Looking at the web, I can find old memories [1] where postgresql12-devel
>> installed them in /usr/pgsql-12/lib/pgxs/src/test/perl/
>>
>
> We really need some consistency and cross checks between the RPMs and debs.
>

Ah. I just noticed you said they're installed with the *client* packages.

So that's an example of how we actually need some postgres packaging
guidance that applies to rpms, debs, EDB's binary installers, and anything
else, separate to any particular packaging method or team.

In this case I think it's a bit silly to put the test perl modules along
with the client. They can't really be used without the server installed,
and they're not useful for much unless you're building extensions. They
should be in a -dev package IMO. They should preferably not be in the test
package along with the actual test input files, though, since they're used
by extensions to run their own tests and extensions only have to depend on
server-dev not on a -test package.

Anyway, I hope the above answers your questions about where they live.


^ permalink  raw  reply  [nested|flat] 16+ messages in thread

* Re: missing perl test modules in postgresqlXX-devel ?
  2020-11-05 18:02 missing perl test modules in postgresqlXX-devel ? Jehan-Guillaume de Rorthais <[email protected]>
  2020-11-09 02:29 ` Re: missing perl test modules in postgresqlXX-devel ? Craig Ringer <[email protected]>
  2020-11-09 02:33   ` Re: missing perl test modules in postgresqlXX-devel ? Craig Ringer <[email protected]>
@ 2020-11-09 10:50     ` Jehan-Guillaume de Rorthais <[email protected]>
  2020-11-09 19:45       ` Re: missing perl test modules in postgresqlXX-devel ? Christoph Berg <[email protected]>
  2020-11-10 00:53       ` Re: missing perl test modules in postgresqlXX-devel ? Craig Ringer <[email protected]>
  0 siblings, 2 replies; 16+ messages in thread

From: Jehan-Guillaume de Rorthais @ 2020-11-09 10:50 UTC (permalink / raw)
  To: Craig Ringer <[email protected]>; +Cc: pgsql-pkg-yum

On Mon, 9 Nov 2020 10:33:07 +0800
Craig Ringer <[email protected]> wrote:

> Looking at the web, I can find old memories [1] where postgresql12-devel
> >> installed them in /usr/pgsql-12/lib/pgxs/src/test/perl/
> >>  
> >
> > We really need some consistency and cross checks between the RPMs and debs.
> >  
> 
> Ah. I just noticed you said they're installed with the *client* packages.

Yes, under Debian. This was just for comparison and I was surprised as well.

Under EL7, I installed -devel packages as written in $subject

> So that's an example of how we actually need some postgres packaging
> guidance that applies to rpms, debs, EDB's binary installers, and anything
> else, separate to any particular packaging method or team.
> 
> In this case I think it's a bit silly to put the test perl modules along
> with the client.

This is a bit out of the scope of $subject, but I'll answer here anyway, as far
as it could be interesting.

> They can't really be used without the server installed, and they're not
> useful for much unless you're building extensions. They should be in a -dev
> package IMO. They should preferably not be in the test package along with the
> actual test input files, though, since they're used by extensions to run
> their own tests and extensions only have to depend on server-dev not on a
> -test package.

I agree they should live in -dev packages. But I should admit I have no idea
why Debian put them in -client ones. Maybe they have some other constraints
bound to the postgresql-common debian wrapper?

I am currently writing TAP tests for check_pgactivity and rely on PostgresNode
and friends to write and run them. They are very valuable and saves a lot of
time.

> Anyway, I hope the above answers your questions about where they live.

I had no doubt about where they live, sorry for the confusion.

Thank you,

/Jehan-Guillaume de Rorthais





^ permalink  raw  reply  [nested|flat] 16+ messages in thread

* Re: missing perl test modules in postgresqlXX-devel ?
  2020-11-05 18:02 missing perl test modules in postgresqlXX-devel ? Jehan-Guillaume de Rorthais <[email protected]>
  2020-11-09 02:29 ` Re: missing perl test modules in postgresqlXX-devel ? Craig Ringer <[email protected]>
  2020-11-09 02:33   ` Re: missing perl test modules in postgresqlXX-devel ? Craig Ringer <[email protected]>
  2020-11-09 10:50     ` Re: missing perl test modules in postgresqlXX-devel ? Jehan-Guillaume de Rorthais <[email protected]>
@ 2020-11-09 19:45       ` Christoph Berg <[email protected]>
  1 sibling, 0 replies; 16+ messages in thread

From: Christoph Berg @ 2020-11-09 19:45 UTC (permalink / raw)
  To: Jehan-Guillaume de Rorthais <[email protected]>; +Cc: Craig Ringer <[email protected]>; pgsql-pkg-yum

Re: Jehan-Guillaume de Rorthais
> I agree they should live in -dev packages. But I should admit I have no idea
> why Debian put them in -client ones. Maybe they have some other constraints
> bound to the postgresql-common debian wrapper?

They used to be in the -server-dev-NN package on Debian, but that had
the problem that running tests on installed extension package needed
more than that package's dependencies (namely this -server-dev-NN
package).

https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=944457

The change means you can "apt install postgresql-NN-whatever make",
check out the "whatever" source, cd there, and run "make installcheck"
(or rather "pg_virtualenv make installcheck").

Maybe moving pgxs to the -server package instead of -client would have
been better, but pg_regress is a client program in nature.

Christoph





^ permalink  raw  reply  [nested|flat] 16+ messages in thread

* Re: missing perl test modules in postgresqlXX-devel ?
  2020-11-05 18:02 missing perl test modules in postgresqlXX-devel ? Jehan-Guillaume de Rorthais <[email protected]>
  2020-11-09 02:29 ` Re: missing perl test modules in postgresqlXX-devel ? Craig Ringer <[email protected]>
  2020-11-09 02:33   ` Re: missing perl test modules in postgresqlXX-devel ? Craig Ringer <[email protected]>
  2020-11-09 10:50     ` Re: missing perl test modules in postgresqlXX-devel ? Jehan-Guillaume de Rorthais <[email protected]>
@ 2020-11-10 00:53       ` Craig Ringer <[email protected]>
  2020-11-10 13:41         ` Re: missing perl test modules in postgresqlXX-devel ? Jehan-Guillaume de Rorthais <[email protected]>
  1 sibling, 1 reply; 16+ messages in thread

From: Craig Ringer @ 2020-11-10 00:53 UTC (permalink / raw)
  To: Jehan-Guillaume de Rorthais <[email protected]>; +Cc: pgsql-pkg-yum

On Mon, Nov 9, 2020 at 6:50 PM Jehan-Guillaume de Rorthais <[email protected]>
wrote:

>
> I am currently writing TAP tests for check_pgactivity and rely on
> PostgresNode
> and friends to write and run them. They are very valuable and saves a lot
> of
> time.
>

I'm really glad. I have put a fair bit of effort into getting the test
infra installed as part of "make install" so it gets packaged.

Next I need to push for consistent -test packages for rpms and debs that
bundle the actual test .sql, .out, .spec, and t/*.pl files needed to
actually run the tests on the installed postgres. This is exceedingly
useful when validating the behaviour of extensions.


^ permalink  raw  reply  [nested|flat] 16+ messages in thread

* Re: missing perl test modules in postgresqlXX-devel ?
  2020-11-05 18:02 missing perl test modules in postgresqlXX-devel ? Jehan-Guillaume de Rorthais <[email protected]>
  2020-11-09 02:29 ` Re: missing perl test modules in postgresqlXX-devel ? Craig Ringer <[email protected]>
  2020-11-09 02:33   ` Re: missing perl test modules in postgresqlXX-devel ? Craig Ringer <[email protected]>
  2020-11-09 10:50     ` Re: missing perl test modules in postgresqlXX-devel ? Jehan-Guillaume de Rorthais <[email protected]>
  2020-11-10 00:53       ` Re: missing perl test modules in postgresqlXX-devel ? Craig Ringer <[email protected]>
@ 2020-11-10 13:41         ` Jehan-Guillaume de Rorthais <[email protected]>
  0 siblings, 0 replies; 16+ messages in thread

From: Jehan-Guillaume de Rorthais @ 2020-11-10 13:41 UTC (permalink / raw)
  To: Craig Ringer <[email protected]>; +Cc: pgsql-pkg-yum

On Tue, 10 Nov 2020 08:53:40 +0800
Craig Ringer <[email protected]> wrote:

> On Mon, Nov 9, 2020 at 6:50 PM Jehan-Guillaume de Rorthais <[email protected]>
> wrote:
> 
> >
> > I am currently writing TAP tests for check_pgactivity and rely on
> > PostgresNode
> > and friends to write and run them. They are very valuable and saves a lot
> > of
> > time.
> >  
> 
> I'm really glad. I have put a fair bit of effort into getting the test
> infra installed as part of "make install" so it gets packaged.

Then, I have to thank you very much :)

> Next I need to push for consistent -test packages for rpms and debs that
> bundle the actual test .sql, .out, .spec, and t/*.pl files needed to
> actually run the tests on the installed postgres. This is exceedingly
> useful when validating the behaviour of extensions.

Indeed.

Thank you for this effort!





^ permalink  raw  reply  [nested|flat] 16+ messages in thread

* Re: missing perl test modules in postgresqlXX-devel ?
  2020-11-05 18:02 missing perl test modules in postgresqlXX-devel ? Jehan-Guillaume de Rorthais <[email protected]>
  2020-11-09 02:29 ` Re: missing perl test modules in postgresqlXX-devel ? Craig Ringer <[email protected]>
@ 2020-11-09 10:40   ` Jehan-Guillaume de Rorthais <[email protected]>
  2020-11-10 05:57     ` Re: missing perl test modules in postgresqlXX-devel ? Craig Ringer <[email protected]>
  1 sibling, 1 reply; 16+ messages in thread

From: Jehan-Guillaume de Rorthais @ 2020-11-09 10:40 UTC (permalink / raw)
  To: Craig Ringer <[email protected]>; +Cc: pgsql-pkg-yum

Hello Craig,

On Mon, 9 Nov 2020 10:29:16 +0800
Craig Ringer <[email protected]> wrote:

> On Fri, Nov 6, 2020 at 2:02 AM Jehan-Guillaume de Rorthais <[email protected]>
> wrote:
> > I noticed the perl test modules from PostgreSQL source tree, eg.
> > PostgresNode, are not installed with package "postgresqlXX-devel". Only
> > pg_regress is installed.
> >
> > Looking at the web, I can find old memories [1] where postgresql12-devel
> > installed them in /usr/pgsql-12/lib/pgxs/src/test/perl/
> >  
> 
> We really need some consistency and cross checks between the RPMs and debs.
> But it seems fine to me in the -12 and -13 packages for Fedora 32. So
> please provide some more specifics about exactly what OS, yum repo
> configuration, metadata version, etc you are using.

Oh, sorry, I didn't thought about looking for other packages from other distro
and versions before writing my email. I should I thought about that as, as I
wrote in my email, I found some old fedora packages providing the files...

So it looks like at least EL7 packages are broken/different from fedora 32. Here
are some more informations from a CentOS Linux 7 (vagrant box "centos/7"):

  # repoquery -f /usr/pgsql-12/bin/postgres
  postgresql12-server-0:12.2-1PGDG.rhel7.x86_64
  postgresql12-server-0:12.1-2PGDG.rhel7.x86_64
  postgresql12-server-0:12.2-2PGDG.rhel7.x86_64
  postgresql12-server-0:12.3-1PGDG.rhel7.x86_64
  postgresql12-server-0:12.3-5PGDG.rhel7.x86_64
  postgresql12-server-0:12.4-1PGDG.rhel7.x86_64

  # repoquery -f /usr/pgsql-13/bin/postgres
  postgresql13-server-0:13.0-1PGDG.rhel7.x86_64

  # repoquery -f /usr/pgsql-12/lib/pgxs/src/test/perl/PostgresNode.pm
  (nothing)

  # repoquery -f /usr/pgsql-13/lib/pgxs/src/test/perl/PostgresNode.pm
  (nothing)

  # head -2 /etc/os-release
  NAME="CentOS Linux"
  VERSION="7 (Core)"

  # yum repolist enabled pgdg* 2>&1|colrm 22 72
  repo id                status
  pgdg-common/7/x86_64   350
  pgdg10/7/x86_64        770
  pgdg11/7/x86_64        813
  pgdg12/7/x86_64        395
  pgdg13/7/x86_64        127
  pgdg95/7/x86_64        679
  pgdg96/7/x86_64        740
  repolist: 3874


Thank you,

/Jehan-Guillaume de Rorthais





^ permalink  raw  reply  [nested|flat] 16+ messages in thread

* Re: missing perl test modules in postgresqlXX-devel ?
  2020-11-05 18:02 missing perl test modules in postgresqlXX-devel ? Jehan-Guillaume de Rorthais <[email protected]>
  2020-11-09 02:29 ` Re: missing perl test modules in postgresqlXX-devel ? Craig Ringer <[email protected]>
  2020-11-09 10:40   ` Re: missing perl test modules in postgresqlXX-devel ? Jehan-Guillaume de Rorthais <[email protected]>
@ 2020-11-10 05:57     ` Craig Ringer <[email protected]>
  2020-11-10 13:56       ` Re: missing perl test modules in postgresqlXX-devel ? Jehan-Guillaume de Rorthais <[email protected]>
  0 siblings, 1 reply; 16+ messages in thread

From: Craig Ringer @ 2020-11-10 05:57 UTC (permalink / raw)
  To: Jehan-Guillaume de Rorthais <[email protected]>; +Cc: pgsql-pkg-yum

On Mon, Nov 9, 2020 at 6:40 PM Jehan-Guillaume de Rorthais <[email protected]>
wrote:

>
> So it looks like at least EL7 packages are broken/different from fedora
> 32. Here
> are some more informations from a CentOS Linux 7 (vagrant box "centos/7"):
>
>   # repoquery -f /usr/pgsql-12/bin/postgres
>   postgresql12-server-0:12.2-1PGDG.rhel7.x86_64
>   postgresql12-server-0:12.1-2PGDG.rhel7.x86_64
>   postgresql12-server-0:12.2-2PGDG.rhel7.x86_64
>   postgresql12-server-0:12.3-1PGDG.rhel7.x86_64
>   postgresql12-server-0:12.3-5PGDG.rhel7.x86_64
>   postgresql12-server-0:12.4-1PGDG.rhel7.x86_64
>
>   # repoquery -f /usr/pgsql-13/bin/postgres
>   postgresql13-server-0:13.0-1PGDG.rhel7.x86_64
>
>   # repoquery -f /usr/pgsql-12/lib/pgxs/src/test/perl/PostgresNode.pm
>   (nothing)
>
>   # repoquery -f /usr/pgsql-13/lib/pgxs/src/test/perl/PostgresNode.pm
>   (nothing)
>

Yeah, that seems wrong.

You can find concrete (non-symlink) spec files for current releases with:

     find -type f -regex '.*/postgresql-\(9\.[456]\|1[0-9]\).spec'

e.g.

    rpm/redhat/master/non-common/postgresql-13/master/postgresql-13.spec

You'll note that while they're shared across distro variants, there's a
separate specfile for each major release.

In rpm/redhat/master/non-common/postgresql-13/master/postgresql-13.spec
you'll see

    %files devel -f pg_devel.lst
    ....
    %{pgbaseinstdir}/lib/pgxs/*
    ....

so anything installed in pgxs/* should be packaged.

TAP tests get installed if they are enabled. They are enabled if
--enable-tap-tests is passed to configure. That is controlled by the stanza

    %if %enabletaptests
            --enable-tap-tests \
    %endif

which in turn is controlled by

    %if 0%{?rhel} || 0%{?suse_version} >= 1315
    %{!?enabletaptests:%global enabletaptests 0}
    %else
    %{!?enabletaptests:%global enabletaptests 1}
    %endif

so apparently the TAP tests aren't built/enabled for any RHEL/CentOS
versions in -13. The same is true for 10 and up, at least.

That's ... surprising. There's no comment to indicate why.

Git logs suggest the cause is commit 511834297 "Disable tap tests  on RHEL
7" . I think the package in question is perl-Test-Simple a.k.a
'perl(Test::Simple)'.

It looks like the test should be updated to enable them for RHEL 8 at least.

I don't really feel like wrestling builds for an obsolete OS version to get
these packaged for EL-7 though.


^ permalink  raw  reply  [nested|flat] 16+ messages in thread

* Re: missing perl test modules in postgresqlXX-devel ?
  2020-11-05 18:02 missing perl test modules in postgresqlXX-devel ? Jehan-Guillaume de Rorthais <[email protected]>
  2020-11-09 02:29 ` Re: missing perl test modules in postgresqlXX-devel ? Craig Ringer <[email protected]>
  2020-11-09 10:40   ` Re: missing perl test modules in postgresqlXX-devel ? Jehan-Guillaume de Rorthais <[email protected]>
  2020-11-10 05:57     ` Re: missing perl test modules in postgresqlXX-devel ? Craig Ringer <[email protected]>
@ 2020-11-10 13:56       ` Jehan-Guillaume de Rorthais <[email protected]>
  2020-11-11 03:29         ` Re: missing perl test modules in postgresqlXX-devel ? Craig Ringer <[email protected]>
  0 siblings, 1 reply; 16+ messages in thread

From: Jehan-Guillaume de Rorthais @ 2020-11-10 13:56 UTC (permalink / raw)
  To: Craig Ringer <[email protected]>; +Cc: pgsql-pkg-yum

On Tue, 10 Nov 2020 13:57:22 +0800
Craig Ringer <[email protected]> wrote:

> [...]
> 
> so apparently the TAP tests aren't built/enabled for any RHEL/CentOS
> versions in -13. The same is true for 10 and up, at least.
> 
> That's ... surprising. There's no comment to indicate why.
> 
> Git logs suggest the cause is commit 511834297 "Disable tap tests  on RHEL
> 7" . I think the package in question is perl-Test-Simple a.k.a
> 'perl(Test::Simple)'.

That's surprising. Grep'ing postgresql source doesn't catch anything about
Test::Simple. TAP tests in PostgreSQL sources rely on Test::More which is part
of the official Perl core modules at least since 5.8.0... Do I miss something?

> It looks like the test should be updated to enable them for RHEL 8 at least.
> 
> I don't really feel like wrestling builds for an obsolete OS version to get
> these packaged for EL-7 though.

EL7 is still very popular. A lot of new upgrade/packages are still going to
EL7, at least for maintenance.

Regards,





^ permalink  raw  reply  [nested|flat] 16+ messages in thread

* Re: missing perl test modules in postgresqlXX-devel ?
  2020-11-05 18:02 missing perl test modules in postgresqlXX-devel ? Jehan-Guillaume de Rorthais <[email protected]>
  2020-11-09 02:29 ` Re: missing perl test modules in postgresqlXX-devel ? Craig Ringer <[email protected]>
  2020-11-09 10:40   ` Re: missing perl test modules in postgresqlXX-devel ? Jehan-Guillaume de Rorthais <[email protected]>
  2020-11-10 05:57     ` Re: missing perl test modules in postgresqlXX-devel ? Craig Ringer <[email protected]>
  2020-11-10 13:56       ` Re: missing perl test modules in postgresqlXX-devel ? Jehan-Guillaume de Rorthais <[email protected]>
@ 2020-11-11 03:29         ` Craig Ringer <[email protected]>
  2020-11-12 10:36           ` Re: missing perl test modules in postgresqlXX-devel ? Jehan-Guillaume de Rorthais <[email protected]>
  0 siblings, 1 reply; 16+ messages in thread

From: Craig Ringer @ 2020-11-11 03:29 UTC (permalink / raw)
  To: Jehan-Guillaume de Rorthais <[email protected]>; +Cc: pgsql-pkg-yum

On Tue, Nov 10, 2020 at 9:56 PM Jehan-Guillaume de Rorthais <[email protected]>
wrote:

> On Tue, 10 Nov 2020 13:57:22 +0800
> Craig Ringer <[email protected]> wrote:
>
> > [...]
> >
> > so apparently the TAP tests aren't built/enabled for any RHEL/CentOS
> > versions in -13. The same is true for 10 and up, at least.
> >
> > That's ... surprising. There's no comment to indicate why.
> >
> > Git logs suggest the cause is commit 511834297 "Disable tap tests  on
> RHEL
> > 7" . I think the package in question is perl-Test-Simple a.k.a
> > 'perl(Test::Simple)'.
>
> That's surprising. Grep'ing postgresql source doesn't catch anything about
> Test::Simple. TAP tests in PostgreSQL sources rely on Test::More which is
> part
> of the official Perl core modules at least since 5.8.0... Do I miss
> something?
>

Yep.

Perl test frameworks are an insane messy tangle of WTFery, so it's not
surprising.

Test::More became part of Test::Simple at some point. When you "cpanm
Test::More" you get "Test::Simple" installed:

$ cpanm --test-only Test::More
--> Working on Test::More
Fetching
http://www.cpan.org/authors/id/E/EX/EXODIST/Test-Simple-1.302183.tar.gz ...
OK
Configuring Test-Simple-1.302183 ... OK
Building and testing Test-Simple-1.302183 ...

Then there's this horrid tangle of Test2:: packages, TAP:: packages, and
more all jumbled up into it. And now we're apparently supposed to
transition to Test2::Suite instead, at some point, somehow...

Anyway, we should probably be declaring

    Requires 'perl(Test::More)'

instead of

    Requires perl-Test-Simple

because that tells the package manager we're asking for a specific Perl
module, rather than a specific package containing a Perl module.

$ sudo dnf -y install 'perl(Test::More)'
Package perl-Test-Simple-3:1.302174-1.fc32.noarch is already installed.
Dependencies resolved.
Nothing to do.

This is true on centos7 too:

$ docker run -t centos:7 yum -y install 'perl(Test::More)'
...
---> Package perl-Test-Simple.noarch 0:0.98-243.el7 will be installed
...
Installed:
  perl-Test-Simple.noarch 0:0.98-243.el7



but I'm not sure about RHEL7 official.

> It looks like the test should be updated to enable them for RHEL 8 at
> least.
> >
> > I don't really feel like wrestling builds for an obsolete OS version to
> get
> > these packaged for EL-7 though.
>
> EL7 is still very popular. A lot of new upgrade/packages are still going to
> EL7, at least for maintenance.
>

Yep.

I know, I maintain some. But I don't have nearly enough clones to do
everything I want to do, so some things have to slip.

Would you mind firing up a RHEL7 AWS EC2 instance and checking if

    yum -y install 'perl(Test::More)'

runs?

If so, we can probably restore the dependency, and then restore
--enable-tap-tests support.

Alternatively we might be able to build with --enable-tap-tests and make
'perl(Test::More)' a build-time-only dependency when built on EL7. This
means that TAP test running would have an undeclared dependency that won't
actually work on EL7 without a separate package install step, which kind of
sucks. But so long as it doesn't break other functionality in
Makefile.global it's probably actually OK.

If EL7's yum and rpm aren't too stupid to cope, we can possibly use a
Recommends: dependency for 'perl(Test::More)' there.

I'd need you to run some tests on a real RHEL 7 VM or host if you want to
pursue this. I can help but can't take this on right now. I'll be able to
send you a toy specfile to use rpmbuilds commands with to check things.


^ permalink  raw  reply  [nested|flat] 16+ messages in thread

* Re: missing perl test modules in postgresqlXX-devel ?
  2020-11-05 18:02 missing perl test modules in postgresqlXX-devel ? Jehan-Guillaume de Rorthais <[email protected]>
  2020-11-09 02:29 ` Re: missing perl test modules in postgresqlXX-devel ? Craig Ringer <[email protected]>
  2020-11-09 10:40   ` Re: missing perl test modules in postgresqlXX-devel ? Jehan-Guillaume de Rorthais <[email protected]>
  2020-11-10 05:57     ` Re: missing perl test modules in postgresqlXX-devel ? Craig Ringer <[email protected]>
  2020-11-10 13:56       ` Re: missing perl test modules in postgresqlXX-devel ? Jehan-Guillaume de Rorthais <[email protected]>
  2020-11-11 03:29         ` Re: missing perl test modules in postgresqlXX-devel ? Craig Ringer <[email protected]>
@ 2020-11-12 10:36           ` Jehan-Guillaume de Rorthais <[email protected]>
  2020-11-13 05:38             ` Re: missing perl test modules in postgresqlXX-devel ? Craig Ringer <[email protected]>
  0 siblings, 1 reply; 16+ messages in thread

From: Jehan-Guillaume de Rorthais @ 2020-11-12 10:36 UTC (permalink / raw)
  To: Craig Ringer <[email protected]>; +Cc: pgsql-pkg-yum

On Wed, 11 Nov 2020 11:29:49 +0800
Craig Ringer <[email protected]> wrote:

> On Tue, Nov 10, 2020 at 9:56 PM Jehan-Guillaume de Rorthais <[email protected]>
> wrote:
> 
> > On Tue, 10 Nov 2020 13:57:22 +0800
> > Craig Ringer <[email protected]> wrote:
> >  
> > > [...]
> > >
> > > so apparently the TAP tests aren't built/enabled for any RHEL/CentOS
> > > versions in -13. The same is true for 10 and up, at least.
> > >
> > > That's ... surprising. There's no comment to indicate why.
> > >
> > > Git logs suggest the cause is commit 511834297 "Disable tap tests  on  
> > RHEL  
> > > 7" . I think the package in question is perl-Test-Simple a.k.a
> > > 'perl(Test::Simple)'.  
> >
> > That's surprising. Grep'ing postgresql source doesn't catch anything about
> > Test::Simple. TAP tests in PostgreSQL sources rely on Test::More which is
> > part
> > of the official Perl core modules at least since 5.8.0... Do I miss
> > something?
> >  
> 
> Yep.
> 
> Perl test frameworks are an insane messy tangle of WTFery, so it's not
> surprising.
> 
> Test::More became part of Test::Simple at some point.

Oh, I didn't noticed that.


> [...] Anyway, we should probably be declaring
> 
>     Requires 'perl(Test::More)'
> 
> instead of
> 
>     Requires perl-Test-Simple

I believe you are right.


> [...}
> Would you mind firing up a RHEL7 AWS EC2 instance and checking if
> 
>     yum -y install 'perl(Test::More)'
> 
> runs?

I fired the vagrant generic/rhel7 box and registered it using my dev account:

  $ head -2 /etc/os-release 
  NAME="Red Hat Enterprise Linux Server"
  VERSION="7.8 (Maipo)"

  $ sudo -i yum -y install 'perl(Test::More)'"
  [...]
  ---> Package perl-Test-Simple.noarch 0:0.98-243.el7 will be installed
  [...]
  Installed:
    perl-Test-Simple.noarch 0:0.98-243.el7

  $ source /etc/os-release
  $ export VERSION NAME
  $ perl -MTest::More -le '
    like $ENV{VERSION}, qr/7\./, "version is $ENV{VERSION}"; 
    like $ENV{NAME}, qr/Red Hat Enterprise/, "OS is $ENV{NAME}"; 
    done_testing'

  ok 1 - version is 7.8 (Maipo)
  ok 2 - OS is Red Hat Enterprise Linux Server
  1..2
  
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/packa...

I checked in RHEL 7 changelog and couldn't find anything about
removing/adding/deprecating this package.

I couldn't find the original discussion deciding to remove --enable-tap-tests
for RHEL packages after a quick look at archives, but it seems the package IS
actually available for RHEL 7. Is it really because of this package the perl
modules are not build RHEL?

> If so, we can probably restore the dependency, and then restore
> --enable-tap-tests support.
> 
> Alternatively we might be able to build with --enable-tap-tests and make
> 'perl(Test::More)' a build-time-only dependency when built on EL7. This
> means that TAP test running would have an undeclared dependency that won't
> actually work on EL7 without a separate package install step, which kind of
> sucks. But so long as it doesn't break other functionality in
> Makefile.global it's probably actually OK.
> 
> If EL7's yum and rpm aren't too stupid to cope, we can possibly use a
> Recommends: dependency for 'perl(Test::More)' there.

Since Test::More is available in EL7, it doesn't look necessary in my opinion.

> I'd need you to run some tests on a real RHEL 7 VM or host if you want to
> pursue this. I can help but can't take this on right now. I'll be able to
> send you a toy specfile to use rpmbuilds commands with to check things.

Sure, I'm available.

Regards,





^ permalink  raw  reply  [nested|flat] 16+ messages in thread

* Re: missing perl test modules in postgresqlXX-devel ?
  2020-11-05 18:02 missing perl test modules in postgresqlXX-devel ? Jehan-Guillaume de Rorthais <[email protected]>
  2020-11-09 02:29 ` Re: missing perl test modules in postgresqlXX-devel ? Craig Ringer <[email protected]>
  2020-11-09 10:40   ` Re: missing perl test modules in postgresqlXX-devel ? Jehan-Guillaume de Rorthais <[email protected]>
  2020-11-10 05:57     ` Re: missing perl test modules in postgresqlXX-devel ? Craig Ringer <[email protected]>
  2020-11-10 13:56       ` Re: missing perl test modules in postgresqlXX-devel ? Jehan-Guillaume de Rorthais <[email protected]>
  2020-11-11 03:29         ` Re: missing perl test modules in postgresqlXX-devel ? Craig Ringer <[email protected]>
  2020-11-12 10:36           ` Re: missing perl test modules in postgresqlXX-devel ? Jehan-Guillaume de Rorthais <[email protected]>
@ 2020-11-13 05:38             ` Craig Ringer <[email protected]>
  2020-11-13 09:47               ` Re: missing perl test modules in postgresqlXX-devel ? Jehan-Guillaume de Rorthais <[email protected]>
  2020-11-13 15:51               ` Re: missing perl test modules in postgresqlXX-devel ? Devrim Gündüz <[email protected]>
  0 siblings, 2 replies; 16+ messages in thread

From: Craig Ringer @ 2020-11-13 05:38 UTC (permalink / raw)
  To: Jehan-Guillaume de Rorthais <[email protected]>; +Cc: pgsql-pkg-yum

On Thu, Nov 12, 2020 at 6:36 PM Jehan-Guillaume de Rorthais <[email protected]>
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/packa...
>
>
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


^ permalink  raw  reply  [nested|flat] 16+ messages in thread

* Re: missing perl test modules in postgresqlXX-devel ?
  2020-11-05 18:02 missing perl test modules in postgresqlXX-devel ? Jehan-Guillaume de Rorthais <[email protected]>
  2020-11-09 02:29 ` Re: missing perl test modules in postgresqlXX-devel ? Craig Ringer <[email protected]>
  2020-11-09 10:40   ` Re: missing perl test modules in postgresqlXX-devel ? Jehan-Guillaume de Rorthais <[email protected]>
  2020-11-10 05:57     ` Re: missing perl test modules in postgresqlXX-devel ? Craig Ringer <[email protected]>
  2020-11-10 13:56       ` Re: missing perl test modules in postgresqlXX-devel ? Jehan-Guillaume de Rorthais <[email protected]>
  2020-11-11 03:29         ` Re: missing perl test modules in postgresqlXX-devel ? Craig Ringer <[email protected]>
  2020-11-12 10:36           ` Re: missing perl test modules in postgresqlXX-devel ? Jehan-Guillaume de Rorthais <[email protected]>
  2020-11-13 05:38             ` Re: missing perl test modules in postgresqlXX-devel ? Craig Ringer <[email protected]>
@ 2020-11-13 09:47               ` Jehan-Guillaume de Rorthais <[email protected]>
  1 sibling, 0 replies; 16+ messages in thread

From: Jehan-Guillaume de Rorthais @ 2020-11-13 09:47 UTC (permalink / raw)
  To: Craig Ringer <[email protected]>; +Cc: pgsql-pkg-yum

On Fri, 13 Nov 2020 13:38:05 +0800
Craig Ringer <[email protected]> wrote:

> On Thu, Nov 12, 2020 at 6:36 PM Jehan-Guillaume de Rorthais <[email protected]>
> wrote:
> > 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/packa...
> >
> >
> 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.

All these changes seem fine to me.

Thank you,





^ permalink  raw  reply  [nested|flat] 16+ messages in thread

* Re: missing perl test modules in postgresqlXX-devel ?
  2020-11-05 18:02 missing perl test modules in postgresqlXX-devel ? Jehan-Guillaume de Rorthais <[email protected]>
  2020-11-09 02:29 ` Re: missing perl test modules in postgresqlXX-devel ? Craig Ringer <[email protected]>
  2020-11-09 10:40   ` Re: missing perl test modules in postgresqlXX-devel ? Jehan-Guillaume de Rorthais <[email protected]>
  2020-11-10 05:57     ` Re: missing perl test modules in postgresqlXX-devel ? Craig Ringer <[email protected]>
  2020-11-10 13:56       ` Re: missing perl test modules in postgresqlXX-devel ? Jehan-Guillaume de Rorthais <[email protected]>
  2020-11-11 03:29         ` Re: missing perl test modules in postgresqlXX-devel ? Craig Ringer <[email protected]>
  2020-11-12 10:36           ` Re: missing perl test modules in postgresqlXX-devel ? Jehan-Guillaume de Rorthais <[email protected]>
  2020-11-13 05:38             ` Re: missing perl test modules in postgresqlXX-devel ? Craig Ringer <[email protected]>
@ 2020-11-13 15:51               ` Devrim Gündüz <[email protected]>
  2020-11-16 07:42                 ` Re: missing perl test modules in postgresqlXX-devel ? Craig Ringer <[email protected]>
  1 sibling, 1 reply; 16+ messages in thread

From: Devrim Gündüz @ 2020-11-13 15:51 UTC (permalink / raw)
  To: Craig Ringer <[email protected]>; Jehan-Guillaume de Rorthais <[email protected]>; +Cc: pgsql-pkg-yum


Hi,

On Fri, 2020-11-13 at 13:38 +0800, Craig Ringer wrote:
> Based on this, I think it's appropriate to modify the EL-7 spec file
> fo all Pg versions (example patch is for -10) something like the
> following.

We have unified spec file, so can you please send a patch that will
work on all platforms?

Thanks!

-- 
Devrim Gündüz
Open Source Solution Architect, Red Hat Certified Engineer
Twitter: @DevrimGunduz , @DevrimGunduzTR


Attachments:

  [application/pgp-signature] signature.asc (833B, 2-signature.asc)
  download

^ permalink  raw  reply  [nested|flat] 16+ messages in thread

* Re: missing perl test modules in postgresqlXX-devel ?
  2020-11-05 18:02 missing perl test modules in postgresqlXX-devel ? Jehan-Guillaume de Rorthais <[email protected]>
  2020-11-09 02:29 ` Re: missing perl test modules in postgresqlXX-devel ? Craig Ringer <[email protected]>
  2020-11-09 10:40   ` Re: missing perl test modules in postgresqlXX-devel ? Jehan-Guillaume de Rorthais <[email protected]>
  2020-11-10 05:57     ` Re: missing perl test modules in postgresqlXX-devel ? Craig Ringer <[email protected]>
  2020-11-10 13:56       ` Re: missing perl test modules in postgresqlXX-devel ? Jehan-Guillaume de Rorthais <[email protected]>
  2020-11-11 03:29         ` Re: missing perl test modules in postgresqlXX-devel ? Craig Ringer <[email protected]>
  2020-11-12 10:36           ` Re: missing perl test modules in postgresqlXX-devel ? Jehan-Guillaume de Rorthais <[email protected]>
  2020-11-13 05:38             ` Re: missing perl test modules in postgresqlXX-devel ? Craig Ringer <[email protected]>
  2020-11-13 15:51               ` Re: missing perl test modules in postgresqlXX-devel ? Devrim Gündüz <[email protected]>
@ 2020-11-16 07:42                 ` Craig Ringer <[email protected]>
  0 siblings, 0 replies; 16+ messages in thread

From: Craig Ringer @ 2020-11-16 07:42 UTC (permalink / raw)
  To: Devrim Gündüz <[email protected]>; +Cc: Jehan-Guillaume de Rorthais <[email protected]>; pgsql-pkg-yum

On Fri, Nov 13, 2020 at 11:51 PM Devrim Gündüz <[email protected]> wrote:

>
> Hi,
>
> On Fri, 2020-11-13 at 13:38 +0800, Craig Ringer wrote:
> > Based on this, I think it's appropriate to modify the EL-7 spec file
> > fo all Pg versions (example patch is for -10) something like the
> > following.
>
> We have unified spec file, so can you please send a patch that will
> work on all platforms?
>

I should've said "the unified spec file for pg 10" - the patch targets all
platforms.

I've attached one that's pre-applied to all version specs, with a better
commit message, so you can just "git am" and check it.

For future reference

  PATCHFILE=/path/to/the.patch
  for f in $( find . -type f -path
'./rpm/redhat/master/non-common/postgresql-1[0-9]/*/postgresql-*.spec' )
  do
    patch --no-backup-if-mismatch -p1 -i $PATCHFILE $f
  done

is very handy.

If you're concerned about this, the 'perl(Test::More)' dependency could be
made a weak dependency.

I didn't see a convenient docker-based build script in the pgrpms repo that
I could use to sanity check changes against a clean temporary
locally-generated buildserver image, so I haven't tested these. The
dockerfiles in docker/ look like they're intended as end-user containers.
I'll see if I can make a simple docker-rpm-builder wrapper (see
https://github.com/docker-rpm-builder/docker-rpm-builder#other-distributions-and-osx---installing-st...
).


Attachments:

  [text/x-patch] v1-0001-Enable-TAP-tests-and-package-TAP-postgres-modules.patch (7.4K, 3-v1-0001-Enable-TAP-tests-and-package-TAP-postgres-modules.patch)
  download | inline diff:
From 4d03e46b035c10605b50909bf31f53ea3343eeec Mon Sep 17 00:00:00 2001
From: Craig Ringer <[email protected]>
Date: Mon, 16 Nov 2020 12:04:42 +0800
Subject: [PATCH v1] Enable TAP tests and package TAP postgres modules for EL-7
 and EL-8

All RHEL had TAP tests disabled since commit 511834297 "Disable tap tests on
RHEL 7". This claimed that "Red Hat does not ship with the necessary deps",
they were only present on CentOS. The same commit added a dependency for
perl-Test-Simple, suggesting the issue may have related to Test::More, which is
part of Test::Simple, but it's not too clear.

Investigation of the current state by Jehan-Guillaume de Rorthais shows that
RHEL 7 (at least 7.8) does have Test::More at least if requested via the
preferred Perl module Provides syntax 'perl(Test::More)' per [1].

Accordingly, re-enable building with --enable-tap-tests on RHEL7. In the
process switch to the Perl module Provides syntax for modules 'perl(IPC::Run)'
and 'perl(Test::More)' instead of naming the rpm packages they are part of,
'perl-IPC-Run' and 'perl-Test-Simple' respectively. And merge the requirements
for Fedora and RHEL 7/8, since there's no apparent reason they should be
separate.

[1] https://www.postgresql.org/message-id/20201112113632.627b8749@firost
---
 .../postgresql-10/master/postgresql-10.spec        | 14 +++++---------
 .../postgresql-11/master/postgresql-11.spec        | 14 +++++---------
 .../postgresql-12/master/postgresql-12.spec        | 14 +++++---------
 .../postgresql-13/master/postgresql-13.spec        | 14 +++++---------
 .../postgresql-14/main/postgresql-14.spec          | 14 +++++---------
 5 files changed, 25 insertions(+), 45 deletions(-)

diff --git a/rpm/redhat/master/non-common/postgresql-10/master/postgresql-10.spec b/rpm/redhat/master/non-common/postgresql-10/master/postgresql-10.spec
index a5b6a015a..501e3884f 100644
--- 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
 
diff --git a/rpm/redhat/master/non-common/postgresql-11/master/postgresql-11.spec b/rpm/redhat/master/non-common/postgresql-11/master/postgresql-11.spec
index 4246532c7..63d59e3ed 100644
--- a/rpm/redhat/master/non-common/postgresql-11/master/postgresql-11.spec
+++ b/rpm/redhat/master/non-common/postgresql-11/master/postgresql-11.spec
@@ -11,7 +11,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}
@@ -416,17 +416,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
 
diff --git a/rpm/redhat/master/non-common/postgresql-12/master/postgresql-12.spec b/rpm/redhat/master/non-common/postgresql-12/master/postgresql-12.spec
index be62e1f9e..0617cef71 100644
--- a/rpm/redhat/master/non-common/postgresql-12/master/postgresql-12.spec
+++ b/rpm/redhat/master/non-common/postgresql-12/master/postgresql-12.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}
@@ -417,17 +417,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
 
diff --git a/rpm/redhat/master/non-common/postgresql-13/master/postgresql-13.spec b/rpm/redhat/master/non-common/postgresql-13/master/postgresql-13.spec
index 7f284a5f2..49afff9fa 100644
--- a/rpm/redhat/master/non-common/postgresql-13/master/postgresql-13.spec
+++ b/rpm/redhat/master/non-common/postgresql-13/master/postgresql-13.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}
@@ -386,17 +386,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
 
diff --git a/rpm/redhat/master/non-common/postgresql-14/main/postgresql-14.spec b/rpm/redhat/master/non-common/postgresql-14/main/postgresql-14.spec
index 644df2ebe..fbab2e44a 100644
--- a/rpm/redhat/master/non-common/postgresql-14/main/postgresql-14.spec
+++ b/rpm/redhat/master/non-common/postgresql-14/main/postgresql-14.spec
@@ -14,7 +14,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}
@@ -388,17 +388,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
 
-- 
2.26.2



^ permalink  raw  reply  [nested|flat] 16+ messages in thread


end of thread, other threads:[~2020-11-16 07:42 UTC | newest]

Thread overview: 16+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2020-11-05 18:02 missing perl test modules in postgresqlXX-devel ? Jehan-Guillaume de Rorthais <[email protected]>
2020-11-09 02:29 ` Craig Ringer <[email protected]>
2020-11-09 02:33   ` Craig Ringer <[email protected]>
2020-11-09 10:50     ` Jehan-Guillaume de Rorthais <[email protected]>
2020-11-09 19:45       ` Christoph Berg <[email protected]>
2020-11-10 00:53       ` Craig Ringer <[email protected]>
2020-11-10 13:41         ` Jehan-Guillaume de Rorthais <[email protected]>
2020-11-09 10:40   ` Jehan-Guillaume de Rorthais <[email protected]>
2020-11-10 05:57     ` Craig Ringer <[email protected]>
2020-11-10 13:56       ` Jehan-Guillaume de Rorthais <[email protected]>
2020-11-11 03:29         ` Craig Ringer <[email protected]>
2020-11-12 10:36           ` Jehan-Guillaume de Rorthais <[email protected]>
2020-11-13 05:38             ` Craig Ringer <[email protected]>
2020-11-13 09:47               ` Jehan-Guillaume de Rorthais <[email protected]>
2020-11-13 15:51               ` Devrim Gündüz <[email protected]>
2020-11-16 07:42                 ` Craig Ringer <[email protected]>

This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox