From dfb8d80c1a6514f36912610118d42e41641d01c1 Mon Sep 17 00:00:00 2001 From: Manoj Gupta Date: Wed, 27 Apr 2022 20:23:11 -0700 Subject: [PATCH] utils/cbfstool: Disable Wstrict-prototypes warning As recommended on crrev.com/c/3612466 lz4 code is not supposed to be modified. Since both gcc and clang complain about functions without explicit void in argument with Wstrict-prototypes, just disable it instead instead of enabling. BUG=b:230345382 TEST=llvm tot test BRANCH=none Signed-off-by: Manoj Gupta Change-Id: I9f3ae01821447f43b4082598dd618d9f8325dca2 Reviewed-on: https://review.coreboot.org/c/coreboot/+/63936 Reviewed-by: Julius Werner Tested-by: build bot (Jenkins) --- util/cbfstool/Makefile.inc | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/util/cbfstool/Makefile.inc b/util/cbfstool/Makefile.inc index 3787a56578..f3e6c75dce 100644 --- a/util/cbfstool/Makefile.inc +++ b/util/cbfstool/Makefile.inc @@ -144,6 +144,8 @@ else TOOLCFLAGS+=-std=c11 endif +LZ4CFLAGS ?= -Wno-strict-prototypes + VBOOT_HOSTLIB = $(VBOOT_HOST_BUILD)/libvboot_host.a $(VBOOT_HOSTLIB): @@ -186,7 +188,7 @@ $(objutil)/cbfstool/%.o: $(top)/src/commonlib/bsd/%.c $(objutil)/cbfstool/%.o: $(top)/util/cbfstool/lz4/lib/%.c printf " HOSTCC $(subst $(objutil)/,,$(@))\n" - $(HOSTCC) $(TOOLCPPFLAGS) $(TOOLCFLAGS) $(HOSTCFLAGS) -c -o $@ $< + $(HOSTCC) $(TOOLCPPFLAGS) $(TOOLCFLAGS) $(HOSTCFLAGS) $(LZ4CFLAGS) -c -o $@ $< $(objutil)/cbfstool/%.o: $(top)/util/cbfstool/fpt_formats/%.c printf " HOSTCC $(subst $(objutil)/,,$(@))\n"