With GCC 12, even with -std=gnu99, -Wpedantic complains about %m in format
strings, __PRETTY_FUNCTION__, braces inside expressions, etc.; and it
makes some of these into errors.
Fixes: https://todo.sr.ht/~emersion/basu/18
Signed-off-by: Ismael Luceno <ismael@iodev.co.uk>
---
meson.build | 9 +++++++--
1 file changed, 7 insertions(+), 2 deletions(-)
diff --git a/meson.build b/meson.build
index c942fd311b64..26125d625efb 100644
--- a/meson.build
+++ b/meson.build
@@ -3,7 +3,13 @@ project(
'c',
version : '0.2.0',
license : 'LGPLv2+',
-default_options : ['c_std=gnu99', 'prefix=/usr', 'sysconfdir=/etc', 'localstatedir=/var'],
+default_options : [
+ 'c_std=gnu99',
+ 'prefix=/usr',
+ 'sysconfdir=/etc',
+ 'localstatedir=/var',
+ 'warning_level=2',
+],
meson_version : '>= 0.54'
)
@@ -22,7 +28,6 @@ cc = meson.get_compiler('c')
cxx_cmd = ''
possible_cc_flags = [
- '-Wextra',
'-Werror=undef',
'-Wlogical-op',
'-Wmissing-include-dirs',
--
2.39.0