diff options
author | David Robillard <d@drobilla.net> | 2022-10-23 21:48:38 -0400 |
---|---|---|
committer | David Robillard <d@drobilla.net> | 2022-10-23 21:48:38 -0400 |
commit | 2c1e022ebbb2619b6e497a360480294bb950e20e (patch) | |
tree | 9dc84b0da6088d5bc49b714aad600d78f0a16084 /test/headers/meson.build | |
parent | 94e66b9793932483b5b0f5f67a16c4c16bd4665c (diff) | |
download | serd-2c1e022ebbb2619b6e497a360480294bb950e20e.tar.gz serd-2c1e022ebbb2619b6e497a360480294bb950e20e.tar.bz2 serd-2c1e022ebbb2619b6e497a360480294bb950e20e.zip |
Test header for warnings more strictly
Diffstat (limited to 'test/headers/meson.build')
-rw-r--r-- | test/headers/meson.build | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/test/headers/meson.build b/test/headers/meson.build new file mode 100644 index 00000000..ac9dc2d2 --- /dev/null +++ b/test/headers/meson.build @@ -0,0 +1,29 @@ +# Copyright 2020-2022 David Robillard <d@drobilla.net> +# SPDX-License-Identifier: 0BSD OR ISC + +header_c_suppressions = [] + +if get_option('strict') + if cc.get_id() == 'clang' + header_c_suppressions += [ + '-Wno-nullability-extension', + '-Wno-padded', + ] + elif cc.get_id() == 'gcc' + header_c_suppressions += [ + '-Wno-padded', + '-Wno-unused-const-variable', + ] + endif +endif + +test( + 'headers', + executable( + 'test_headers', + files('test_headers.c'), + c_args: header_c_suppressions, + dependencies: serd_dep, + ), + suite: 'unit', +) |