Re: meson: Specify -Wformat as a common warning flag for extensions

From: Sutou Kouhei <kou(at)clear-code(dot)com>
To: peter(at)eisentraut(dot)org
Cc: tristan(at)neon(dot)tech, michael(at)paquier(dot)xyz, pgsql-hackers(at)postgresql(dot)org
Subject: Re: meson: Specify -Wformat as a common warning flag for extensions
Date: 2024-03-15 09:36:55
Message-ID: 20240315.183655.616433279210896579.kou@clear-code.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Hi,

In <49e97fd0-c17e-4cbc-aeee-80ac51400736(at)eisentraut(dot)org>
"Re: meson: Specify -Wformat as a common warning flag for extensions" on Wed, 13 Mar 2024 08:38:28 +0100,
Peter Eisentraut <peter(at)eisentraut(dot)org> wrote:

> I think the fix then is to put -Wall into CFLAGS in
> Makefile.global. Looking at a diff of Makefile.global between an
> autoconf and a meson build, I also see that under meson, CFLAGS
> doesn't get -O2 -g (or similar, depending on settings). This
> presumably has the same underlying issue that meson handles those
> flags internally.
>
> For someone who wants to write a fix for this, the relevant variable
> is var_cflags in our meson scripts. And var_cxxflags as well.

How about the attached v4 patch?

Thanks,
--
kou

Attachment Content-Type Size
v4-0001-meson-Restore-implicit-warning-debug-optimize-fla.patch text/x-patch 3.3 KB

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Aleksander Alekseev 2024-03-15 09:47:42 Re: UUID v7
Previous Message Daniel Gustafsson 2024-03-15 09:32:00 Re: Support json_errdetail in FRONTEND builds