1993-06-18 18:39:41 +00:00
|
|
|
# @(#)Makefile 5.3 (Berkeley) 5/12/90
|
1999-08-27 23:37:10 +00:00
|
|
|
# $FreeBSD$
|
1993-06-18 18:39:41 +00:00
|
|
|
|
|
|
|
PROG= gzip
|
|
|
|
SRCS= gzip.c zip.c deflate.c trees.c bits.c unzip.c inflate.c util.c \
|
1998-01-25 09:52:32 +00:00
|
|
|
crypt.c lzw.c unlzw.c unlzh.c unpack.c getopt.c
|
1997-12-26 01:53:58 +00:00
|
|
|
MAN1= gzexe.1 gzip.1 zdiff.1 zforce.1 zmore.1 znew.1
|
1998-01-25 09:52:32 +00:00
|
|
|
CFLAGS+=-DSTDC_HEADERS=1 -DHAVE_UNISTD_H=1 -DDIRENT=1
|
1997-12-21 19:15:12 +00:00
|
|
|
GREP_LIBZ?= YES
|
|
|
|
|
1998-01-25 09:52:32 +00:00
|
|
|
.if ${MACHINE_ARCH} == "i386"
|
|
|
|
SRCS+= match.S
|
|
|
|
CFLAGS+=-DASMV
|
|
|
|
.endif
|
|
|
|
|
1993-06-19 00:22:46 +00:00
|
|
|
MLINKS= gzip.1 gunzip.1 gzip.1 zcat.1 gzip.1 gzcat.1
|
1996-02-02 00:26:12 +00:00
|
|
|
MLINKS+= zdiff.1 zcmp.1
|
1997-12-26 01:53:58 +00:00
|
|
|
|
1993-07-16 17:48:38 +00:00
|
|
|
LINKS+= ${BINDIR}/gzip ${BINDIR}/gunzip
|
|
|
|
LINKS+= ${BINDIR}/gzip ${BINDIR}/gzcat
|
|
|
|
LINKS+= ${BINDIR}/gzip ${BINDIR}/zcat
|
1997-12-21 19:15:12 +00:00
|
|
|
LINKS+= ${BINDIR}/zdiff ${BINDIR}/zcmp
|
|
|
|
.if defined(GREP_LIBZ) && empty(GREP_LIBZ)
|
1996-01-23 01:00:37 +00:00
|
|
|
LINKS+= ${BINDIR}/zgrep ${BINDIR}/zegrep
|
|
|
|
LINKS+= ${BINDIR}/zgrep ${BINDIR}/zfgrep
|
1997-12-26 01:53:58 +00:00
|
|
|
MLINKS+= zgrep.1 zfgrep.1 zgrep.1 zegrep.1
|
|
|
|
MAN1+= zgrep.1
|
1997-12-21 19:15:12 +00:00
|
|
|
.endif
|
1993-06-18 18:39:41 +00:00
|
|
|
|
1997-12-21 19:15:12 +00:00
|
|
|
NOSHARED?=yes
|
1997-12-20 19:20:33 +00:00
|
|
|
ZGREP=zgrep.getopt
|
|
|
|
|
1996-01-23 01:00:37 +00:00
|
|
|
beforeinstall:
|
1995-07-25 00:37:58 +00:00
|
|
|
${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m ${BINMODE} \
|
1993-06-18 18:39:41 +00:00
|
|
|
${.CURDIR}/zforce ${.CURDIR}/gzexe ${.CURDIR}/znew \
|
1996-08-28 15:45:32 +00:00
|
|
|
${.CURDIR}/zmore ${.CURDIR}/zdiff \
|
1993-06-18 18:39:41 +00:00
|
|
|
${DESTDIR}${BINDIR}
|
1997-12-21 19:15:12 +00:00
|
|
|
.if defined(GREP_LIBZ) && empty(GREP_LIBZ)
|
1996-07-02 23:01:01 +00:00
|
|
|
${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m ${BINMODE} \
|
1997-12-20 19:20:33 +00:00
|
|
|
${.CURDIR}/${ZGREP} ${DESTDIR}${BINDIR}/zgrep
|
1997-12-21 19:15:12 +00:00
|
|
|
.endif
|
1993-06-18 18:39:41 +00:00
|
|
|
|
|
|
|
match.o: ${.CURDIR}/match.S
|
1998-03-08 17:25:10 +00:00
|
|
|
$(CC) -E -traditional ${.CURDIR}/match.S >_match.s
|
1993-06-18 18:39:41 +00:00
|
|
|
$(CC) -c _match.s
|
1996-05-07 23:19:49 +00:00
|
|
|
mv -f _match.o match.o
|
1993-06-18 18:39:41 +00:00
|
|
|
rm -f _match.s
|
|
|
|
|
|
|
|
.include <bsd.prog.mk>
|