@@ -124,10 +124,14 @@ $(OUTPUT)/test_stub.o: test_stub.c
$(call msg,CC,,$@)
$(CC) -c $(CFLAGS) -o $@ $<
+VMLINUX_BTF_PATHS := $(abspath ../../../../vmlinux) \
+ /sys/kernel/btf/vmlinux \
+ /boot/vmlinux-$(shell uname -r)
+VMLINUX_BTF:= $(firstword $(wildcard $(VMLINUX_BTF_PATHS)))
.PHONY: $(OUTPUT)/runqslower
$(OUTPUT)/runqslower: force
- $(Q)$(MAKE) $(submake_extras) -C $(TOOLSDIR)/bpf/runqslower \
- OUTPUT=$(CURDIR)/tools/
+ $(Q)$(MAKE) $(submake_extras) -C $(TOOLSDIR)/bpf/runqslower \
+ OUTPUT=$(OUTPUT)/tools/ VMLINUX_BTF=$(VMLINUX_BTF)
BPFOBJ := $(OUTPUT)/libbpf.a