summaryrefslogtreecommitdiff
path: root/src/xdp/common/Makefile
diff options
context:
space:
mode:
authorChristian Poessinger <christian@poessinger.com>2020-12-18 17:13:13 +0100
committerChristian Poessinger <christian@poessinger.com>2020-12-19 21:56:19 +0100
commitb5c80d310527223b93e4133ac2f4c8c063c70a98 (patch)
tree48ae9e2752b4b94c07f767a019c99a8c2460c014 /src/xdp/common/Makefile
parent22308b05dfbcd8da0230bbd8ba3bbc2a55da7786 (diff)
downloadvyos-1x-b5c80d310527223b93e4133ac2f4c8c063c70a98.tar.gz
vyos-1x-b5c80d310527223b93e4133ac2f4c8c063c70a98.zip
xdp: T2666: switch to example code provided by xdp-tutorial
Diffstat (limited to 'src/xdp/common/Makefile')
-rw-r--r--src/xdp/common/Makefile23
1 files changed, 23 insertions, 0 deletions
diff --git a/src/xdp/common/Makefile b/src/xdp/common/Makefile
new file mode 100644
index 000000000..2502027e9
--- /dev/null
+++ b/src/xdp/common/Makefile
@@ -0,0 +1,23 @@
+# SPDX-License-Identifier: (GPL-2.0)
+CC := gcc
+
+all: common_params.o common_user_bpf_xdp.o common_libbpf.o
+
+CFLAGS := -g -Wall
+
+CFLAGS += -I../include/
+# TODO: Do we need to make libbpf from this make file too?
+
+common_params.o: common_params.c common_params.h
+ $(CC) $(CFLAGS) -c -o $@ $<
+
+common_user_bpf_xdp.o: common_user_bpf_xdp.c common_user_bpf_xdp.h
+ $(CC) $(CFLAGS) -c -o $@ $<
+
+common_libbpf.o: common_libbpf.c common_libbpf.h
+ $(CC) $(CFLAGS) -c -o $@ $<
+
+.PHONY: clean
+
+clean:
+ rm -f *.o