pg.ddx.io  pgsql-hackers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Andrew Dunstan <andrew.dunstan@2ndquadrant.com>
To: Ashutosh Sharma <ashu.coek88@gmail.com>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: Robert Haas <robertmhaas@gmail.com>
Cc: Dave Page <dpage@pgadmin.org>
Cc: Sandeep Thakkar <sandeep.thakkar@enterprisedb.com>
Cc: pgsql-hackers@postgresql.org <pgsql-hackers@postgresql.org>
Subject: Re: pl/perl extension fails on Windows
Date: Thu, 27 Jul 2017 14:36:27 -0400
Message-ID: <ec40c41f-276c-1270-c0ce-6c3f2fe50be3@2ndQuadrant.com> (raw)
In-Reply-To: <CAE9k0Pnq50=jeeLMMEbhdcYvfXFEc0SVgyNG7MLBmz-Oubw1tA@mail.gmail.com>
References: <CANFyU97OVQ3+Mzfmt3MhuUm5NwPU=-FtbNH5Eb7nZL9ua8=rcA@mail.gmail.com>
	<6063dd4c-cd1e-d9d8-fa0d-3bddb1403c66@2ndQuadrant.com>
	<CAE9k0PkWhEeNS4b5bnoQLeZsnqe4zqkr=4GhN2Ybt1nSsBFk2g@mail.gmail.com>
	<184f1fb9-dfa2-ef2d-024b-7933486e018a@2ndQuadrant.com>
	<16093.1499956602@sss.pgh.pa.us>
	<bb3d3eb6-e310-471c-1d8c-d239ecaf52ad@2ndQuadrant.com>
	<7480.1499965218@sss.pgh.pa.us>
	<CAE9k0Pnvw63MLR=dT1NYdL_t_ptyFqW1ueJwixcsmobadpFWng@mail.gmail.com>
	<30585.1500480763@sss.pgh.pa.us>
	<CAE9k0PnQzRRYEGy1j51D6F-fZeHWoy2GAghewBORWNjwg44y5g@mail.gmail.com>
	<32468.1500498091@sss.pgh.pa.us>
	<CA+TgmoY=3ApjWL0Y0Z_qdDVuK_koP9H_euHMewG06ukWxBW2Cw@mail.gmail.com>
	<CA+TgmoYqTcE8Q-GsfHJvndQPit7iqf63YY=BtGhZM7+qGjfy+g@mail.gmail.com>
	<20729.1501039314@sss.pgh.pa.us>
	<CAE9k0Pkya48GWPF7CViFu7zrJeQGm7Jzs0Wvkx2O1yAsi7EPgQ@mail.gmail.com>
	<CAE9k0PnobqEa0YH48yYGTkQKL0wFh6-BsQEn-_XnBtcbLgRfKQ@mail.gmail.com>
	<22864.1501165302@sss.pgh.pa.us>
	<CAE9k0Pnq50=jeeLMMEbhdcYvfXFEc0SVgyNG7MLBmz-Oubw1tA@mail.gmail.com>
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-hackers>



On 07/27/2017 12:34 PM, Ashutosh Sharma wrote:
> On Thu, Jul 27, 2017 at 7:51 PM, Tom Lane <tgl@sss.pgh.pa.us
> <mailto:tgl@sss.pgh.pa.us>> wrote:
> > Ashutosh Sharma <ashu.coek88@gmail.com
> <mailto:ashu.coek88@gmail.com>> writes:
> >> Anyways, attached is the patch that corrects this issue. The patch now
> >> imports all the switches used by perl into plperl module but, after
> >> doing so, i am seeing some compilation errors on Windows. Following is
> >> the error observed,
> >
> >> SPI.obj : error LNK2019: unresolved external symbol PerlProc_setjmp
> >> referenced in function do_plperl_return_next
> >
> > That's certainly a mess, but how come that wasn't happening before?
>
> Earlier we were using Perl-5.20 version which i think didn't have
> handshaking mechanism. From perl-5.22 onwards, the functions like
> Perl_xs_handshake() or HS_KEY were introduced for handshaking purpose
> and to ensure that the handshaking between plperl and perl doesn't
> fail, we are now trying to import the switches used by  perl into
> plperl. As a result of this, macros like PERL_IMPLICIT_SYS is getting
> defined in plperl which eventually opens the following definitions
> from XSUB.h resulting in the compilation error.
>
>    499 #if defined(PERL_IMPLICIT_SYS) && !defined(PERL_CORE)
>     518 #    undef ioctl
>     519 #    undef getlogin
>     520*#    undef setjmp*
>     ...........
>     ...........
>
>     651 #    define times               PerlProc_times
>     652 #    define wait                PerlProc_wait
>     653 *#    define setjmp              PerlProc_setjmp
>
> *



