xref: /freebsd/usr.sbin/rpc.ypxfrd/Makefile (revision e9ac41698b2f322d55ccf9da50a3596edb2c1800)
133bfdd50SEnji Cooper.PATH: ${SRCTOP}/usr.sbin/ypserv
216118c2bSBill Paul
3*5abb10faSEmmanuel VadotPACKAGE=yp
490e655eaSDavid E. O'BrienPROG=	rpc.ypxfrd
5345e52e7SRuslan ErmilovMAN=	rpc.ypxfrd.8
690e655eaSDavid E. O'BrienSRCS=	ypxfrd_svc.c ypxfrd.h ypxfrd_server.c yp_error.c \
790e655eaSDavid E. O'Brien	yp_access.c ypxfrd_main.c
8345e52e7SRuslan Ermilov
916118c2bSBill PaulCFLAGS+= -I. -DXFRBLOCKSIZE=65535
1016118c2bSBill Paul
1171ccf092SEd SchoutenWARNS?=	2
1271ccf092SEd Schouten
13c6db8143SBaptiste DaroussinLIBADD=	rpcsvc
1416118c2bSBill Paul
1516118c2bSBill PaulCLEANFILES= ypxfrd_svc.c ypxfrd.h
1616118c2bSBill Paul
1733bfdd50SEnji CooperRPCDIR=	${SRCTOP}/include/rpcsvc
185e0a19bdSDimitry AndricRPCGEN= RPCGEN_CPP=${CPP:Q} rpcgen -I -C
1916118c2bSBill Paul
2016118c2bSBill Paul# We need to remove the 'static' keyword from _rpcsvcstate so that
2116118c2bSBill Paul# ypxfrd_main.c can see it.
22930ef4e2SBruce Evansypxfrd_svc.c: ${RPCDIR}/ypxfrd.x
2316118c2bSBill Paul	rm -f ${.TARGET}
2433bfdd50SEnji Cooper	${RPCGEN} -m ${.ALLSRC} | \
2516118c2bSBill Paul	sed s/"static int _rpcsvcstate"/"int _rpcsvcstate"/g > ${.TARGET}
2616118c2bSBill Paul
27930ef4e2SBruce Evans# ypxfrd_xdr.c: ${RPCDIR}/ypxfrd.x
2816118c2bSBill Paul#	rm -f ${.TARGET}
2916118c2bSBill Paul#	${RPCGEN} -c -o ${.TARGET} ${RPCDIR}/ypxfrd.x
3016118c2bSBill Paul
3116118c2bSBill Paulypxfrd.h: ${RPCDIR}/ypxfrd.x
3216118c2bSBill Paul	rm -f ${.TARGET}
3333bfdd50SEnji Cooper	${RPCGEN} -h -o ${.TARGET} ${.ALLSRC}
3416118c2bSBill Paul
3516118c2bSBill Paul.include <bsd.prog.mk>
36