Hi Luca, When I generate a tarball I'm not being able to build, as it can't find bpf/btf.h, for instance, see this cset where I tried to fix it: commit 00cb89fb9af0355b8b4b64e26d3afa2348efb80d (HEAD -> next, five/next) Author: Arnaldo Carvalho de Melo <acme@xxxxxxxxxx> Date: Thu Aug 12 15:29:28 2021 -0300 MANIFEST: Add lib/include/bpf The tarball wasn't working without this file: [ 32%] Building C object CMakeFiles/dwarves.dir/btf_encoder.c.o /tmp/dwarves-1.22/btf_encoder.c:18:10: fatal error: bpf/btf.h: No such file or directory #include <bpf/btf.h> ^~~~~~~~~~~ compilation terminated. Cc: Luca Boccassi <bluca@xxxxxxxxxx> Fixes: 82756ea3eaf1f6e7 ("libbpf: Fixup patch to allow to use packaged version") Signed-off-by: Arnaldo Carvalho de Melo <acme@xxxxxxxxxx> diff --git a/MANIFEST b/MANIFEST index 67f382e6f8f9..88f6193d5bc0 100644 --- a/MANIFEST +++ b/MANIFEST @@ -68,3 +68,4 @@ libctf.c libctf.h regtest lib/bpf/ +lib/include/bpf [acme@seventh pahole]$ But this doesn't help as well, as to prepare the tarball I use tar --transform option (see README.tarball), and with lib/include/bpf (the symlink pointing to ../bpf/src) we end up with: [acme@seventh pahole]$ tar xvf ~/rpmbuild/SOURCES/dwarves-1.22.tar.xz | tail dwarves-1.22/lib/bpf/include/linux/compiler.h dwarves-1.22/lib/bpf/include/linux/list.h dwarves-1.22/lib/bpf/include/linux/kernel.h dwarves-1.22/lib/bpf/include/linux/err.h dwarves-1.22/lib/bpf/CHECKPOINT-COMMIT dwarves-1.22/lib/bpf/LICENSE dwarves-1.22/lib/bpf/LICENSE.BSD-2-Clause dwarves-1.22/lib/bpf/README.md dwarves-1.22/lib/bpf/BPF-CHECKPOINT-COMMIT dwarves-1.22/lib/include/bpf [acme@seventh pahole]$ ls -la dwarves-1.22/lib/include/ total 8 drwxr-xr-x. 2 acme acme 4096 Aug 12 15:54 . drwxr-xr-x. 4 acme acme 4096 Aug 12 15:54 .. lrwxrwxrwx. 1 acme acme 23 Jun 18 17:56 bpf -> dwarves-1.22/../bpf/src [acme@seventh pahole]$ Without the 'tar --transform' that is, on a checked out git repo: ⬢[acme@toolbox pahole]$ ls -la lib/include/bpf lrwxrwxrwx. 1 acme acme 10 Aug 11 08:55 lib/include/bpf -> ../bpf/src ⬢[acme@toolbox pahole]$ ls -la lib/bpf/src total 892 drwxr-xr-x. 1 acme acme 692 Aug 5 16:12 . drwxr-xr-x. 1 acme acme 280 Jun 14 15:51 .. <SNIP> -rw-r--r--. 1 acme acme 123802 Jun 14 15:51 btf.c -rw-r--r--. 1 acme acme 40953 Jun 14 15:51 btf_dump.c -rw-r--r--. 1 acme acme 11796 Jun 14 15:51 btf.h <SNIP> ⬢[acme@toolbox pahole]$ The problem is described in this old Debian ticket: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=775247 I'm now trying to figure out what Frank meant when referring to that "S" flag. This is all on the 'next' branch, but I guess it affects master as well: https://git.kernel.org/pub/scm/devel/pahole/pahole.git/log/?h=next libbpf-devel has it on /usr/include/bpf/btf.h so its all ok there, but when building it from the tarball I'm stuck with that symlink trick not working ;-\ I have to figure out what is this 'S' flag (local symlinks, etc) or stop using this --transform mechanism to have the dwarves-${version} top level directory added when generating the tarball :-\ - Arnaldo