summaryrefslogtreecommitdiffstats
path: root/sys/modules
diff options
context:
space:
mode:
authormlaier <mlaier@FreeBSD.org>2004-02-26 03:53:54 +0000
committermlaier <mlaier@FreeBSD.org>2004-02-26 03:53:54 +0000
commit428f1c9a0fbaac94f9cce57cd846b2b6f82e17d1 (patch)
treeaa20382749ac1e97a0e00869aaa3a69abbc95a34 /sys/modules
parent94f1c2c12e72d156571a8216199086ba2d775312 (diff)
downloadFreeBSD-src-428f1c9a0fbaac94f9cce57cd846b2b6f82e17d1.zip
FreeBSD-src-428f1c9a0fbaac94f9cce57cd846b2b6f82e17d1.tar.gz
Tweak existing header and other build infrastructure to be able to build
pf/pflog/pfsync as modules. Do not list them in NOTES or modules/Makefile (i.e. do not connect it to any (automatic) builds - yet). Approved by: bms(mentor)
Diffstat (limited to 'sys/modules')
-rw-r--r--sys/modules/pf/Makefile30
-rw-r--r--sys/modules/pflog/Makefile25
-rw-r--r--sys/modules/pfsync/Makefile25
3 files changed, 80 insertions, 0 deletions
diff --git a/sys/modules/pf/Makefile b/sys/modules/pf/Makefile
new file mode 100644
index 0000000..3bceb08
--- /dev/null
+++ b/sys/modules/pf/Makefile
@@ -0,0 +1,30 @@
+# $FreeBSD$
+
+.PATH: ${.CURDIR}/../../contrib/pf/net
+.PATH: ${.CURDIR}/../../contrib/pf/netinet
+
+KMOD= pf
+SRCS = pf.c pf_osfp.c pf_ioctl.c pf_norm.c pf_table.c \
+ in4_cksum.c \
+ opt_pf.h opt_inet.h opt_inet6.h opt_bpf.h opt_random_ip_id.h
+
+CFLAGS+= -Wall -I${.CURDIR}/../../contrib/pf
+
+opt_pf.h:
+ echo "#define DEV_PF 1" > opt_pf.h
+ echo "#define DEV_PFLOG 1" >> opt_pf.h
+ echo "#define DEV_PFSYNC 1" >> opt_pf.h
+
+opt_inet.h:
+ echo "#define INET 1" > opt_inet.h
+
+opt_inet6.h:
+ echo "#define INET6 1" > opt_inet6.h
+
+opt_bpf.h:
+ echo "#define DEV_BPF 1" > opt_bpf.h
+
+opt_random_ip_id.h:
+ echo "#define RANDOM_IP_ID 1" > opt_random_ip_id.h
+
+.include <bsd.kmod.mk>
diff --git a/sys/modules/pflog/Makefile b/sys/modules/pflog/Makefile
new file mode 100644
index 0000000..f500846
--- /dev/null
+++ b/sys/modules/pflog/Makefile
@@ -0,0 +1,25 @@
+# $FreeBSD$
+
+.PATH: ${.CURDIR}/../../contrib/pf/net
+
+KMOD= pflog
+SRCS = if_pflog.c \
+ opt_pf.h opt_inet.h opt_inet6.h opt_bpf.h
+
+CFLAGS+= -Wall -I${.CURDIR}/../../contrib/pf
+
+opt_pf.h:
+ echo "#define DEV_PF 1" > opt_pf.h
+ echo "#define DEV_PFLOG 1" >> opt_pf.h
+ echo "#define DEV_PFSYNC 1" >> opt_pf.h
+
+opt_inet.h:
+ echo "#define INET 1" > opt_inet.h
+
+opt_inet6.h:
+ echo "#define INET6 1" > opt_inet6.h
+
+opt_bpf.h:
+ echo "#define DEV_BPF 1" > opt_bpf.h
+
+.include <bsd.kmod.mk>
diff --git a/sys/modules/pfsync/Makefile b/sys/modules/pfsync/Makefile
new file mode 100644
index 0000000..9cb7b18
--- /dev/null
+++ b/sys/modules/pfsync/Makefile
@@ -0,0 +1,25 @@
+# $FreeBSD$
+
+.PATH: ${.CURDIR}/../../contrib/pf/net
+
+KMOD= pfsync
+SRCS = if_pfsync.c \
+ opt_pf.h opt_inet.h opt_inet6.h opt_bpf.h
+
+CFLAGS+= -Wall -I${.CURDIR}/../../contrib/pf
+
+opt_pf.h:
+ echo "#define DEV_PF 1" > opt_pf.h
+ echo "#define DEV_PFLOG 1" >> opt_pf.h
+ echo "#define DEV_PFSYNC 1" >> opt_pf.h
+
+opt_inet.h:
+ echo "#define INET 1" > opt_inet.h
+
+opt_inet6.h:
+ echo "#define INET6 1" > opt_inet6.h
+
+opt_bpf.h:
+ echo "#define DEV_BPF 1" > opt_bpf.h
+
+.include <bsd.kmod.mk>
OpenPOWER on IntegriCloud