file: libmagic knows about libz now so drop the dependency
[dragonfly.git] / usr.bin / file / Makefile
CommitLineData
c03f08f3 1# $DragonFly: src/usr.bin/file/Makefile,v 1.9 2007/08/27 16:50:53 pavalos Exp $
984263bc 2
65346b49 3CONTRIBDIR= ${.CURDIR}/../../contrib/file
81a07ed7 4.PATH: ${CONTRIBDIR}/src
984263bc 5
81a07ed7
PA
6LIBMAGICDIR= ${.CURDIR}/../../lib/libmagic
7CS= 1
8FS= 5
9VER!= grep -w VERSION ${LIBMAGICDIR}/config.h | awk -F\" '{print $$2}'
7dbde16c 10MAGIC= /usr/share/misc/magic
984263bc 11
7dbde16c 12PROG= file
9c152dde 13MAN= file.1 magic.5
984263bc 14
7dbde16c 15CFLAGS+= -DHAVE_CONFIG_H -DMAGIC=\"${MAGIC}\"
81a07ed7 16CFLAGS+= -I${LIBMAGICDIR}
984263bc 17
e3b736ab
FF
18LDADD+= -lmagic
19DPADD+= ${LIBMAGIC}
984263bc 20
81a07ed7
PA
21file.1: ${CONTRIBDIR}/doc/file.man
22 sed -e s@__CSECTION__@${CS}@g \
23 -e s@__FSECTION__@${FS}@g \
24 -e s@__VERSION__@${VER}@g \
25 -e s@__MAGIC__@${MAGIC}@g ${.ALLSRC} > ${.TARGET}
26
27magic.5: ${CONTRIBDIR}/doc/magic.man
28 sed -e s@__CSECTION__@${CS}@g \
29 -e s@__FSECTION__@${FS}@g \
30 -e s@__VERSION__@${VER}@g \
31 -e s@__MAGIC__@${MAGIC}@g ${.ALLSRC} > ${.TARGET}
32
33CLEANFILES+= file.1 magic.5
984263bc 34.include <bsd.prog.mk>