Makefile revision 1.36
11.36Slukem#	$NetBSD: Makefile,v 1.36 2002/08/19 14:55:16 lukem Exp $
21.36Slukem
31.36SlukemNOMAN=		# defined
41.36SlukemNOPIC=		# defined
51.4Sbrezak
61.10ScgdRPCSRCS=	bootparam_prot.x klm_prot.x mount.x nfs_prot.x\
71.8Sjtc		nlm_prot.x rex.x rnusers.x rusers.x rquota.x rstat.x rwall.x\
81.8Sjtc		sm_inter.x spray.x yp.x yppasswd.x
91.21SmycroftSRCS=		${RPCSRCS:.x=.c} ${HDRS}
101.21SmycroftHDRS=           ${RPCSRCS:.x=.h}
111.8SjtcCLEANFILES+=	${SRCS} ${HDRS}
121.8Sjtc
131.21SmycroftINCS=		${HDRS} ${RPCSRCS}
141.21SmycroftINCSDIR=	/usr/include/rpcsvc
151.19Schristos
161.8SjtcLIB=		rpcsvc
171.8Sjtc
181.32Stv.include <bsd.lib.mk>
191.26Serh
201.33Stv# Resolve rpcgen's path, to allow it to be a dependency.
211.35Stv_RPCGEN:=	${RPCGEN:M*rpcgen}
221.33Stv.if ${_RPCGEN:M/*} == ""
231.33Stv_RPCGEN!=	type ${RPCGEN} | awk '{print $$NF}'
241.33Stv.endif
251.33Stv
261.19Schristos# We don't use explicit suffix rules here to avoid dependencies in the
271.19Schristos# Installed files.
281.19Schristos
291.19Schristos.for I in ${RPCSRCS}
301.33Stv${I:.x=.c}: $I ${_RPCGEN}
311.31Smycroft	${RPCGEN} -C -c ${.CURDIR}/$I -o ${.TARGET}
321.26Serh
331.33Stv${I:.x=.h}: $I ${_RPCGEN}
341.31Smycroft	${RPCGEN} -C -h ${.CURDIR}/$I -o ${.TARGET}
351.19Schristos.endfor
36