Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

Commit 4c15327

Browse files
committed
Bump minimum Perl version to 5.14
The oldest vendor-shipped Perl in the buildfarm is 5.14.2, which is the last version that Debian Wheezy shipped. That OS is EOL, but we keep it running because there is no other convenient way to test certain non-mainstream 32-bit platforms. There is no bugfix in the 5.14.2 release that is required, and yet it's also not the latest minor release -- that would be 5.14.4. To clarify the situation, we have thus arranged the buildfarm to test 5.14.0. That allows configure scripts and documentation to state 5.14 without fine print. The MSVC build didn't check the version, since our previous minimum 5.8.3 was considered too old to check for on Windows. We will need a check for Windows sometime during the v16 cycle, but that could be rendered moot by the impending Meson conversion, so it seems safe to just document the requirement for now. Reviewed by Tom Lane Discussion: https://www.postgresql.org/message-id/20220902181553.ev4pgzhubhdkguuv@awork3.anarazel.de
1 parent ecaf7c5 commit 4c15327

File tree

9 files changed

+12
-19
lines changed

9 files changed

+12
-19
lines changed

config/perl.m4

+2-2
Original file line numberDiff line numberDiff line change
@@ -11,11 +11,11 @@ if test "$PERL"; then
1111
pgac_perl_version=`$PERL -v 2>/dev/null | sed -n ['s/This is perl.*v[a-z ]*\([0-9]\.[0-9][0-9.]*\).*$/\1/p']`
1212
AC_MSG_NOTICE([using perl $pgac_perl_version])
1313
if echo "$pgac_perl_version" | sed ['s/[.a-z_]/ /g'] | \
14-
$AWK '{ if ([$]1 == 5 && ([$]2 > 8 || ($[2] == 8 && [$]3 >= 3))) exit 1; else exit 0;}'
14+
$AWK '{ if ([$]1 == 5 && ([$]2 >= 14)) exit 1; else exit 0;}'
1515
then
1616
AC_MSG_WARN([
1717
*** The installed version of Perl, $PERL, is too old to use with PostgreSQL.
18-
*** Perl version 5.8.3 or later is required, but this is $pgac_perl_version.])
18+
*** Perl version 5.14 or later is required, but this is $pgac_perl_version.])
1919
PERL=""
2020
fi
2121
fi

configure

