diff options
author | David Robillard <d@drobilla.net> | 2022-06-28 23:17:19 -0400 |
---|---|---|
committer | David Robillard <d@drobilla.net> | 2022-07-20 16:24:16 -0400 |
commit | 1e87b3ace42c1a51d8b8c6d09b4fa4d0d6025698 (patch) | |
tree | 862fbe1cd497a7782da1ab08ddd39ac548afd78b /meson/suppressions/meson.build | |
parent | 3ae22e31b51e920d22a4bebb211e82b5d7e7c3f2 (diff) | |
download | raul-1e87b3ace42c1a51d8b8c6d09b4fa4d0d6025698.tar.gz raul-1e87b3ace42c1a51d8b8c6d09b4fa4d0d6025698.tar.bz2 raul-1e87b3ace42c1a51d8b8c6d09b4fa4d0d6025698.zip |
Switch to meson build system
Diffstat (limited to 'meson/suppressions/meson.build')
-rw-r--r-- | meson/suppressions/meson.build | 58 |
1 files changed, 58 insertions, 0 deletions
diff --git a/meson/suppressions/meson.build b/meson/suppressions/meson.build new file mode 100644 index 0000000..f43bce3 --- /dev/null +++ b/meson/suppressions/meson.build @@ -0,0 +1,58 @@ +# Copyright 2020-2022 David Robillard <d@drobilla.net> +# SPDX-License-Identifier: CC0-1.0 OR GPL-3.0-or-later + +# Project-specific warning suppressions. +# +# This should be used in conjunction with the generic "warnings" sibling that +# enables all reasonable warnings for the compiler. It lives here just to keep +# the top-level meson.build more readable. + +####### +# C++ # +####### + +if is_variable('cpp') + cpp_suppressions = [] + + if get_option('strict') + if cpp.get_id() in ['clang', 'emscripten'] + cpp_suppressions = [ + '-Wno-c++17-extensions', + '-Wno-padded', + '-Wno-weak-vtables', + ] + + elif cpp.get_id() == 'gcc' + cpp_suppressions = [ + '-Wno-abi-tag', + '-Wno-inline', + '-Wno-multiple-inheritance', + '-Wno-padded', + '-Wno-suggest-attribute=pure', + '-Wno-switch-default', + '-Wno-useless-cast', + ] + + elif cpp.get_id() == 'msvc' + cpp_suppressions = [ + '/wd4514', # unreferenced inline function removed + '/wd4625', # copy constructor implicitly deleted + '/wd4626', # assignment operator implicitly deleted + '/wd4706', # assignment within conditional expression + '/wd4710', # function not inlined + '/wd4711', # function selected for automatic inline expansion + '/wd5026', # move constructor implicitly deleted + '/wd5027', # move assignment operator implicitly deleted + '/wd5045', # compiler will insert Spectre mitigation + ] + endif + endif + + if cpp.get_id() in ['clang', 'emscripten'] + cpp_suppressions += [ + '-Wno-nullability-extension', + ] + endif + + cpp_suppressions = cpp.get_supported_arguments(cpp_suppressions) +endif |