1
0
mirror of https://git.FreeBSD.org/ports.git synced 2024-12-25 04:43:33 +00:00
freebsd-ports/archivers/minizip/Makefile
Matthias Andree de671468c9 Provide our own distfile mirror that is fetchable through http:// and ftp://.
Move pkg-plist into Makefile's PLIST_FILES.
2014-01-18 00:03:56 +00:00

44 lines
1.3 KiB
Makefile

# Created by: lbartoletti <coder@tuxfamily.org>
# $FreeBSD$
PORTNAME= minizip
PORTVERSION= 1.2.8
CATEGORIES= archivers
MASTER_SITES= https://github.com/madler/zlib/archive/ \
LOCAL/mandree/${PORTNAME}
DISTNAME= v${PORTVERSION}
DIST_SUBDIR= ${PORTNAME}
MAINTAINER= coder@tuxfamily.org
COMMENT= Minizip and miniunz programs from Zlib contributions
LICENSE= ZLIB
PLIST_FILES= bin/minizip bin/miniunz \
man/man1/miniunzip.1.gz man/man1/minizip.1.gz
MAKE_ARGS= CFLAGS="${CPPFLAGS} ${CFLAGS} -include sys/stat.h -include stdint.h"
USE_ZIP= yes
WRKSRC= ${WRKDIR}/zlib-${PORTVERSION}/contrib/minizip
.include <bsd.port.pre.mk>
# work around missing typedef in 8.X's libz configuration
.if ${OSVERSION} < 900000
CPPFLAGS+= -Dz_crc_t=uint32_t
.endif
post-patch:
${REINPLACE_CMD} -e 's/#ifdef unix \|\| __APPLE__/#ifdef unix/' ${WRKSRC}/mini???.c
do-install:
${INSTALL_PROGRAM} ${WRKSRC}/${PORTNAME} ${WRKSRC}/miniunz ${STAGEDIR}${PREFIX}/bin/
${INSTALL_MAN} ${WRKSRC}/*.1 ${STAGEDIR}${PREFIX}/man/man1
regression-test:
${RM} -f ${WRKDIR}/test.zip && (cd ${WRKSRC} && ./${PORTNAME} ${WRKDIR}/test.zip *)
${RM} -rf ${WRKDIR}/regression-test && ${MKDIR} ${WRKDIR}/regression-test
${WRKSRC}/miniunz ${WRKDIR}/test.zip -d ${WRKDIR}/regression-test
diff -ur >/dev/null ${WRKSRC} ${WRKDIR}/regression-test
.include <bsd.port.post.mk>