On Mon, 21 Sep 2026 14:00:05 +0800 Bochao Cao via B4 Relay wrote: > +BPFTOOL ?= bpftool > + > +CFLAGS += -I$(OUTPUT) -I$(SCRATCH_DIR)/include > +CFLAGS += -I$(top_srcdir)/tools/include > +CFLAGS += -I$(top_srcdir)/tools/arch/$(SRCARCH)/include > +CFLAGS += -I$(top_srcdir)/tools/include/uapi > +CFLAGS += -I../../../net/lib
Can we stick the generic BPF stuff into ../../../net/bpf.mk instead of directly in here? I think the includes should already be fine? (please note that net/ selftests assume `make headers_install` was run before building the tests! IIRC bpf selftests were trying to avoid that but we have weaker rules, so some of the includes may not really be necessary) > +$(OUTPUT)/xdp_features.skel.h: $(OUTPUT)/xdp_features.bpf.o > + $(call msg,GEN-SKEL,,$@) > + $(Q)$(BPFTOOL) gen skeleton $< name xdp_features > $@ It should be possible to create a generic rule to build all %.skel.h ? > +$(OUTPUT)/xdp_features: xdp_features.c xdp_features.h \ > + $(OUTPUT)/xdp_features.skel.h $(BPFOBJ) > + $(call msg,BINARY,,$@) > + $(Q)$(CC) $(CFLAGS) $(filter %.a %.o %.c,$^) \ > + $(LDLIBS) -lelf -lz -lpthread -o $@ > + > +EXTRA_CLEAN += $(OUTPUT)/xdp_features.skel.h

