Makefile.flags: restrict Wno-constant-logical-operand and Wno-string-plus-int options for clang

these options were added in b4ef2e3467 commit
gcc shows unrecognized command-line option warnings

Signed-off-by: Biswapriyo Nath <nathbappai@gmail.com>
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
This commit is contained in:
Biswapriyo Nath 2020-06-09 23:05:12 +05:30 committed by Denys Vlasenko
parent 0356607264
commit 505eeae402

View File

@ -77,7 +77,9 @@ CFLAGS += $(call cc-option,-fno-asynchronous-unwind-tables,)
CFLAGS += $(call cc-option,-fno-builtin-printf,)
# clang-9 does not like "str" + N and "if (CONFIG_ITEM && cond)" constructs
ifeq ($(CC),clang)
CFLAGS += $(call cc-option,-Wno-string-plus-int -Wno-constant-logical-operand)
endif
# FIXME: These warnings are at least partially to be concerned about and should
# be fixed..