From: Hilko Bengen Date: Sun, 2 Dec 2018 23:26:03 +0000 (+0000) Subject: libbpf: link shared object with libelf X-Git-Tag: archive/raspbian/5.2.17-1+rpi1^2^2^2^2^2~23 X-Git-Url: https://dgit.raspbian.org/?a=commitdiff_plain;h=da6e8b2b5a4f744ee255b6dc322a3e804a3a56c0;p=linux.git libbpf: link shared object with libelf libbpf.so needs to be linked against libelf to avoid missing symbols. Signed-off-by: Hilko Bengen Gbp-Pq: Topic bugfix/all Gbp-Pq: Name libbpf-link-shared-object-with-libelf.patch --- diff --git a/tools/lib/bpf/Makefile b/tools/lib/bpf/Makefile index eabc610ca75..6729315cef3 100644 --- a/tools/lib/bpf/Makefile +++ b/tools/lib/bpf/Makefile @@ -162,7 +162,7 @@ $(BPF_IN): force elfdep bpfdep $(Q)$(MAKE) $(build)=libbpf $(OUTPUT)libbpf.so.$(LIBBPF_VERSION): $(BPF_IN) - $(QUIET_LINK)$(CC) --shared $^ -Wl,-soname,$(@F) -o $@ + $(QUIET_LINK)$(CC) --shared $^ -lelf -Wl,-soname,$(@F) -o $@ $(OUTPUT)libbpf.a: $(BPF_IN) $(QUIET_LINK)$(RM) $@; $(AR) rcs $@ $^