summaryrefslogtreecommitdiffstats
path: root/meson.build
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2024-11-24 17:09:30 -0500
committerDavid Robillard <d@drobilla.net>2024-11-24 17:10:28 -0500
commit1d03a572d7d88819a0f024d0d110caae1c2f42ab (patch)
tree131cbb97dd04014b090c05ec26546b0377c4e44c /meson.build
parent55d397fe715502a6dabfa59e735eca32fa9f2f48 (diff)
downloadzix-1d03a572d7d88819a0f024d0d110caae1c2f42ab.tar.gz
zix-1d03a572d7d88819a0f024d0d110caae1c2f42ab.tar.bz2
zix-1d03a572d7d88819a0f024d0d110caae1c2f42ab.zip
Clean up and strengthen warning flags
Some previously global suppressions were only actually needed in benchmarks or tests, so move them there to keep the main set as small as possible.
Diffstat (limited to 'meson.build')
-rw-r--r--meson.build22
1 files changed, 5 insertions, 17 deletions
diff --git a/meson.build b/meson.build
index ad31a87..81f6c62 100644
--- a/meson.build
+++ b/meson.build
@@ -44,8 +44,6 @@ c_suppressions = []
if cc.get_id() in ['clang', 'emscripten']
if warning_level == 'everything'
c_suppressions += [
- '-Wno-bad-function-cast',
- '-Wno-c11-extensions', # Glib
'-Wno-declaration-after-statement',
'-Wno-implicit-fallthrough', # Really for clang < 12
'-Wno-padded',
@@ -54,9 +52,7 @@ if cc.get_id() in ['clang', 'emscripten']
]
if not meson.is_cross_build()
- c_suppressions += [
- '-Wno-poison-system-directories',
- ]
+ c_suppressions += ['-Wno-poison-system-directories']
endif
if host_machine.system() == 'windows'
@@ -68,22 +64,16 @@ if cc.get_id() in ['clang', 'emscripten']
endif
if warning_level in ['everything', '3']
- c_suppressions += [
- '-Wno-nullability-extension',
- ]
+ c_suppressions += ['-Wno-nullability-extension']
endif
if cc.get_id() == 'emscripten'
- c_suppressions += [
- '-Wno-format',
- ]
+ c_suppressions += ['-Wno-format']
endif
elif cc.get_id() == 'gcc'
if warning_level == 'everything'
c_suppressions += [
- '-Wno-bad-function-cast',
- '-Wno-cast-function-type',
'-Wno-inline',
'-Wno-padded',
'-Wno-strict-overflow',
@@ -93,7 +83,7 @@ elif cc.get_id() == 'gcc'
if host_machine.system() == 'windows'
c_suppressions += [
- '-Wno-format',
+ '-Wno-bad-function-cast',
'-Wno-suggest-attribute=const',
'-Wno-suggest-attribute=format',
'-Wno-suggest-attribute=pure',
@@ -102,9 +92,7 @@ elif cc.get_id() == 'gcc'
endif
if warning_level in ['everything', '3']
- c_suppressions += [
- '-Wno-pedantic', # C11
- ]
+ c_suppressions += ['-Wno-pedantic'] # C11
endif
elif cc.get_id() == 'msvc'