pg.ddx.io  pgsql-hackers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Andrew Dunstan <andrew@dunslane.net>
To: Andres Freund <andres@anarazel.de>
Cc: Tom Lane <tgl@sss.pgh.pa.us>
Cc: Peter Eisentraut <peter.eisentraut@enterprisedb.com>
Cc: pgsql-hackers <pgsql-hackers@postgresql.org>
Subject: Re: Strip -mmacosx-version-min options from plperl build
Date: Thu, 25 Aug 2022 18:04:34 -0400
Message-ID: <e64be5d0-e38a-8eae-b083-f977b5dfd4bc@dunslane.net> (raw)
In-Reply-To: <20220825214739.wfn6qrkkinfex5c3@awork3.anarazel.de>
References: <2369869.1660830828@sss.pgh.pa.us>
	<9518842c-6844-0c99-85ec-ec43fba3115f@enterprisedb.com>
	<843fbed9-0749-bba4-b6b0-e3e7d1244b0d@enterprisedb.com>
	<1009406.1661347818@sss.pgh.pa.us>
	<65922608-fe34-fee0-a0be-82b6cd7daaea@dunslane.net>
	<1181344.1661381760@sss.pgh.pa.us>
	<27e1214f-26e8-7970-ad08-6da1bccdf985@dunslane.net>
	<c4afec71-ba16-c589-b094-66c2514afa4c@enterprisedb.com>
	<1465158.1661434999@sss.pgh.pa.us>
	<a9c57fe2-085d-7037-4178-f821c8148159@dunslane.net>
	<20220825214739.wfn6qrkkinfex5c3@awork3.anarazel.de>


On 2022-08-25 Th 17:47, Andres Freund wrote:
> Hi,
>
> On 2022-08-25 17:39:35 -0400, Andrew Dunstan wrote:
>> On 2022-08-25 Th 09:43, Tom Lane wrote:
>>> Peter Eisentraut <peter.eisentraut@enterprisedb.com> writes:
>>>>>> In short: if the Cygwin Perl headers redefine PGDLLEXPORT (unlikely)
>>>>>> or somehow #define "__attribute__()" or "visibility()" into no-ops
>>>>>> (perhaps more likely) then we could explain this failure, and that
>>>>>> would also explain why it doesn't fail elsewhere.
>>>> This could be checked by running plperl.c through the preprocessor 
>>>> (replace gcc -c plperl.c -o plperl.o by gcc -E plperl.c -o plperl.i) and 
>>>> seeing what becomes of those symbols.
>>> Yeah, that was what I was going to suggest: grep the "-E" output for
>>> _PG_init and Pg_magic_func and confirm what their extern declarations
>>> look like.
>>
>> $ egrep '_PG_init|Pg_magic_func'  plperl.i
>> extern __attribute__((visibility("default"))) void _PG_init(void);
>> extern __attribute__((visibility("default"))) const Pg_magic_struct
>> *Pg_magic_func(void); const Pg_magic_struct * Pg_magic_func(void) {
>> static const Pg_magic_struct Pg_magic_data = { sizeof(Pg_magic_struct),
>> 160000 / 100, 100, 32, 64,
>> _PG_init(void)
> Could you show objdump -t of the library? Perhaps once with the flags as now,
> and once relinking with the "old" flags that we're now omitting?


current:


$ objdump -t plperl.dll | egrep '_PG_init|Pg_magic_func'
[103](sec  1)(fl 0x00)(ty  20)(scl   2) (nx 0) 0x00000000000040a0
Pg_magic_func
[105](sec  1)(fl 0x00)(ty  20)(scl   2) (nx 0) 0x00000000000040b0 _PG_init


from July 11th build:


$ objdump -t plperl.dll | egrep '_PG_init|Pg_magic_func'
[101](sec  1)(fl 0x00)(ty  20)(scl   2) (nx 0) 0x00000000000040d0
Pg_magic_func
[103](sec  1)(fl 0x00)(ty  20)(scl   2) (nx 0) 0x00000000000040e0 _PG_init


cheers


andrew

--
Andrew Dunstan
EDB: https://www.enterprisedb.com






view thread (33+ messages)  latest in thread

Message-ID: <e64be5d0-e38a-8eae-b083-f977b5dfd4bc@dunslane.net>
Permalink:  ../e64be5d0-e38a-8eae-b083-f977b5dfd4bc@dunslane.net/
Also on:    postgresql.org/message-id/e64be5d0-e38a-8eae-b083-f977b5dfd4bc@dunslane.net

 · 

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@dunslane.net, andres@anarazel.de, tgl@sss.pgh.pa.us, peter.eisentraut@enterprisedb.com
  Subject: Re: Strip -mmacosx-version-min options from plperl build
  In-Reply-To: <e64be5d0-e38a-8eae-b083-f977b5dfd4bc@dunslane.net>
  References: <2369869.1660830828@sss.pgh.pa.us> <9518842c-6844-0c99-85ec-ec43fba3115f@enterprisedb.com> <843fbed9-0749-bba4-b6b0-e3e7d1244b0d@enterprisedb.com> <1009406.1661347818@sss.pgh.pa.us> <65922608-fe34-fee0-a0be-82b6cd7daaea@dunslane.net> <1181344.1661381760@sss.pgh.pa.us> <27e1214f-26e8-7970-ad08-6da1bccdf985@dunslane.net> <c4afec71-ba16-c589-b094-66c2514afa4c@enterprisedb.com> <1465158.1661434999@sss.pgh.pa.us> <a9c57fe2-085d-7037-4178-f821c8148159@dunslane.net> <20220825214739.wfn6qrkkinfex5c3@awork3.anarazel.de> <e64be5d0-e38a-8eae-b083-f977b5dfd4bc@dunslane.net>

* 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