Treat 'implicit fallthrough' errors as warnings

After fixing the warnings, the compiler option should be removed.

Issue #3307
This commit is contained in:
Christian Prochaska 2019-05-17 13:41:07 +02:00 committed by Christian Helmuth
parent b4649d84ee
commit 7fadfbbd9f
3 changed files with 13 additions and 0 deletions

View File

@ -16,6 +16,10 @@ CC_WARN = -Wall -Wextra -Waggregate-return -Wcast-align -Wcast-qual \
-Wold-style-cast -Woverloaded-virtual -Wsign-promo \
-Wlogical-op -Wstrict-null-sentinel \
-Wstrict-overflow=5 -Wvolatile-register-var
# XXX fix the warnings and remove this option
CC_WARN += -Wno-error=implicit-fallthrough
CC_OPT += -pipe \
-fdata-sections -fomit-frame-pointer -freg-struct-return \
-freorder-blocks -funit-at-a-time -fno-exceptions -fno-rtti \

View File

@ -134,6 +134,11 @@ endif
CC_OLEVEL ?= -O2
CC_WARN ?= -Wall
#
# XXX fix the warnings and remove this option
#
CC_WARN += -Wno-error=implicit-fallthrough
#
# Additional warnings for C++
#

View File

@ -26,6 +26,10 @@ include $(call select_from_repositories,lib/mk/libc-common.inc)
CC_CXX_WARN_STRICT = -Wextra -Weffc++ -Werror
CC_WARN += -Wno-parentheses -Wall -Wno-unused
# XXX fix the warnings and remove this option
CC_WARN += -Wno-error=implicit-fallthrough
CC_CXX_OPT += -march=core2
CC_OPT_model/intel82576vf := -mssse3
CC_OPT_PIC :=