Re: pgsql: tests: Add a test C++ extension module - Mailing list pgsql-hackers

From Jelte Fennema-Nio
Subject Re: pgsql: tests: Add a test C++ extension module
Date
Msg-id CAGECzQTujhsQ8amxgoABotQ9xQL62SJpuq=wfEzozTk+6zmAYw@mail.gmail.com
Whole thread Raw
In response to Re: pgsql: tests: Add a test C++ extension module  (Robert Haas <robertmhaas@gmail.com>)
Responses Re: pgsql: tests: Add a test C++ extension module
Re: pgsql: tests: Add a test C++ extension module
List pgsql-hackers
On Wed, 21 Jan 2026 at 21:25, Robert Haas <robertmhaas@gmail.com> wrote:
>
> On Tue, Jan 20, 2026 at 10:43 AM Peter Eisentraut <peter@eisentraut.org> wrote:
> > tests: Add a test C++ extension module
>
> This patch caused my usual build process to fail. I have been setting
> CC='ccache clang' in my environment, and I was able to fix make it
> work again by also setting CXX='ccache clang'. Before that, I was
> getting my macPorts version of clang (21.1.2) for C source files but
> the OS version of clang (15.0.0) for c++ files. But I still don't
> really understand how that caused this failure, which doesn't look
> like it has anything to do with mixing compilers:

Seems like the same error as Peter Smith. So I guess clang 15 doesn't
use C++11 by default. Did you try if my proposed patch solves it?
Another way of fixing your problem would have been:
CXX='/path/to/os-version/clang -std=gnu++11'



pgsql-hackers by date:

Previous
From: Corey Huinker
Date:
Subject: Re: Import Statistics in postgres_fdw before resorting to sampling.
Next
From: Kirill Reshke
Date:
Subject: Re: Fix crash during recovery when redo segment is missing