From ae7b0948f9325ca228130f6728395b97259a1e8f Mon Sep 17 00:00:00 2001 From: Jesper Dangaard Brouer Date: Fri, 8 Jan 2021 18:07:41 +0100 Subject: [PATCH] MTU-tests: Makefile detect if TC have libbpf Only strip BTF info when TC don't have libbpf support. Signed-off-by: Jesper Dangaard Brouer --- MTU-tests/Makefile | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/MTU-tests/Makefile b/MTU-tests/Makefile index 19fe613..40375d1 100644 --- a/MTU-tests/Makefile +++ b/MTU-tests/Makefile @@ -8,7 +8,8 @@ LIB_DIR = ../lib include $(LIB_DIR)/common.mk -# The iproute2 'tc' tool doesn't understand BTF debug info +ifndef HAVE_TC_LIBBPF +# If the iproute2 'tc' tool doesn't understand BTF debug info # use llvm-strip to remove this debug info from object file # # *BUT* cannot strip everything as it removes ELF elems needed for @@ -19,3 +20,4 @@ strip_tc_obj: tc_bpf_inc_pkt_size.o $(Q) llvm-strip --no-strip-all --remove-section .BTF $? all: strip_tc_obj +endif