2015-09-07 06:44:19 +03:00
|
|
|
# $NetBSD: Makefile,v 1.21 2015/09/07 03:44:19 uebayasi Exp $
|
1997-01-16 03:19:04 +03:00
|
|
|
|
|
|
|
LIB= z
|
2011-10-30 04:28:57 +04:00
|
|
|
LIBISPRIVATE= yes
|
1997-01-16 03:19:04 +03:00
|
|
|
|
2006-01-14 23:15:38 +03:00
|
|
|
ZDISTDIR:=${.PARSEDIR}/../../../common/dist/zlib
|
1999-05-07 18:28:50 +04:00
|
|
|
|
2007-06-23 14:50:24 +04:00
|
|
|
CPPFLAGS+= -I${ZDISTDIR} ${ZCPPFLAGS} ${ZMISCCPPFLAGS}
|
2006-01-14 23:15:38 +03:00
|
|
|
|
|
|
|
.PATH.c: ${ZDISTDIR} ${.PARSEDIR}
|
1997-01-16 03:19:04 +03:00
|
|
|
|
|
|
|
# files to be copied down from libz.
|
2009-03-25 21:41:06 +03:00
|
|
|
LIBZSRCS= adler32.c compress.c deflate.c infback.c inffast.c \
|
2006-01-14 23:15:38 +03:00
|
|
|
inflate.c inftrees.c trees.c uncompr.c
|
2009-03-25 21:41:06 +03:00
|
|
|
LIBZHDRS= deflate.h inffast.h inffixed.h inflate.h inftrees.h \
|
2006-01-14 23:15:38 +03:00
|
|
|
trees.h zconf.h zlib.h
|
1997-01-16 03:19:04 +03:00
|
|
|
|
|
|
|
# Other stuff
|
1999-04-15 04:52:58 +04:00
|
|
|
SRCS= ${LIBZSRCS} zalloc.c
|
1997-01-16 03:19:04 +03:00
|
|
|
|
|
|
|
# Files to clean up
|
|
|
|
CLEANFILES+= lib${LIB}.o
|
|
|
|
|
2001-11-15 00:59:31 +03:00
|
|
|
.undef DESTDIR
|
1997-01-16 03:19:04 +03:00
|
|
|
.include <bsd.lib.mk>
|
|
|
|
|
2015-09-07 06:44:19 +03:00
|
|
|
lib${LIB}.o:: ${OBJS:O}
|
1997-01-16 03:19:04 +03:00
|
|
|
@echo building standard ${LIB} library
|
|
|
|
@rm -f lib${LIB}.o
|
|
|
|
@${LD} -r -o lib${LIB}.o `lorder ${OBJS} | tsort`
|
2015-09-07 06:20:18 +03:00
|
|
|
@echo done
|
2011-07-03 19:29:34 +04:00
|
|
|
|
2014-06-15 00:49:36 +04:00
|
|
|
.if defined(HAVE_GCC) && ${MACHINE_ARCH} == "vax"
|
2011-07-03 19:29:34 +04:00
|
|
|
COPTS.inftrees.c+= -O0
|
|
|
|
.endif
|