Error building eBPF under Kali Linux

Good morning,

I am trying to build Suricata 6.0.3 under Kali Linux with eBPF support. I have installed clang, libbpf-dev and libbpf0 packages. But when I try to pass configure options, the following error is returned:

./configure --prefix=/usr/ --sysconfdir=/etc/ --localstatedir=/var/ --enable-ebpf --enable-ebpf-build
checking whether make supports nested variables… yes
checking for a BSD-compatible install… /usr/bin/install -c
checking whether build environment is sane… yes
checking for a thread-safe mkdir -p… /usr/bin/mkdir -p
checking for gawk… no
checking for mawk… mawk
checking whether make sets $(MAKE)… yes
checking whether UID ‘0’ is supported by ustar format… yes
checking whether GID ‘0’ is supported by ustar format… yes
checking how to create a ustar tar archive… gnutar
checking build system type… x86_64-pc-linux-gnu
checking host system type… x86_64-pc-linux-gnu
checking how to print strings… printf
checking whether make supports the include directive… yes (GNU style)
checking for gcc… /usr/bin/clang
checking whether the C compiler works… yes

checking for special C compiler options needed for large files… no
checking for _FILE_OFFSET_BITS value needed for large files… no
checking host os… installation for x86_64-pc-linux-gnu OS… ok
checking for c11 support… yes
checking for thread local storage gnu __thread support… yes
checking for dlfcn.h… (cached) yes
checking for plugin support… yes
checking checking if /usr/bin/clang supports -march=native… yes
configure: error: unable to find any of needed to build ebpf files

In config.log there is only one entry:

configure:17393: checking for dlfcn.h
configure:17393: result: yes
configure:17403: checking for plugin support
configure:17418: /usr/bin/clang -o conftest -g -O2 -std=c11 -rdynamic conftest.c >&5
configure:17418: $? = 0
configure:17420: result: yes
configure:17474: checking checking if /usr/bin/clang supports -march=native
configure:17487: /usr/bin/clang -c -g -O2 -std=c11 -march=native conftest.c >&5
configure:17487: $? = 0
configure:17489: result: yes
configure:17606: error: unable to find any of needed to build ebpf files

What am I doing wrong?

P.D: dpkg -l | grep bpf output:
ii libbpf-dev:amd64 1:0.3-2 amd64 eBPF helper library (development files)
ii libbpf0:amd64 1:0.3-2 amd64 eBPF helper library (shared library)

For any future lurkers - I ran into this issue today and the fix should be contained within configure: fix llc detection on recent Debian v2 by lukashino · Pull Request #9975 · OISF/suricata · GitHub

This only affects master-6.0.x until the merge, main-7.0.x, and master work fine already.