Makefile revision 91758
1219820Sjeff# $FreeBSD: head/usr.bin/awk/Makefile 91758 2002-03-06 18:06:39Z obrien $ 2219820Sjeff 3219820SjeffAWKSRC= ${.CURDIR}/../../contrib/one-true-awk 4219820Sjeff.PATH: ${AWKSRC} 5219820Sjeff 6219820SjeffPROG= nawk 7219820SjeffSRCS= b.c lex.c lib.c main.c parse.c proctab.c run.c tran.c ytab.c ytab.h 8219820Sjeff 9219820Sjeff# Important for ctype macros! 10219820SjeffCFLAGS+= -funsigned-char 11219820SjeffCFLAGS+= -I. -I${AWKSRC} 12219820Sjeff 13219820SjeffDPADD+= ${LIBM} 14219820SjeffLDADD+= -lm 15219820Sjeff 16219820Sjeff.if ${MACHINE_ARCH} == "sparc64" 17219820SjeffLINKS+= ${BINDIR}/nawk ${BINDIR}/awk 18219820SjeffMLINKS+= nawk.1 awk.1 19219820Sjeff.endif 20219820Sjeff 21219820SjeffCLEANFILES+= maketab proctab.c ytab.c ytab.h 22219820Sjeff 23219820Sjeff.ORDER: ytab.c ytab.h proctab.c 24219820Sjeffytab.c ytab.h: ${AWKSRC}/awkgram.y 25219820Sjeff @echo Expect 42 reduce/shift conflicts and 83 reduce/reduce conflicts 26219820Sjeff ${YACC} -d ${AWKSRC}/awkgram.y 27219820Sjeff mv -f y.tab.c ytab.c 28219820Sjeff mv -f y.tab.h ytab.h 29219820Sjeff 30219820Sjeffproctab.c: maketab 31219820Sjeff ./maketab > proctab.c 32219820Sjeff 33219820Sjeffbuild-tools: maketab 34219820Sjeffmaketab: ytab.h ${AWKSRC}/maketab.c 35219820Sjeff ${CC} ${CFLAGS} ${AWKSRC}/maketab.c -o maketab 36219820Sjeff 37219820Sjeffnawk.1: awk.1 38219820Sjeff ln -sf ${.ALLSRC} ${.TARGET} 39219820Sjeff 40219820Sjeff.include <bsd.prog.mk> 41219820Sjeff