]> git.proxmox.com Git - mirror_ubuntu-artful-kernel.git/blob - tools/testing/selftests/bpf/Makefile
bonding: attempt to better support longer hw addresses
[mirror_ubuntu-artful-kernel.git] / tools / testing / selftests / bpf / Makefile
1 LIBDIR := ../../../lib
2 BPFDIR := $(LIBDIR)/bpf
3
4 CFLAGS += -Wall -O2 -I../../../include/uapi -I$(LIBDIR) -I../../../include
5 LDLIBS += -lcap -lelf
6
7 TEST_GEN_PROGS = test_verifier test_tag test_maps test_lru_map test_lpm_map test_progs
8
9 TEST_GEN_FILES = test_pkt_access.o test_xdp.o test_l4lb.o
10
11 TEST_PROGS := test_kmod.sh
12
13 include ../lib.mk
14
15 BPFOBJ := $(OUTPUT)/libbpf.a
16
17 $(TEST_GEN_PROGS): $(BPFOBJ)
18
19 .PHONY: force
20
21 # force a rebuild of BPFOBJ when its dependencies are updated
22 force:
23
24 $(BPFOBJ): force
25 $(MAKE) -C $(BPFDIR) OUTPUT=$(OUTPUT)/
26
27 CLANG ?= clang
28
29 %.o: %.c
30 $(CLANG) -I../../../include/uapi -I../../../../samples/bpf/ \
31 -D__x86_64__ -Wno-compare-distinct-pointer-types \
32 -O2 -target bpf -c $< -o $@