From: "Steven Rostedt (Google)" <rostedt@xxxxxxxxxxx> Remove the '-c' option from the test-build macro build. To test if a function exists, it needs to go through the link phase, otherwise it can pass with an undefined symbol. Link: https://lore.kernel.org/linux-trace-devel/20220428174949.797657-2-rostedt@xxxxxxxxxxx Cc: Joel Fernandes <joel@xxxxxxxxxxxxxxxxx> Signed-off-by: Steven Rostedt (Google) <rostedt@xxxxxxxxxxx> --- Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Makefile b/Makefile index 982514baad01..9fbc6de25d05 100644 --- a/Makefile +++ b/Makefile @@ -163,7 +163,7 @@ export NO_PYTHON # $(call test-build, snippet, ret) -> ret if snippet compiles # -> empty otherwise test-build = $(if $(shell sh -c 'echo "$(1)" | \ - $(CC) -o /dev/null -c -x c - > /dev/null 2>&1 && echo y'), $2) + $(CC) -o /dev/null -x c - > /dev/null 2>&1 && echo y'), $2) UDIS86_AVAILABLE := $(call test-build,\#include <udis86.h>, y) ifneq ($(strip $(UDIS86_AVAILABLE)), y) -- 2.35.1