1995-12-23 21:35:35 +00:00
|
|
|
# $Id: Makefile,v 1.2 1995/12/16 23:01:04 bde Exp $
|
1995-12-16 20:54:17 +00:00
|
|
|
|
|
|
|
PROG= ypserv
|
|
|
|
SRCS= yp_svc.c yp_server.c yp_dblookup.c yp_dnslookup.c \
|
1995-12-23 21:35:35 +00:00
|
|
|
ypxfr_clnt.c yp_main.c yp_error.c yp_access.c
|
1995-12-16 20:54:17 +00:00
|
|
|
|
|
|
|
MAN8= ypserv.8
|
|
|
|
|
1995-12-16 23:01:04 +00:00
|
|
|
CFLAGS+= -I.
|
|
|
|
|
1995-12-23 21:35:35 +00:00
|
|
|
CLEANFILES= yp_svc.c ypxfr_clnt.c yp.h
|
1995-12-16 20:54:17 +00:00
|
|
|
|
|
|
|
RPCSRC= ${.DESTDIR}/usr/include/rpcsvc/yp.x
|
1995-12-23 21:35:35 +00:00
|
|
|
RPCGEN= rpcgen -I -C
|
1995-12-16 20:54:17 +00:00
|
|
|
|
|
|
|
# We need to remove the 'static' keyword from _rpcsvcstate so that
|
|
|
|
# yp_main.c can see it.
|
|
|
|
yp_svc.c: ${RPCSRC} yp.h
|
|
|
|
rm -f ${.TARGET}
|
1995-12-23 21:35:35 +00:00
|
|
|
${RPCGEN} -DYPSERV_ONLY -m ${RPCSRC} | \
|
1995-12-16 20:54:17 +00:00
|
|
|
sed s/"static int _rpcsvcstate"/"int _rpcsvcstate"/g > ${.TARGET}
|
|
|
|
|
1995-12-23 21:35:35 +00:00
|
|
|
ypxfr_clnt.c: ${RPCSRC} yp.h
|
|
|
|
${RPCGEN} -DYPPUSH_ONLY -l -o ${.TARGET} ${RPCSRC}
|
1995-12-16 20:54:17 +00:00
|
|
|
|
|
|
|
yp.h: ${RPCSRC}
|
|
|
|
${RPCGEN} -h -o ${.TARGET} ${RPCSRC}
|
|
|
|
|
|
|
|
afterinstall:
|
|
|
|
${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 444 \
|
|
|
|
${.CURDIR}/Makefile.yp \
|
|
|
|
${DESTDIR}/var/yp/Makefile
|
|
|
|
${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m ${BINMODE} \
|
|
|
|
${.CURDIR}/mknetid \
|
|
|
|
${DESTDIR}/usr/libexec/mknetid
|
|
|
|
|
|
|
|
.include <bsd.prog.mk>
|