btrfs-progs: Makefile.extrawarn: Import cc-disable-warning

We imported cc-option but forgot to import cc-disable-warning.

Fixes: b556a992c3 ("btrfs-progs: build: allow to build with various compiler warnings")
Signed-off-by: Qu Wenruo <wqu@suse.com>
Signed-off-by: David Sterba <dsterba@suse.com>
master
Qu Wenruo 2018-12-05 14:40:06 +08:00 committed by David Sterba
parent 41e19f703d
commit 737defd3a5
1 changed files with 5 additions and 0 deletions

View File

@ -19,6 +19,11 @@ try-run = $(shell set -e; \
cc-option = $(call try-run,\
$(CC) $(CFLAGS) $(1) -c -x c /dev/null -o "$$TMP",$(1),$(2))
# cc-disable-warning
# Usage: cflags-y += $(call cc-disable-warning,unused-but-set-variable)
cc-disable-warning = $(call try-run, \
$(CC) -Werror $(CFLAGS) -W$(strip $(1)) -c -x c /dev/null -o "$$TMP",-Wno-$(strip $(1)))
# From linux.git/scripts/Makefile.extrawarn
# ==========================================================================
#