1# 2# $FreeBSD$ 3# 4 5LIB= z 6SHLIBDIR?= /lib 7MAN= zlib.3 8 9#CFLAGS+= -DMAX_WBITS=14 -DMAX_MEM_LEVEL=7 10#CFLAGS+= -g -DDEBUG 11#CFLAGS+= -Wall -Wwrite-strings -Wpointer-arith -Wconversion \ 12# -Wstrict-prototypes -Wmissing-prototypes 13 14CFLAGS+= -DHAS_snprintf -DHAS_vsnprintf 15 16WARNS?= 3 17 18CLEANFILES+= example.o example foo.gz minigzip.o minigzip 19 20SRCS = adler32.c compress.c crc32.c gzio.c uncompr.c deflate.c trees.c \ 21 zutil.c inflate.c inftrees.c inffast.c zopen.c infback.c 22INCS= zconf.h zlib.h 23 24minigzip: all minigzip.o 25 $(CC) -o minigzip minigzip.o -L. -lz 26 27example: all example.o 28 $(CC) -o example example.o -L. -lz 29 30test: example minigzip 31 (export LD_LIBRARY_PATH=. ; ./example ) 32 (export LD_LIBRARY_PATH=. ; \ 33 echo hello world | ./minigzip | ./minigzip -d ) 34 35.include <bsd.lib.mk> 36