Skip to content

Commit 67f1758

Browse files
Leo-Yanqmonnet
authored andcommitted
bpftool: Link zstd lib required by libelf
When the feature libelf-zstd is detected, the zstd lib is required by libelf. Link the zstd lib in this case. Reviewed-by: Quentin Monnet <[email protected]> Signed-off-by: Leo Yan <[email protected]> Tested-by: Namhyung Kim <[email protected]> Acked-by: Andrii Nakryiko <[email protected]> Cc: Adrian Hunter <[email protected]> Cc: Alexei Starovoitov <[email protected]> Cc: Daniel Borkmann <[email protected]> Cc: Eduard Zingerman <[email protected]> Cc: Guilherme Amadio <[email protected]> Cc: Hao Luo <[email protected]> Cc: Ian Rogers <[email protected]> Cc: James Clark <[email protected]> Cc: Jiri Olsa <[email protected]> Cc: John Fastabend <[email protected]> Cc: KP Singh <[email protected]> Cc: Kan Liang <[email protected]> Cc: Martin KaFai Lau <[email protected]> Cc: Nick Terrell <[email protected]> Cc: Song Liu <[email protected]> Cc: Stanislav Fomichev <[email protected]> Cc: Yonghong Song <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Arnaldo Carvalho de Melo <[email protected]>
1 parent 2f5b4d9 commit 67f1758

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

src/Makefile

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -104,6 +104,7 @@ FEATURE_TESTS += libbfd-liberty
104104
FEATURE_TESTS += libbfd-liberty-z
105105
FEATURE_TESTS += disassembler-four-args
106106
FEATURE_TESTS += disassembler-init-styled
107+
FEATURE_TESTS += libelf-zstd
107108

108109
FEATURE_DISPLAY := clang-bpf-co-re
109110
FEATURE_DISPLAY += llvm
@@ -126,6 +127,12 @@ endif
126127

127128
LIBS = $(LIBBPF) -lelf -lz
128129
LIBS_BOOTSTRAP = $(LIBBPF_BOOTSTRAP) -lelf -lz
130+
131+
ifeq ($(feature-libelf-zstd),1)
132+
LIBS += -lzstd
133+
LIBS_BOOTSTRAP += -lzstd
134+
endif
135+
129136
ifeq ($(feature-libcap), 1)
130137
CFLAGS += -DUSE_LIBCAP
131138
LIBS += -lcap

0 commit comments

Comments
 (0)