Skip to content
Snippets Groups Projects
Commit 6262e4e7 authored by Mike Frysinger's avatar Mike Frysinger Committed by Wolfgang Denk
Browse files

disable security warning flags when possible


Some toolchains enable security warning flags by default, but these don't
really make sense in the u-boot world.  Such as forcing changes like:
	-printf(foo);
	+printf("%s", foo);

So disable the flags when the compiler supports them.  Linux has already
merged a similar change in their build system.

Signed-off-by: default avatarMike Frysinger <vapier@gentoo.org>
parent e84ffddb
No related branches found
No related tags found
No related merge requests found
......@@ -211,6 +211,10 @@ CFLAGS := $(CPPFLAGS) -Wall -Wstrict-prototypes
endif
CFLAGS += $(call cc-option,-fno-stack-protector)
# Some toolchains enable security related warning flags by default,
# but they don't make much sense in the u-boot world, so disable them.
CFLAGS += $(call cc-option,-Wno-format-nonliteral)
CFLAGS += $(call cc-option,-Wno-format-security)
# $(CPPFLAGS) sets -g, which causes gcc to pass a suitable -g<format>
# option to the assembler.
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment