xref: /freebsd/lib/libz/Makefile (revision b1c8a8dffe810f746b3733b8033880b338f06501)
1#
2# $Id$
3#
4
5MAINTAINER=peter@FreeBSD.org
6
7LIB=		z
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
14CLEANFILES+=	example.o example minigzip.o minigzip
15
16SRCS = adler32.c compress.c crc32.c gzio.c uncompr.c deflate.c trees.c \
17       zutil.c inflate.c infblock.c inftrees.c infcodes.c infutil.c inffast.c
18
19beforeinstall:
20	${INSTALL} -c -m 644 -o ${BINOWN} -g ${BINGRP} zlib.h zconf.h \
21		${DESTDIR}/usr/include
22
23minigzip:	all minigzip.o
24	$(CC) -o minigzip minigzip.o -L. -lz
25
26example:	all example.o
27	$(CC) -o example example.o -L. -lz
28
29test: example minigzip
30	(export LD_LIBRARY_PATH=. ; ./example )
31	(export LD_LIBRARY_PATH=. ; \
32		echo hello world | ./minigzip | ./minigzip -d )
33
34
35.include <bsd.lib.mk>
36