diff options
author | Matthias Clasen <mclasen@redhat.com> | 2021-08-21 21:37:28 -0400 |
---|---|---|
committer | Matthias Clasen <mclasen@redhat.com> | 2021-08-22 02:36:48 -0400 |
commit | 68a10a221b661cf194086e57ca019364c6775b7f (patch) | |
tree | e0f835f76aabb3e6f8ccdcb78c48d6bcaa44e6fd /meson.build | |
parent | 3dacd23ed30d8b906fe7774fa04bcc9103639955 (diff) | |
download | pango-68a10a221b661cf194086e57ca019364c6775b7f.tar.gz |
build: More compiler warningscompiler-warnings
Now that the code has been fixed, we can enable
these warnings. The flags here match what is used
in GTK.
Diffstat (limited to 'meson.build')
-rw-r--r-- | meson.build | 43 |
1 files changed, 39 insertions, 4 deletions
diff --git a/meson.build b/meson.build index 92d4a548..63f6e6ce 100644 --- a/meson.build +++ b/meson.build @@ -62,15 +62,50 @@ if cc.get_id() == 'msvc' test_c_only_flags = [] elif cc.get_id() == 'gcc' or cc.get_id() == 'clang' test_c_only_flags = [ + '-Wno-c++11-extensions', + '-Wno-missing-include-dirs', + '-Wno-typedef-redefinition', + '-Wduplicated-branches', + '-Wduplicated-cond', + '-Wformat=2', + '-Wformat-nonliteral', + '-Wformat-security', + '-Wignored-qualifiers', '-Wimplicit-function-declaration', - '-Wstrict-prototypes', - '-Wmissing-prototypes', + '-Wlogical-op', + '-Wmisleading-indentation', + '-Wmissing-format-attribute', + '-Wmissing-include-dirs', + '-Wmissing-noreturn', '-Wnested-externs', '-Wold-style-definition', - '-Wno-int-conversion', - '-Wno-discarded-qualifiers', + '-Wpointer-arith', + '-Wshadow', + '-Wstrict-prototypes', + '-Wswitch-default', + '-Wswitch-enum', + '-Wundef', + '-Wuninitialized', + '-Wunused', + '-Werror=address', + '-Werror=array-bounds', + '-Werror=empty-body', '-Werror=implicit', + '-Werror=implicit-fallthrough', + '-Werror=init-self', + '-Werror=int-to-pointer-cast', + '-Werror=main', + '-Werror=missing-braces', + '-Werror=missing-declarations', + '-Werror=missing-prototypes', + '-Werror=nonnull', '-Werror=pointer-to-int-cast', + '-Werror=redundant-decls', + '-Werror=return-type', + '-Werror=sequence-point', + '-Werror=trigraphs', + '-Werror=vla', + '-Werror=write-strings', ] test_cflags = test_c_only_flags + [ |