2001-03-27 12:45:02 +04:00
|
|
|
# $NetBSD: Makefile,v 1.29 2001/03/27 08:45:02 pooka Exp $
|
1999-02-13 05:54:17 +03:00
|
|
|
|
|
|
|
.include <bsd.own.mk>
|
1993-08-02 21:48:44 +04:00
|
|
|
|
2000-10-11 18:46:00 +04:00
|
|
|
WFORMAT= 1
|
1998-09-27 21:22:03 +04:00
|
|
|
MFILESDIR= /usr/share/misc
|
2001-03-27 04:48:59 +04:00
|
|
|
MFILES= magic magic.mgc magic.mime
|
2000-05-15 02:53:37 +04:00
|
|
|
MAGIC= ${MFILESDIR}/magic
|
1999-02-13 05:54:17 +03:00
|
|
|
.if ${MKSHARE} != "no"
|
1998-09-27 21:22:03 +04:00
|
|
|
FILESDIR= ${MFILESDIR}
|
|
|
|
FILES= ${MFILES}
|
|
|
|
.endif
|
1993-03-21 12:45:37 +03:00
|
|
|
|
1993-06-10 04:37:55 +04:00
|
|
|
PROG= file
|
|
|
|
SRCS= file.c apprentice.c fsmagic.c softmagic.c ascmagic.c is_tar.c \
|
2000-09-22 20:34:59 +04:00
|
|
|
print.c compress.c readelf.c
|
1999-11-01 20:39:26 +03:00
|
|
|
CPPFLAGS+= -DMAGIC='"$(MAGIC)"' -DHAVE_CONFIG_H -I${.CURDIR}
|
2001-03-27 04:48:59 +04:00
|
|
|
CPPFLAGS+= -DQUICK -DBUILTIN_ELF -DELFCORE
|
1994-12-22 15:29:38 +03:00
|
|
|
MAN= file.1 magic.5
|
1993-03-21 12:45:37 +03:00
|
|
|
|
2001-03-27 04:53:43 +04:00
|
|
|
CLEANFILES+= magic magic.mgc
|
2000-01-23 21:00:38 +03:00
|
|
|
realall: file magic
|
1993-06-10 04:37:55 +04:00
|
|
|
|
1997-05-18 01:15:35 +04:00
|
|
|
MAGDIRF:sh= echo $(.CURDIR)/magdir/[0-9a-z]*
|
1998-09-20 19:27:15 +04:00
|
|
|
MAGFILES= $(.CURDIR)/Header \
|
|
|
|
$(.CURDIR)/Localstuff \
|
1997-04-03 11:17:24 +04:00
|
|
|
$(.CURDIR)/magdir/netbsd \
|
1997-05-18 01:15:35 +04:00
|
|
|
${MAGDIRF}
|
1997-03-25 00:57:01 +03:00
|
|
|
|
1999-02-13 05:54:17 +03:00
|
|
|
.if ${MKSHARE} != "no"
|
1993-06-10 04:37:55 +04:00
|
|
|
magic: $(MAGFILES)
|
|
|
|
cat $(MAGFILES) > $(.TARGET)
|
2001-03-27 12:45:02 +04:00
|
|
|
$(.OBJDIR)/$(PROG) -C -m $(.TARGET)
|
1998-09-27 21:22:03 +04:00
|
|
|
.else
|
|
|
|
magic:
|
|
|
|
.endif
|
1993-03-21 12:45:37 +03:00
|
|
|
|
|
|
|
.include <bsd.prog.mk>
|