Add bpftool

bpftool comes with Linux kernel source and
it is handy to have bpftool on ipfire kernel
with BPF/BTF enabled to diagnosis BPF related
issue.

Signed-off-by: Vincent Li <vincent.mc.li@gmail.com>
This commit is contained in:
Vincent Li
2024-02-20 21:07:56 +00:00
parent d0bd3cc033
commit e97d70d152
2 changed files with 8 additions and 0 deletions

View File

@@ -23699,3 +23699,4 @@ lib/modules/KVER-ipfire/modules.symbols
lib/modules/KVER-ipfire/modules.symbols.bin
#lib/modules/KVER-ipfire/source
sbin/gen_init_cpio
usr/sbin/bpftool

View File

@@ -170,12 +170,19 @@ else
# Build the kernel
cd $(DIR_APP) && make $(MAKETUNING) $(KERNEL_TARGET) modules
# Build bpftool
cd $(DIR_APP)/tools/bpf/bpftool && sed -i -e 's/^prefix ?= \/usr\/local/prefix ?= \/usr/' Makefile
cd $(DIR_APP)/tools/bpf/bpftool && make $(MAKETUNING)
# Install the kernel
cd $(DIR_APP) && cp -v arch/$(KERNEL_ARCH)/boot/$(KERNEL_TARGET) /boot/vmlinuz-$(VER)-$(VERSUFIX)
cd $(DIR_APP) && cp -v System.map /boot/System.map-$(VER)-$(VERSUFIX)
cd $(DIR_APP) && cp -v .config /boot/config-$(VER)-$(VERSUFIX)
cd $(DIR_APP) && make $(MAKETUNING) modules_install
# Install bpftool
cd $(DIR_APP)/tools/bpf/bpftool && make install
ifneq "$(BUILD_PLATFORM)" "x86"
cd $(DIR_APP) && make $(MAKETUNING) dtbs
mkdir -p /boot/dtb-$(VER)-$(VERSUFIX)