Re: meson PGXS compatibility

Andres Freund <andres@anarazel.de>

From: Andres Freund <andres@anarazel.de>
To: pgsql-hackers@postgresql.org, Nazir Bilal Yavuz <byavuz81@gmail.com>, Peter Eisentraut <peter.eisentraut@enterprisedb.com>, Tom Lane <tgl@sss.pgh.pa.us>
Date: 2022-10-10T21:35:14Z
Lists: pgsql-hackers
Hi,

On 2022-10-05 13:07:10 -0700, Andres Freund wrote:
> 0004: solaris: Check for -Wl,-E directly instead of checking for gnu LD
> 
>   This allows us to get rid of the nontrivial detection of with_gnu_ld,
>   simplifying meson PGXS compatibility. It's also nice to delete libtool.m4.
> 
>   I don't like the SOLARIS_EXPORT_DYNAMIC variable I invented. If somebody has
>   a better idea...

A cleaner approach could be to add a LDFLAGS_BE and emit the -Wl,-E into it
from both configure and meson, solely based on whether -Wl,-E is supported.  I
haven't verified cygwin, but on our other platforms that seems to do the right
thing.

Greetings,

Andres Freund



Commits

  1. meson: Add basic PGXS compatibility

  2. autoconf: Move export_dynamic determination to configure

  3. autoconf: Don't AC_SUBST() LD in configure

  4. autoconf: Unify CFLAGS_SSE42 and CFLAGS_ARMV8_CRC32C

  5. autoconf: Rely on ar supporting index creation