From: Peter Eisentraut <peter.eisentraut@enterprisedb.com>
To: pgsql-hackers <pgsql-hackers@postgresql.org>
Subject: meson: Fix support for empty darwin sysroot
Date: Wed, 22 Mar 2023 08:34:00 +0100
Message-ID: <60765bf0-5027-4b23-9f78-4a365d28823f@enterprisedb.com> (raw)
The -isysroot options should only be added if the sysroot resolved to a
nonempty string. This matches the behavior in src/template/darwin (also
documented in installation.sgml).
Attachments:0001-meson-Fix-support-for-empty-darwin-sysroot.patch (text/plain, 1.2K) download
From 6012fe86627db134aa48ed55f5d9086931b399e0 Mon Sep 17 00:00:00 2001
From: Peter Eisentraut <peter@eisentraut.org>
Date: Wed, 22 Mar 2023 08:05:45 +0100
Subject: [PATCH] meson: Fix support for empty darwin sysroot
The -isysroot options should only be added if the sysroot resolved to
a nonempty string. This matches the behavior in src/template/darwin
(also documented in installation.sgml).
---
meson.build | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/meson.build b/meson.buildindex 7f76a101ec..9fb7fda539 100644--- a/meson.build+++ b/meson.build@@ -233,8 +233,10 @@ elif host_system == 'darwin'
sysroot_args = [files('src/tools/darwin_sysroot'), get_option('darwin_sysroot')]
pg_sysroot = run_command(sysroot_args, check:true).stdout().strip()
message('darwin sysroot: @0@'.format(pg_sysroot))
- cflags += ['-isysroot', pg_sysroot]- ldflags += ['-isysroot', pg_sysroot]+ if pg_sysroot != ''+ cflags += ['-isysroot', pg_sysroot]+ ldflags += ['-isysroot', pg_sysroot]+ endif
# meson defaults to -Wl,-undefined,dynamic_lookup for modules, which we
# don't want because a) it's different from what we do for autoconf, b) it
# causes warnings starting in macOS Ventura
--
2.40.0
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 using the --to and --cc options:
reply via email
To: pgsql-hackers@postgresql.org
Cc: peter.eisentraut@enterprisedb.com
Subject: Re: meson: Fix support for empty darwin sysroot
In-Reply-To: <60765bf0-5027-4b23-9f78-4a365d28823f@enterprisedb.com>
* 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