aboutsummaryrefslogtreecommitdiff
path: root/README
diff options
context:
space:
mode:
authorGravatar Quentin Monnet <quentin@isovalent.com> 2021-10-07 20:44:35 +0100
committerGravatar Andrii Nakryiko <andrii@kernel.org> 2021-10-08 12:00:20 -0700
commit3f7a3318a7c60947e27be372950840a5eab976d0 (patch)
tree44951cb4e972b8e3242a24deba951da878ebeb66 /README
parentsamples/bpf: Update .gitignore (diff)
downloadlinux-3f7a3318a7c60947e27be372950840a5eab976d0.tar.gz
linux-3f7a3318a7c60947e27be372950840a5eab976d0.tar.bz2
linux-3f7a3318a7c60947e27be372950840a5eab976d0.zip
samples/bpf: Install libbpf headers when building
API headers from libbpf should not be accessed directly from the source directory. Instead, they should be exported with "make install_headers". Make sure that samples/bpf/Makefile installs the headers properly when building. The object compiled from and exported by libbpf are now placed into a subdirectory of sample/bpf/ instead of remaining in tools/lib/bpf/. We attempt to remove this directory on "make clean". However, the "clean" target re-enters the samples/bpf/ directory from the root of the repository ("$(MAKE) -C ../../ M=$(CURDIR) clean"), in such a way that $(srctree) and $(src) are not defined, making it impossible to use $(LIBBPF_OUTPUT) and $(LIBBPF_DESTDIR) in the recipe. So we only attempt to clean $(CURDIR)/libbpf, which is the default value. Add a dependency on libbpf's headers for the $(TRACE_HELPERS). We also change the output directory for bpftool, to place the generated objects under samples/bpf/bpftool/ instead of building in bpftool's directory directly. Doing so, we make sure bpftool reuses the libbpf library previously compiled and installed. Signed-off-by: Quentin Monnet <quentin@isovalent.com> Signed-off-by: Andrii Nakryiko <andrii@kernel.org> Link: https://lore.kernel.org/bpf/20211007194438.34443-10-quentin@isovalent.com
Diffstat (limited to 'README')
0 files changed, 0 insertions, 0 deletions