aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/tools
diff options
context:
space:
mode:
authorDavid Engraf <david.engraf@sysgo.com>2025-02-03 08:36:10 +0100
committerJosh Poimboeuf <jpoimboe@kernel.org>2025-03-12 15:43:38 -0700
commitbf71940fc16953bed84caa59b7b076ead70d42f6 (patch)
tree33cc74852f1feafff74729f06246821285860adb /tools
parentLinux 6.14-rc6 (diff)
downloadwireguard-linux-bf71940fc16953bed84caa59b7b076ead70d42f6.tar.xz
wireguard-linux-bf71940fc16953bed84caa59b7b076ead70d42f6.zip
objtool: Hide unnecessary compiler error message
The check for using old libelf prints an error message when libelf.h is not available but does not abort. This may confuse so hide the compiler error message. Signed-off-by: David Engraf <david.engraf@sysgo.com> Link: https://lore.kernel.org/r/20250203073610.206000-1-david.engraf@sysgo.com Signed-off-by: Josh Poimboeuf <jpoimboe@kernel.org>
Diffstat (limited to 'tools')
-rw-r--r--tools/objtool/Makefile2
1 files changed, 1 insertions, 1 deletions
diff --git a/tools/objtool/Makefile b/tools/objtool/Makefile
index 7a65948892e5..8c20361dd100 100644
--- a/tools/objtool/Makefile
+++ b/tools/objtool/Makefile
@@ -37,7 +37,7 @@ OBJTOOL_CFLAGS := -Werror $(WARNINGS) $(KBUILD_HOSTCFLAGS) -g $(INCLUDES) $(LIBE
OBJTOOL_LDFLAGS := $(LIBELF_LIBS) $(LIBSUBCMD) $(KBUILD_HOSTLDFLAGS)
# Allow old libelf to be used:
-elfshdr := $(shell echo '$(pound)include <libelf.h>' | $(HOSTCC) $(OBJTOOL_CFLAGS) -x c -E - | grep elf_getshdr)
+elfshdr := $(shell echo '$(pound)include <libelf.h>' | $(HOSTCC) $(OBJTOOL_CFLAGS) -x c -E - 2>/dev/null | grep elf_getshdr)
OBJTOOL_CFLAGS += $(if $(elfshdr),,-DLIBELF_USE_DEPRECATED)
# Always want host compilation.