diff options
author | Tijl Coosemans <tijl@FreeBSD.org> | 2014-06-02 20:38:38 +0000 |
---|---|---|
committer | Tijl Coosemans <tijl@FreeBSD.org> | 2014-06-02 20:38:38 +0000 |
commit | 044449c06a1131d65f782ef26b6bbe51123ee7f7 (patch) | |
tree | 993d07bdc94c56e1d95be69acac1c6bb1535dd86 /archivers | |
parent | Properly respect CFLAGS, LDFLAGS, etc. (diff) |
Enable the libminizip library which will be used by multimedia/vlc:
- Use the standard MASTER_SITE for zlib.
- Replace PLIST_FILES with a separate pkg-plist.
- Instead of using the bundled "Makefile" set USE_AUTOTOOLS to generate
a new Makefile from Makefile.am that allows building libminizip.so.
Also remove MAKE_ARGS, do-install and patch-contrib-minizip-Makefile.
- Silence post-patch.
- Adjust regression-test.
PR: 190179
Approved by: bapt
Notes
Notes:
svn path=/head/; revision=356248
Diffstat (limited to 'archivers')
-rw-r--r-- | archivers/minizip/Makefile | 43 | ||||
-rw-r--r-- | archivers/minizip/distinfo | 4 | ||||
-rw-r--r-- | archivers/minizip/files/patch-contrib-minizip-Makefile | 28 | ||||
-rw-r--r-- | archivers/minizip/pkg-plist | 15 |
4 files changed, 41 insertions, 49 deletions
diff --git a/archivers/minizip/Makefile b/archivers/minizip/Makefile index 17f3d48819a0..399e437abbea 100644 --- a/archivers/minizip/Makefile +++ b/archivers/minizip/Makefile @@ -3,24 +3,25 @@ PORTNAME= minizip PORTVERSION= 1.2.8 +PORTREVISION= 1 CATEGORIES= archivers -MASTER_SITES= https://github.com/madler/zlib/archive/ \ - LOCAL/mandree/${PORTNAME} -DISTNAME= v${PORTVERSION} -DIST_SUBDIR= ${PORTNAME} +MASTER_SITES= SF/libpng/zlib/${PORTVERSION} +DISTNAME= zlib-${PORTVERSION} MAINTAINER= coder@tuxfamily.org -COMMENT= Minizip and miniunz programs from Zlib contributions +COMMENT= Zip library and programs from Zlib distribution LICENSE= ZLIB -USES= zip -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" +USES= libtool pathfix tar:xz +PATHFIX_MAKEFILEIN= Makefile.am +USE_AUTOTOOLS= libtoolize aclocal autoconf automake +AUTOMAKE_ARGS= -a -c -f +CONFIGURE_ARGS= --enable-demos +INSTALL_TARGET= install-strip WRKSRC= ${WRKDIR}/zlib-${PORTVERSION}/contrib/minizip -.include <bsd.port.pre.mk> +.include <bsd.port.options.mk> # work around missing typedef in 8.X's libz configuration .if ${OSVERSION} < 900000 @@ -28,16 +29,20 @@ CPPFLAGS+= -Dz_crc_t=uint32_t .endif post-patch: - ${REINPLACE_CMD} -e 's/#ifdef unix \|\| __APPLE__/#ifdef unix/' ${WRKSRC}/mini???.c + @${REINPLACE_CMD} 's/#ifdef unix || __APPLE__/#ifdef unix/' ${WRKSRC}/mini???.c -do-install: - ${INSTALL_PROGRAM} ${WRKSRC}/${PORTNAME} ${WRKSRC}/miniunz ${STAGEDIR}${PREFIX}/bin/ +post-install: ${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> + ${RM} -rf ${WRKDIR}/regression-test1 + ${MKDIR} ${WRKDIR}/regression-test1 + ${MV} ${WRKSRC}/*.[cho] ${WRKDIR}/regression-test1 + ${RM} -f ${WRKDIR}/test.zip + (cd ${WRKDIR}/regression-test1 && ${WRKSRC}/minizip ${WRKDIR}/test.zip *) + ${RM} -rf ${WRKDIR}/regression-test2 + ${MKDIR} ${WRKDIR}/regression-test2 + ${WRKSRC}/miniunzip ${WRKDIR}/test.zip -d ${WRKDIR}/regression-test2 + ${DIFF} -ur ${WRKDIR}/regression-test1 ${WRKDIR}/regression-test2 > /dev/null + +.include <bsd.port.mk> diff --git a/archivers/minizip/distinfo b/archivers/minizip/distinfo index 136f9adf52f0..8e85cae5b8d7 100644 --- a/archivers/minizip/distinfo +++ b/archivers/minizip/distinfo @@ -1,2 +1,2 @@ -SHA256 (minizip/v1.2.8.zip) = da78eabfef55cbab21776d4cca207cf7e0dde483b4dd3590e525421667bfb6a7 -SIZE (minizip/v1.2.8.zip) = 724598 +SHA256 (zlib-1.2.8.tar.xz) = 831df043236df8e9a7667b9e3bb37e1fcb1220a0f163b6de2626774b9590d057 +SIZE (zlib-1.2.8.tar.xz) = 450776 diff --git a/archivers/minizip/files/patch-contrib-minizip-Makefile b/archivers/minizip/files/patch-contrib-minizip-Makefile deleted file mode 100644 index 70016010bba4..000000000000 --- a/archivers/minizip/files/patch-contrib-minizip-Makefile +++ /dev/null @@ -1,28 +0,0 @@ ---- Makefile.orig 2013-04-29 02:23:49.000000000 +0200 -+++ Makefile 2013-12-10 10:06:34.000000000 +0100 -@@ -1,8 +1,9 @@ - CC=cc --CFLAGS=-O -I../.. -+CFLAGS=-O -I/usr/local -+LDFLAGS=-L/usr/lib -lz - --UNZ_OBJS = miniunz.o unzip.o ioapi.o ../../libz.a --ZIP_OBJS = minizip.o zip.o ioapi.o ../../libz.a -+UNZ_OBJS = miniunz.o unzip.o ioapi.o -+ZIP_OBJS = minizip.o zip.o ioapi.o - - .c.o: - $(CC) -c $(CFLAGS) $*.c -@@ -10,10 +11,10 @@ - all: miniunz minizip - - miniunz: $(UNZ_OBJS) -- $(CC) $(CFLAGS) -o $@ $(UNZ_OBJS) -+ $(CC) $(CFLAGS) $(LDFLAGS) -o $@ $(UNZ_OBJS) - - minizip: $(ZIP_OBJS) -- $(CC) $(CFLAGS) -o $@ $(ZIP_OBJS) -+ $(CC) $(CFLAGS) $(LDFLAGS) -o $@ $(ZIP_OBJS) - - test: miniunz minizip - ./minizip test readme.txt diff --git a/archivers/minizip/pkg-plist b/archivers/minizip/pkg-plist new file mode 100644 index 000000000000..505035549a88 --- /dev/null +++ b/archivers/minizip/pkg-plist @@ -0,0 +1,15 @@ +bin/miniunzip +bin/minizip +include/minizip/crypt.h +include/minizip/ioapi.h +include/minizip/mztools.h +include/minizip/unzip.h +include/minizip/zip.h +lib/libminizip.a +lib/libminizip.so +lib/libminizip.so.1 +lib/libminizip.so.1.0.0 +libdata/pkgconfig/minizip.pc +man/man1/miniunzip.1.gz +man/man1/minizip.1.gz +@dirrm include/minizip |