Makefile revision 172593
150472Speter# $FreeBSD: head/gnu/usr.bin/diff/Makefile 172593 2007-10-12 18:03:00Z obrien $
230842Sache
3170758SdelphijDIFFSRC=${.CURDIR}/../../../contrib/diff/src
4170758Sdelphij.PATH: ${DIFFSRC} \
5170758Sdelphij       ${.CURDIR}/../../../contrib/diff/lib \
6170758Sdelphij       ${.CURDIR}/../../../contrib/diff/man
730842Sache
867SnatePROG=	diff
9170758SdelphijSRCS=   analyze.c context.c diff.c dir.c ed.c ifdef.c io.c \
10170758Sdelphij	normal.c side.c util.c \
11170758Sdelphij	xmalloc.c strtoumax.c cmpbuf.c exitfail.c error.c quotesys.c \
12170758Sdelphij	strftime.c c-stack.c basename.c exclude.c hard-locale.c \
13170758Sdelphij	file-type.c posixver.c prepargs.c version-etc.c
1430842Sache
1530842Sache# Important for ctype macros!
1630842SacheCFLAGS+=-funsigned-char
1730842Sache
18172593SobrienCFLAGS+=-DHAVE_CONFIG_H
19172593SobrienCFLAGS+=-DPR_PROGRAM=\"/usr/bin/pr\"
20170758SdelphijCFLAGS+=-I${DESTDIR}/usr/include/gnu
21170758SdelphijCFLAGS+=-I${.CURDIR}/../../../contrib/diff
22170758SdelphijCFLAGS+=-I${.CURDIR}/../../../contrib/diff/src
23170758SdelphijCFLAGS+=-I${.CURDIR}/../../../contrib/diff/lib
2467Snate
2553704SobrienSUBDIR+=doc
2611909Speter
27125503SruDPADD=	${LIBGNUREGEX}
28125503SruLDADD=	-lgnuregex
295500Sache
30170758Sdelphij.for f in diff.c context.c
31170758Sdelphij${f}: ${DIFFSRC}/${f} ${.CURDIR}/${f}.diff
32170758Sdelphij	patch -s -b .orig -o ${.TARGET} < ${.CURDIR}/${f}.diff ${DIFFSRC}/${f}
33170758SdelphijCLEANFILES+= ${f}
34170758Sdelphij.endfor
35170758Sdelphij
3667Snate.include <bsd.prog.mk>
37