Re: pgsql: Fix msvc builds for ActivePerl > 5.24

From: Noah Misch <noah(at)leadboat(dot)com>
To: Magnus Hagander <magnus(at)hagander(dot)net>
Cc: pgsql-committers(at)postgresql(dot)org
Subject: Re: pgsql: Fix msvc builds for ActivePerl > 5.24
Date: 2018-03-03 08:00:21
Message-ID: 20180303080021.GA1758858@rfd.leadboat.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-committers

On Fri, Mar 02, 2018 at 11:42:32AM +0000, Magnus Hagander wrote:
> Fix msvc builds for ActivePerl > 5.24

> --- a/src/tools/msvc/Mkvcbuild.pm
> +++ b/src/tools/msvc/Mkvcbuild.pm
> @@ -524,9 +524,11 @@ sub mkvcbuild
> my $perl_path = $solution->{options}->{perl} . '\lib\CORE\*perl*';
>
> # ActivePerl 5.16 provided perl516.lib; 5.18 provided libperl518.a
> + # Starting with ActivePerl 5.24, both perlnn.lib and libperlnn.a are provided.
> + # In this case, prefer .lib.

Sounds reasonable, but ...

> my @perl_libs =
> grep { /perl\d+\.lib$|libperl\d+\.a$/ } glob($perl_path);
> - if (@perl_libs == 1)
> + if (@perl_libs > 0)
> {
> $plperl->AddLibrary($perl_libs[0]);
> }

... the behavior doesn't match the comment. By default, glob() sorts by ASCII
value, so @perl_libs = qw(libperl524.a perl524.lib).

In response to

Responses

Browse pgsql-committers by date

  From Date Subject
Next Message Peter Eisentraut 2018-03-03 13:56:03 pgsql: In SSL tests, restart after pg_hba.conf changes
Previous Message Peter Eisentraut 2018-03-03 06:41:56 pgsql: Add PG_TEST_EXTRA to control optional test suites