Re: PG vs macOS Mojave

Tom Lane <tgl@sss.pgh.pa.us>

From: Tom Lane <tgl@sss.pgh.pa.us>
To: Jakob Egger <jakob@eggerapps.at>
Cc: pgsql-hackers@lists.postgresql.org
Date: 2018-10-16T14:02:03Z
Lists: pgsql-hackers
Jakob Egger <jakob@eggerapps.at> writes:
> Am 25. Sep. 2018 um 06:49 schrieb Tom Lane <tgl@sss.pgh.pa.us>:
>> It's a bit scary to be adding -isysroot globally.

> This breaks building extensions with a different SDK than the server itself.

Hm, under what circumstances would that be safe or a good idea?

The concerns that strike my mind are mainly around the hazard that
configure's choices could be inappropriate for a build with a
different SDK.  Given that, though, wiring -isysroot into the
configure output doesn't seem all that insane.

It's possible that we could arrange things so that the generated
Makefile.global looks like

PG_SYSROOT = /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk 
CPPFLAGS =  -isysroot $(PG_SYSROOT)

instead of

CPPFLAGS =  -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk 

thus making it a bit simpler to override that path at build time.
But I'm not sure that that really moves the goalposts very far for you
in terms of ease-of-use, and anyway it might just be greasing the skids
to a non-working extension.

			regards, tom lane


Commits

  1. Yet further rethinking of build changes for macOS Mojave.

  2. Still further rethinking of build changes for macOS Mojave.

  3. Back off using -isysroot on Darwin.

  4. Make some fixes to allow building Postgres on macOS 10.14 ("Mojave").