pgsql: headerscheck: Get CXXFLAGS from Makefile.global

From: Peter Eisentraut <peter(at)eisentraut(dot)org>
To: pgsql-committers(at)lists(dot)postgresql(dot)org
Subject: pgsql: headerscheck: Get CXXFLAGS from Makefile.global
Date: 2026-03-23 07:00:31
Message-ID: E1w4ZH4-0012wu-1Y@gemulon.postgresql.org
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-committers

headerscheck: Get CXXFLAGS from Makefile.global

headerscheck in C++ mode (cpluspluscheck) previously hardcoded
CXXFLAGS and documented that you might need to override them manually
from the environment. Now that we have better C++ support in the
build system, we can just get CXXFLAGS from Makefile.global, like we
do for other variables.

Furthermore, this is necessary in some configurations to make
cpluspluscheck work under meson, because under meson, some -I options
end up in CXXFLAGS where under make they would be in CPPFLAGS.
Therefore, getting the correct CXXFLAGS is required in those cases.

Reviewed-by: Nazir Bilal Yavuz <byavuz81(at)gmail(dot)com>
Discussion: https://www.postgresql.org/message-id/flat/CAMSWrt-PoQt4sHryWrB1ViuGBJF_PpbjoSGrWR2Ry47bHNLDqg%40mail.gmail.com

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/0f17d1dbfa6224b3ab0f4377c593b880be427f31

Modified Files
--------------
src/tools/pginclude/README | 4 ----
src/tools/pginclude/headerscheck | 4 +---
2 files changed, 1 insertion(+), 7 deletions(-)

Browse pgsql-committers by date

  From Date Subject
Next Message Peter Eisentraut 2026-03-23 07:44:53 pgsql: ci: Run headerscheck and cpluspluscheck in parallel
Previous Message Amit Kapila 2026-03-23 03:59:05 pgsql: pg_createsubscriber: Introduce module-specific logging functions