+3-3
Original file line numberDiff line numberDiff line change
@@ -10491,14 +10491,14 @@ if test "$PERL"; then
1049110491
{ $as_echo "$as_me:${as_lineno-$LINENO}: using perl $pgac_perl_version" >&5
1049210492
$as_echo "$as_me: using perl $pgac_perl_version" >&6;}
1049310493
if echo "$pgac_perl_version" | sed 's/[.a-z_]/ /g' | \
10494-
$AWK '{ if ($1 == 5 && ($2 > 8 || ($2 == 8 && $3 >= 3))) exit 1; else exit 0;}'
10494+
$AWK '{ if ($1 == 5 && ($2 >= 14)) exit 1; else exit 0;}'
1049510495
then
1049610496
{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING:
1049710497
*** The installed version of Perl, $PERL, is too old to use with PostgreSQL.
10498-
*** Perl version 5.8.3 or later is required, but this is $pgac_perl_version." >&5
10498+
*** Perl version 5.14 or later is required, but this is $pgac_perl_version." >&5
1049910499
$as_echo "$as_me: WARNING:
1050010500
*** The installed version of Perl, $PERL, is too old to use with PostgreSQL.
10501-
*** Perl version 5.8.3 or later is required, but this is $pgac_perl_version." >&2;}
10501+
*** Perl version 5.14 or later is required, but this is $pgac_perl_version." >&2;}
1050210502
PERL=""
1050310503
fi
1050410504
fi

doc/src/sgml/install-windows.sgml

+1-1
Original file line numberDiff line numberDiff line change
@@ -190,7 +190,7 @@ $ENV{MSBFLAGS}="/m";
190190
or Cygwin Perl will not work. It must also be present in the PATH.
191191
Binaries can be downloaded from
192192
<ulink url="https://www.activestate.com"></ulink>
193-
(Note: version 5.8.3 or later is required,
193+
(Note: version 5.14 or later is required,
194194
the free Standard Distribution is sufficient).
195195
</para></listitem>
196196
</varlistentry>

doc/src/sgml/installation.sgml

+2-2
Original file line numberDiff line numberDiff line change
@@ -165,7 +165,7 @@ su - postgres
165165
<application>PL/Perl</application> you need a full
166166
<productname>Perl</productname> installation, including the
167167
<filename>libperl</filename> library and the header files.
168-
The minimum required version is <productname>Perl</productname> 5.8.3.
168+
The minimum required version is <productname>Perl</productname> 5.14.
169169
Since <application>PL/Perl</application> will be a shared
170170
library, the <indexterm><primary>libperl</primary></indexterm>
171171
<filename>libperl</filename> library must be a shared library
@@ -325,7 +325,7 @@ su - postgres
325325
<primary>perl</primary>
326326
</indexterm>
327327

328-
<application>Perl</application> 5.8.3 or later is needed to build from a Git checkout,
328+
<application>Perl</application> 5.14 or later is needed to build from a Git checkout,
329329
or if you changed the input files for any of the build steps that
330330
use Perl scripts. If building on Windows you will need
331331
<application>Perl</application> in any case. <application>Perl</application> is

src/pl/plperl/plc_perlboot.pl

-1
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@
66
use strict;
77
use warnings;
88

9-
use 5.008001;
109
use vars qw(%_SHARED $_TD);
1110

1211
PostgreSQL::InServer::Util::bootstrap();

src/test/perl/PostgreSQL/Test/Cluster.pm

+1-1
Original file line numberDiff line numberDiff line change
@@ -2780,7 +2780,7 @@ all values '' if not found. Does not differentiate between null and empty string
27802780
for fields, no field is ever undef.
27812781
27822782
The restart_lsn and confirmed_flush_lsn fields are returned verbatim, and also
2783-
as a 2-list of [highword, lowword] integer. Since we rely on Perl 5.8.8 we can't
2783+
as a 2-list of [highword, lowword] integer. Since we rely on Perl 5.14 we can't
27842784
"use bigint", it's from 5.20, and we can't assume we have Math::Bigint from CPAN
27852785
either.
27862786

src/test/perl/README

+3-7
Original file line numberDiff line numberDiff line change
@@ -78,10 +78,6 @@ Each test script should end with:
7878

7979
done_testing();
8080

81-
Test::More::like entails use of the qr// operator. Avoid Perl 5.8.8 bug
82-
#39185 by not using the "$" regular expression metacharacter in qr// when also
83-
using the "/m" modifier. Instead of "$", use "\n" or "(?=\n|\z)".
84-
8581
Test::Builder::Level controls how far up in the call stack a test will look
8682
at when reporting a failure. This should be incremented by any subroutine
8783
which directly or indirectly calls test routines from Test::More, such as
@@ -103,7 +99,7 @@ Portability
10399
-----------
104100

105101
Avoid using any bleeding-edge Perl features. We have buildfarm animals
106-
running Perl versions as old as 5.8.3, so your tests will be expected
102+
running Perl versions as old as 5.14, so your tests will be expected
107103
to pass on that.
108104

109105
Also, do not use any non-core Perl modules except IPC::Run. Or, if you
@@ -116,8 +112,8 @@ One way to test for compatibility with old Perl versions is to use
116112
perlbrew; see http://perlbrew.pl . After installing that, do
117113

118114
export PERLBREW_CONFIGURE_FLAGS='-de -Duseshrplib'
119-
perlbrew --force install 5.8.3
120-
perlbrew use 5.8.3
115+
perlbrew --force install 5.14.0
116+
perlbrew use 5.14.0
121117
perlbrew install-cpanm
122118
cpanm install Test::Simple@0.98
123119
cpanm install IPC::Run@0.79

src/tools/msvc/gendef.pl

-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@
33

44
use strict;
55
use warnings;
6-
use 5.8.0;
76
use List::Util qw(max);
87

98
my @def;

src/tools/pgindent/pgindent

-1
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@
44

55
use strict;
66
use warnings;
7-
use 5.008001;
87

98
use Cwd qw(abs_path getcwd);
109
use File::Find;

0 commit comments

Comments
 (0)