Home | History | Annotate | Line # | Download | only in ipnat
Makefile revision 1.1
      1 #	$NetBSD: Makefile,v 1.1 2012/03/23 21:29:45 christos Exp $
      2 
      3 PROG=		ipnat
      4 SRCS=		ipnat.c ipnat_y.c ipnat_l.c
      5 MAN=		ipnat.8 ipnat.4 ipnat.5
      6 MLINKS=		ipnat.5 ipnat.conf.5
      7 CPPFLAGS+=	-I.
      8 
      9 DPSRCS+=	ipnat_l.h ipnat_y.h
     10 
     11 CLEANFILES+=	ipnat_y.c ipnat_y.h
     12 CLEANFILES+=	ipnat_l.c ipnat_l.h
     13 
     14 ipnat_y.c: ipnat_y.y
     15 	${_MKTARGET_CREATE}
     16 	${YACC} -d ${.ALLSRC}
     17 	${TOOL_SED} -e 's/yy/ipnat_yy/g' \
     18 	    -e 's/y.tab.c/ipnat_y.c/' \
     19 	    -e s/\"ipnat_y.y\"/\"..\\/tools\\/ipnat_y.y\"/ \
     20 	    y.tab.c > ${.TARGET}
     21 	${TOOL_SED} -e 's/yy/ipnat_yy/g' \
     22 	    -e 's/y.tab.h/ipnat_y.h/' \
     23 	    y.tab.h > ${.TARGET:.c=.h}
     24 
     25 ipnat_y.h: ipnat_y.c
     26 
     27 ipnat_l.c: lexer.c
     28 	${_MKTARGET_CREATE}
     29 	${TOOL_SED} -e 's/yy/ipnat_yy/g' \
     30 	    -e 's/y.tab.h/ipnat_y.h/' \
     31 	    -e 's/lexer.h/ipnat_l.h/' \
     32 	    ${.ALLSRC} > ${.TARGET}
     33 
     34 ipnat_l.h: lexer.h
     35 	${_MKTARGET_CREATE}
     36 	${TOOL_SED} -e 's/yy/ipnat_yy/g' \
     37 	    ${.ALLSRC} > ${.TARGET}
     38 
     39 .include <bsd.prog.mk>
     40