build: Enable Wextra with some exceptions

-Wno-cast-function-type:
Signal handler code relies on this.

-Wno-type-limits:
Some of the color space conversion code in zm_image throws this warning. To not break anything let's ignore this warning for the time being.

Note that clang enables -Woverloaded-virtual with -Wextra. To not flood the GCC build log with warnings let's not enable this at the moment.
This will be done in a second step, when the currently throwing code will be cleaned up.
This commit is contained in:
Peter Keresztes Schmidt 2021-02-27 02:08:14 +01:00
parent 6a47780f60
commit 6e2f8bfedb
2 changed files with 8 additions and 2 deletions

View File

@ -1,6 +1,8 @@
target_compile_options(zm-warning-interface target_compile_options(zm-warning-interface
INTERFACE INTERFACE
-Wall) -Wall
-Wextra
-Wno-unused-parameter)
if(ASAN) if(ASAN)
target_compile_options(zm-compile-option-interface target_compile_options(zm-compile-option-interface

View File

@ -1,6 +1,10 @@
target_compile_options(zm-warning-interface target_compile_options(zm-warning-interface
INTERFACE INTERFACE
-Wall) -Wall
-Wextra
-Wno-cast-function-type
-Wno-type-limits
-Wno-unused-parameter)
if(ASAN) if(ASAN)
target_compile_options(zm-compile-option-interface target_compile_options(zm-compile-option-interface