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

Peter Eisentraut <peter@eisentraut.org>

From: Peter Eisentraut <peter@eisentraut.org>
To: Sutou Kouhei <kou@clear-code.com>, andres@anarazel.de
Cc: tristan@neon.tech, michael@paquier.xyz, pgsql-hackers@postgresql.org
Date: 2024-05-29T06:31:05Z
Lists: pgsql-hackers
On 07.04.24 18:01, Sutou Kouhei wrote:
> +# We don't have "warning_level == 3" and "warning_level ==
> +# 'everything'" here because we don't use these warning levels.
> +if warning_level == '1'
> +  common_builtin_flags += ['-Wall']
> +elif warning_level == '2'
> +  common_builtin_flags += ['-Wall', '-Wextra']
> +endif

I would trim this even further and always export just '-Wall'.  The 
other options aren't really something we support.

The other stanzas, on '-g' and '-O*', look good to me.




Commits

  1. meson: Restore implicit warning/debug/optimize flags for extensions