1f1979ea2c
whose version has not already been bumped since RELENG_5 are being bumped. Revisions of files being MFC-ed: > Path Revision > src/gnu/lib/libdialog/Makefile 1.43 > src/gnu/lib/libg2c/Makefile 1.16 > src/gnu/lib/libobjc/Makefile 1.27 > src/gnu/lib/libreadline/Makefile.inc 1.12 > src/gnu/lib/libregex/Makefile 1.32 > src/gnu/lib/libstdc++/Makefile 1.56 > src/kerberos5/lib/Makefile.inc 1.7 > src/lib/Makefile.inc 1.3 > src/lib/libalias/Makefile 1.31 > src/lib/libarchive/Makefile 1.37 > src/lib/libbegemot/Makefile 1.3 > src/lib/libbluetooth/Makefile 1.2 > src/lib/libbsnmp/Makefile.inc 1.6 > src/lib/libbz2/Makefile 1.6 > src/lib/libc_r/Makefile 1.42 > src/lib/libcrypt/Makefile 1.36 > src/lib/libdevstat/Makefile 1.15 > src/lib/libdevstat/devstat.h 1.11 > src/lib/libedit/Makefile 1.29 > src/lib/libexpat/Makefile 1.5 > src/lib/libfetch/Makefile 1.45 > src/lib/libftpio/Makefile 1.14 > src/lib/libgpib/Makefile 1.2 > src/lib/libipsec/Makefile 1.17 > src/lib/libkiconv/Makefile 1.3 > src/lib/libmagic/Makefile 1.7 > src/lib/libmp/Makefile 1.10 > src/lib/libncp/Makefile 1.6 > src/lib/libncurses/Makefile 1.79 > src/lib/libnetgraph/Makefile 1.11 > src/lib/libngatm/Makefile 1.6 > src/lib/libopie/Makefile 1.21 > src/lib/libpam/Makefile.inc 1.17 > src/lib/libpthread/Makefile 1.54 > src/lib/libradius/Makefile 1.12 > src/lib/libsdp/Makefile 1.4 > src/lib/libsmb/Makefile 1.8 > src/lib/libtacplus/Makefile 1.7 > src/lib/libthr/Makefile 1.14 > src/lib/libthread_db/Makefile 1.6 > src/lib/libugidfw/Makefile 1.7 > src/lib/libusbhid/Makefile 1.10 > src/lib/libutil/Makefile 1.57 > src/lib/libvgl/Makefile 1.11 > src/lib/libwrap/Makefile 1.17 > src/lib/libypclnt/Makefile 1.13 > src/lib/msun/Makefile 1.72 > src/secure/lib/libcrypto/Makefile 1.74 > src/secure/lib/libssh/Makefile 1.35 > src/secure/lib/libssl/Makefile 1.22 > src/usr.sbin/bsnmpd/modules/Makefile.inc 1.10 Reviewed by: ru Approved by: re (scottl)
55 lines
1.3 KiB
Makefile
55 lines
1.3 KiB
Makefile
# $FreeBSD$
|
|
# Copyright (c) David E. O'Brien, 2000-2004
|
|
|
|
CONTRDIR= ${.CURDIR}/../../contrib/file
|
|
.PATH: ${CONTRDIR}
|
|
|
|
LIB= magic
|
|
SHLIB_MAJOR= 2
|
|
MAN= libmagic.3 magic.5
|
|
|
|
SRCS= apprentice.c apptype.c ascmagic.c compress.c fsmagic.c funcs.c \
|
|
is_tar.c magic.c print.c readelf.c softmagic.c
|
|
INCS= magic.h
|
|
|
|
MAGICPATH?= /usr/share/misc
|
|
|
|
CFLAGS+= -DMAGIC='"${MAGICPATH}/magic"' -DBUILTIN_ELF -DELFCORE -DHAVE_CONFIG_H
|
|
CFLAGS+= -I${.CURDIR} -I${CONTRDIR}
|
|
|
|
CLEANFILES+= magic magic.mgc magic.mime.mgc
|
|
|
|
FILES= magic magic.mgc ${CONTRDIR}/magic.mime magic.mime.mgc
|
|
FILESDIR= ${MAGICPATH}
|
|
|
|
MAGFILES= ${CONTRDIR}/Header\
|
|
${CONTRDIR}/Localstuff\
|
|
${CONTRDIR}/Magdir/[a-z]*
|
|
|
|
magic: ${MAGFILES}
|
|
cat ${.ALLSRC} > ${.TARGET}
|
|
|
|
magic.mgc: mkmagic magic
|
|
./mkmagic magic
|
|
|
|
magic.mime.mgc: mkmagic magic.mime
|
|
./mkmagic ${CONTRDIR}/magic.mime
|
|
|
|
CLEANFILES+= mkmagic
|
|
build-tools: mkmagic
|
|
mkmagic: apprentice.c funcs.c magic.c print.c
|
|
${CC} -DHAVE_CONFIG_H -DCOMPILE_ONLY \
|
|
-I${.CURDIR} -I${CONTRDIR} -o ${.TARGET} ${.ALLSRC}
|
|
|
|
FILEVER!= awk '$$1 == "\#define" && $$2 == "VERSION" { print $$3; exit }' \
|
|
${.CURDIR}/config.h
|
|
CLEANFILES+= ${MAN}
|
|
.for mp in ${MAN}
|
|
${mp}: ${mp:C/[0-9]/man/}
|
|
sed -e 's/__FSECTION__/5/g' -e 's/__CSECTION__/1/g' \
|
|
-e 's/__VERSION__/${FILEVER}/g' \
|
|
-e 's,__MAGIC__,${MAGICPATH}/magic,g' ${.ALLSRC} > ${.TARGET}
|
|
.endfor
|
|
|
|
.include <bsd.lib.mk>
|