xref: /freebsd/sbin/route/Makefile (revision e6bfd18d21b225af6a0ed67ceeaf1293b7b9eba5)
1#	@(#)Makefile	8.1 (Berkeley) 6/5/93
2# $FreeBSD$
3
4.include <src.opts.mk>
5
6PACKAGE=runtime
7PROG=	route
8MAN=	route.8
9SRCS=	route.c keywords.h
10WARNS?=	3
11CLEANFILES+=keywords.h
12
13CFLAGS+= -DNS
14.if ${MK_INET_SUPPORT} != "no"
15CFLAGS+= -DINET
16.endif
17.if ${MK_INET6_SUPPORT} != "no"
18CFLAGS+= -DINET6
19.endif
20CFLAGS+= -I.
21
22.if ${MK_NETLINK_SUPPORT} != "no"
23SRCS+= route_netlink.c
24.else
25CFLAGS+=-DWITHOUT_NETLINK
26.endif
27
28HAS_TESTS=
29SUBDIR.${MK_TESTS}+= tests
30
31keywords.h: keywords
32	LC_ALL=C awk '!/^#|^$$/ { \
33		printf "#define\tK_%s\t%d\n\t{\"%s\", K_%s},\n", \
34		    toupper($$1), ++L, $$1, toupper($$1); \
35	}' < ${.CURDIR}/keywords > ${.TARGET} || (rm -f ${.TARGET}; false)
36
37.include <bsd.prog.mk>
38