What is the minimal set of extra defines required to sort out the
handshake fingerprint issue?

cheers

andrew

-- 
Andrew Dunstan                https://www.2ndQuadrant.com
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services



-- 
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers



view thread (94+ messages)  latest in thread

Message-ID: <ec40c41f-276c-1270-c0ce-6c3f2fe50be3@2ndQuadrant.com>
Permalink:  ../ec40c41f-276c-1270-c0ce-6c3f2fe50be3@2ndQuadrant.com/
Also on:    postgresql.org/message-id/ec40c41f-276c-1270-c0ce-6c3f2fe50be3@2ndQuadrant.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-hackers@postgresql.org
  Cc: andrew.dunstan@2ndquadrant.com, ashu.coek88@gmail.com, tgl@sss.pgh.pa.us, robertmhaas@gmail.com, dpage@pgadmin.org, sandeep.thakkar@enterprisedb.com
  Subject: Re: pl/perl extension fails on Windows
  In-Reply-To: <ec40c41f-276c-1270-c0ce-6c3f2fe50be3@2ndQuadrant.com>
  References: <CANFyU97OVQ3+Mzfmt3MhuUm5NwPU=-FtbNH5Eb7nZL9ua8=rcA@mail.gmail.com> <CAE9k0PkWhEeNS4b5bnoQLeZsnqe4zqkr=4GhN2Ybt1nSsBFk2g@mail.gmail.com> <184f1fb9-dfa2-ef2d-024b-7933486e018a@2ndQuadrant.com> <16093.1499956602@sss.pgh.pa.us> <bb3d3eb6-e310-471c-1d8c-d239ecaf52ad@2ndQuadrant.com> <7480.1499965218@sss.pgh.pa.us> <CAE9k0Pnvw63MLR=dT1NYdL_t_ptyFqW1ueJwixcsmobadpFWng@mail.gmail.com> <30585.1500480763@sss.pgh.pa.us> <CAE9k0PnQzRRYEGy1j51D6F-fZeHWoy2GAghewBORWNjwg44y5g@mail.gmail.com> <32468.1500498091@sss.pgh.pa.us> <CA+TgmoY=3ApjWL0Y0Z_qdDVuK_koP9H_euHMewG06ukWxBW2Cw@mail.gmail.com> <CA+TgmoYqTcE8Q-GsfHJvndQPit7iqf63YY=BtGhZM7+qGjfy+g@mail.gmail.com> <20729.1501039314@sss.pgh.pa.us> <CAE9k0Pkya48GWPF7CViFu7zrJeQGm7Jzs0Wvkx2O1yAsi7EPgQ@mail.gmail.com> <CAE9k0PnobqEa0YH48yYGTkQKL0wFh6-BsQEn-_XnBtcbLgRfKQ@mail.gmail.com> <22864.1501165302@sss.pgh.pa.us> <CAE9k0Pnq50=jeeLMMEbhdcYvfXFEc0SVgyNG7MLBmz-Oubw1tA@mail.gmail.com> <ec40c41f-276c-1270-c0ce-6c3f2fe50be3@2ndQuadrant.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

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