NetBSD/usr.sbin/rpc.pcnfsd/Makefile

41 lines
1022 B
Makefile

# $NetBSD: Makefile,v 1.14 2002/09/14 05:35:13 thorpej Exp $
.include <bsd.own.mk>
PROG= rpc.pcnfsd
MAN= pcnfsd.8
MLINKS= pcnfsd.8 rpc.pcnfsd.8
CPPFLAGS += -DUSER_CACHE -DWTMP -I. -DSUPPORT_UTMP -DSUPPORT_UTMPX
.if (${USE_YP} != "no")
CPPFLAGS+=-DUSE_YP
.endif
SRCS= pcnfsd_v1.c pcnfsd_v2.c pcnfsd_misc.c \
pcnfsd_cache.c pcnfsd_print.c pcnfsd_svc.c pcnfsd_xdr.c
DPADD= ${LIBRPCSVC} ${LIBCRYPT} ${LIBUTIL}
LDADD= -lrpcsvc -lcrypt -lutil
# Resolve rpcgen's path, to allow it to be a dependency.
_RPCGEN:= ${RPCGEN:M*rpcgen}
.if ${_RPCGEN:M/*} == ""
_RPCGEN!= type ${RPCGEN} | awk '{print $$NF}'
.endif
pcnfsd_svc.c: pcnfsd.x ${_RPCGEN}
${RPCGEN} -C -s udp -s tcp -I ${.CURDIR}/pcnfsd.x -o $@
pcnfsd_xdr.c: pcnfsd.x ${_RPCGEN}
${RPCGEN} -C -c ${.CURDIR}/pcnfsd.x -o $@
pcnfsd.h: pcnfsd.x ${_RPCGEN}
${RPCGEN} -C -h ${.CURDIR}/pcnfsd.x -o $@
CLEANFILES += pcnfsd_svc.c pcnfsd_xdr.c pcnfsd.h
CLEANFILES += clnt.pcnfsd pcnfsd_test.o pcnfsd_test.ln pcnfsd_clnt.*
.include <bsd.prog.mk>
.depend ${OBJS}: pcnfsd.h