Re: another look at macOS SIP

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Peter Eisentraut <peter(dot)eisentraut(at)2ndquadrant(dot)com>
Cc: pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: another look at macOS SIP
Date: 2019-09-10 17:26:42
Message-ID: 7146.1568136402@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Peter Eisentraut <peter(dot)eisentraut(at)2ndquadrant(dot)com> writes:
> I have figured out another solution to the problem that macOS SIP
> defeats the use of DYLD_LIBRARY_PATH for running the temp-install
> regression tests. It's not without problems either, but it might show a
> path forward.
> ...
> The precise issue is that /bin/sh filters out DYLD_* environment
> variables (presumably all, but at least the ones we care about) when it
> starts.

Yeah, that was pretty much what we'd speculated.

> I think the way forward here is to get rid of all uses of system() for
> calling between PostgreSQL programs.

We could do that perhaps, but how are you going to get make to not use
/bin/sh while spawning subprocesses? I don't think we want to also
reimplement make ...

> There is a minor second issue, namely that /usr/bin/perl also filters
> out DYLD_* environment variables. This can be worked around again by
> using a third-party installation of Perl.

This is not sounding better than just turning off SIP :-(

We could, however, probably fix things so that our Perl test scripts
re-establish those environment variables internally. We don't need
the perl processes themselves to load test libraries, just their
descendants.

Maybe a similar workaround is possible for the "make" issue?
I have a feeling it would be less flexible than what we have
today, though.

regards, tom lane

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Alvaro Herrera from 2ndQuadrant 2019-09-10 17:34:42 Re: Re: libpq host/hostaddr/conninfo inconsistencies
Previous Message Peter Eisentraut 2019-09-10 17:14:19 another look at macOS SIP