Re: Regression tests fail with musl libc because libpq.so can't be loaded

Wolfgang Walther <walther@technowledgy.de>

From: walther@technowledgy.de
To: Tom Lane <tgl@sss.pgh.pa.us>, Thomas Munro <thomas.munro@gmail.com>
Cc: Peter Eisentraut <peter@eisentraut.org>, Christophe Pettus <xof@thebuild.com>, Andrew Dunstan <andrew@dunslane.net>, PostgreSQL Bugs <pgsql-bugs@lists.postgresql.org>, Bruce Momjian <bruce@momjian.us>
Date: 2024-03-22T08:12:47Z
Lists: pgsql-bugs, pgsql-hackers

Commits

Same data as JSON: GET /api/v1/messages/:b64id/commits the thread's linked commits as JSON, with link sources. API reference →
  1. Allow "make check"-style testing to work with musl C library.

  2. Fix compiler warnings on MSYS2

Tom Lane:
> Thomas Munro <thomas.munro@gmail.com> writes:
>> Just a thought: if we want to go this way, do we need a new exec call?
>>   We already control the initial exec in pg_ctl.c.
> 
> I'm resistant to assuming the postmaster is launched through pg_ctl.
> systemd, for example, might well prefer not to do that, not to
> mention all the troglodytes still using 1990s launch scripts.

Right, the systemd example in the docs is not using pg_ctl.

But, it should be easily possible to have:
- pg_ctl call postgres with a padded argv0
- postgres call itself with padding, if it wasn't called with that already

This way, there would be no additional exec call when started through 
pg_ctl, but one more call when started directly.

Best,

Wolfgang