1#	from: @(#)Makefile    5.10 (Berkeley) 6/24/90
2# $FreeBSD$
3
4.include <bsd.own.mk>
5
6.PATH: ${.CURDIR}/../../include/rpcsvc
7
8LIB=    rpcsvc
9
10RPCSRCS= klm_prot.x mount.x nfs_prot.x nlm_prot.x rex.x rnusers.x \
11	rquota.x rstat.x rwall.x sm_inter.x spray.x yppasswd.x ypxfrd.x \
12	ypupdate_prot.x
13
14OTHERSRCS=  rnusers.c rstat.c rwall.c
15SECRPCSRCS= secretkey.c xcrypt.c
16
17.if ${MK_NIS} != "no"
18OTHERSRCS+= yp_passwd.c yp_update.c
19.endif
20
21RPCCOM=	RPCGEN_CPP=${CPP:Q} rpcgen -C
22
23INCDIRS= -I${DESTDIR}/usr/include/rpcsvc
24
25CFLAGS+= -DYP ${INCDIRS}
26
27GENSRCS= ${RPCSRCS:R:S/$/_xdr.c/g}
28SRCS+= ${GENSRCS} ${OTHERSRCS} ${SECRPCSRCS}
29
30CLEANFILES+= ${GENSRCS}
31
32WARNS?=	1
33
34.include <bsd.lib.mk>
35
36.SUFFIXES: .x _xdr.c
37
38.x_xdr.c:
39	${RPCCOM} -c ${.IMPSRC} -o ${.TARGET}
40
41OBJS=	${RPCSRCS:R:S/$/_xdr.o/g} ${SECRPCSRCS:R:S/$/.o/g} \
42	${OTHERSRCS:R:S/$/.o/g}
43