On Fri, Oct 1, 2021 at 4:09 AM Quentin Monnet <quentin@xxxxxxxxxxxxx> wrote: > > API headers from libbpf should not be accessed directly from the > library's source directory. Instead, they should be exported with "make > install_headers". Let's make sure that resolve_btfids installs the > headers properly when building. > > When descending from a parent Makefile, the specific output directories > for building the library and exporting the headers are configurable with > LIBBPF_OUT and LIBBPF_DESTDIR, respectively. This is in addition to > OUTPUT, on top of which those variables are constructed by default. > > Also adjust the Makefile for the BPF selftests in order to point to the > (target) libbpf shared with other tools, instead of building a version > specific to resolve_btfids. > > Signed-off-by: Quentin Monnet <quentin@xxxxxxxxxxxxx> > --- > tools/bpf/resolve_btfids/Makefile | 17 ++++++++++++----- > tools/bpf/resolve_btfids/main.c | 4 ++-- > tools/testing/selftests/bpf/Makefile | 7 +++++-- > 3 files changed, 19 insertions(+), 9 deletions(-) > Acked-by: Andrii Nakryiko <andrii@xxxxxxxxxx>