btrfs-progs: Makefile.extrawarn: Don't warn on sign compare

Under most case, we are just using 'int' for 'unsigned int', and doesn't
care about the sign.

The -Wsign-compare warning is causing tons of false alerts.  Suppressing
it makes W=1 less noisy so we can focus on real problems, while still
allowing it in W=3 build.

Signed-off-by: Qu Wenruo <wqu@suse.com>
Signed-off-by: David Sterba <dsterba@suse.com>
This commit is contained in:
Qu Wenruo 2018-12-05 14:40:08 +08:00 committed by David Sterba
parent 07cead1a1e
commit 32b86071cf
1 changed files with 2 additions and 0 deletions

View File

@ -53,6 +53,7 @@ warning-1 += $(call cc-option, -Wmissing-include-dirs)
warning-1 += $(call cc-option, -Wunused-but-set-variable)
warning-1 += $(call cc-disable-warning, missing-field-initializers)
warning-1 += $(call cc-disable-warning, format-truncation)
warning-1 += $(call cc-disable-warning, sign-compare)
warning-2 := -Waggregate-return
warning-2 += -Wcast-align
@ -73,6 +74,7 @@ warning-3 += -Wredundant-decls
warning-3 += -Wswitch-default
warning-3 += $(call cc-option, -Wpacked-bitfield-compat)
warning-3 += $(call cc-option, -Wvla)
warning-3 += $(call cc-option, -Wsign-compare)
warning := $(warning-$(findstring 1, $(BUILD_ENABLE_EXTRA_GCC_CHECKS)))
warning += $(warning-$(findstring 2, $(BUILD_ENABLE_EXTRA_GCC_CHECKS)))