- Update to version 0.6.5 [1]

- Fix build when WITH_BUNDLED_LIBPNG=true

PR:		ports/156376 [1]
Submitted by:	Anton Yuzhaninov <ayuzhaninov@team.vega.ru> [1]
Approved by:	maintainer timeout
This commit is contained in:
Pawel Pekala 2011-12-29 14:07:57 +00:00
parent 0f1ab7dfed
commit 2b0f2325b6
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=288227
7 changed files with 39 additions and 41 deletions

View File

@ -6,7 +6,7 @@
#
PORTNAME= optipng
PORTVERSION= 0.6.4
PORTVERSION= 0.6.5
CATEGORIES= graphics
MASTER_SITES= SF/${PORTNAME}/OptiPNG/${PORTNAME}-${PORTVERSION}
@ -16,6 +16,7 @@ COMMENT= An optimizer for PNG files
OPTIONS= BUNDLED_LIBPNG "Use bundled libpng" off \
BUNDLED_ZLIB "Use bundled zlib" off
HAS_CONFIGURE= yes
BUILD_WRKSRC= ${WRKSRC}/src
MAKEFILE= scripts/unix.mak
ALL_TARGET= ${PORTNAME}
@ -24,11 +25,11 @@ MAN1= optipng.1
PORTDOCS= caveat.txt history.txt manual.html manual.pdf manual.txt \
png_optimization_guide.html thanks.html todo.txt
.include <bsd.port.pre.mk>
.include <bsd.port.options.mk>
CONFIGURE_ARGS= #
.ifndef(WITH_BUNDLED_LIBPNG)
CONFIGURE_ARGS+= --with-system-libpng
CFLAGS+= "-I${LOCALBASE}/include"
LIB_DEPENDS+= png.6:${PORTSDIR}/graphics/png
.endif
@ -36,11 +37,6 @@ LIB_DEPENDS+= png.6:${PORTSDIR}/graphics/png
CONFIGURE_ARGS+= --with-system-zlib
.endif
do-configure:
(cd ${WRKSRC} && ./configure ${CONFIGURE_ARGS})
${REINPLACE_CMD} -e 's|^INCS =.*|INCS = -I${LOCALBASE}/include|' \
${WRKSRC}/lib/pngxtern/scripts/unix.mak
do-install:
${INSTALL_PROGRAM} ${WRKSRC}/src/optipng ${PREFIX}/bin/
${INSTALL_MAN} ${WRKSRC}/man/optipng.1 ${MAN1PREFIX}/man/man1/
@ -51,4 +47,4 @@ post-install:
${INSTALL_DATA} ${PORTDOCS:S,^,${WRKSRC}/doc/,} ${DOCSDIR}/
.endif
.include <bsd.port.post.mk>
.include <bsd.port.mk>

View File

@ -1,2 +1,2 @@
SHA256 (optipng-0.6.4.tar.gz) = 3000892b1d240351f057fbc8012485c3a1e75b991fa8d54e048273fa0fa87647
SIZE (optipng-0.6.4.tar.gz) = 1483806
SHA256 (optipng-0.6.5.tar.gz) = 2998e203941cdb95eb97587a44b02b3b765e85a7d62fe2df076b0123a7ba5b44
SIZE (optipng-0.6.5.tar.gz) = 1534271

View File

@ -1,6 +1,6 @@
--- lib/libpng/scripts/makefile.std.orig 2006-03-06 17:06:28.000000000 +0000
+++ lib/libpng/scripts/makefile.std 2008-11-14 18:00:09.000000000 +0000
@@ -24,12 +24,16 @@
--- lib/libpng/scripts/makefile.std.orig 2010-12-09 16:48:13.000000000 +0300
+++ lib/libpng/scripts/makefile.std 2011-04-13 20:38:46.000000000 +0400
@@ -27,12 +27,16 @@
ZLIBLIB=../zlib
ZLIBINC=../zlib

View File

@ -1,5 +1,5 @@
--- lib/pngxtern/scripts/unix.mak.in.orig 2008-06-18 01:29:00.000000000 +0200
+++ lib/pngxtern/scripts/unix.mak.in 2010-04-05 21:52:14.000000000 +0200
--- lib/pngxtern/scripts/unix.mak.in.orig 2008-06-18 03:29:00.000000000 +0400
+++ lib/pngxtern/scripts/unix.mak.in 2011-04-13 21:06:00.000000000 +0400
@@ -8,8 +8,8 @@
PNGDIR = ../libpng
@ -11,14 +11,16 @@
AR_RC = ar rcs
RANLIB = ranlib
RM_F = rm -f
@@ -18,8 +18,8 @@
@@ -18,9 +18,9 @@
LDDEBUG =
CRELEASE = -O
LDRELEASE = -s
-CFLAGS = $(CRELEASE)
-LDFLAGS = $(LDRELEASE)
-INCS = -I$(ZDIR) -I$(PNGDIR)
+CFLAGS ?= $(CRELEASE)
+LDFLAGS ?= $(LDRELEASE)
INCS = -I$(ZDIR) -I$(PNGDIR)
+INCS = -I$(ZDIR) -I$(PNGDIR) -I${LOCALBASE}/include
LIBS = -lpng -lz -lm
# File extensions

View File

@ -1,5 +1,5 @@
--- lib/zlib/Makefile.in.orig 2010-03-14 04:10:27.000000000 +0100
+++ lib/zlib/Makefile.in 2010-04-05 21:25:15.000000000 +0200
--- lib/zlib/Makefile.in.orig 2011-04-14 15:10:39.000000000 +0400
+++ lib/zlib/Makefile.in 2011-04-14 15:11:57.000000000 +0400
@@ -16,9 +16,9 @@
# To install in $HOME instead of /usr/local, use:
# make install prefix=$HOME
@ -12,21 +12,23 @@
#CFLAGS=-O -DMAX_WBITS=14 -DMAX_MEM_LEVEL=7
#CFLAGS=-g -DDEBUG
#CFLAGS=-O3 -Wall -Wwrite-strings -Wpointer-arith -Wconversion \
@@ -36,9 +36,10 @@
@@ -36,11 +36,12 @@
SHAREDLIBM=libz.so.1
LIBS=$(STATICLIB) $(SHAREDLIB) $(SHAREDLIBV)
LIBS=$(STATICLIB) $(SHAREDLIBV)
-AR=ar rc
-RANLIB=ranlib
-TAR=tar
+AR?=ar
+ARFLAGS?=rc
+RANLIB?=ranlib
LDCONFIG=ldconfig
LDSHAREDLIBC=-lc
-TAR=tar
+TAR?=tar
SHELL=/bin/sh
EXE=
@@ -105,7 +106,7 @@
@@ -108,7 +109,7 @@
-@rm -f foo.gz
libz.a: $(OBJS)

View File

@ -1,11 +1,11 @@
--- src/opngreduc.c.orig 2010-01-03 06:59:00.000000000 +0100
+++ src/opngreduc.c 2010-04-05 22:02:26.000000000 +0200
@@ -23,7 +23,7 @@
#define PNG_NO_PEDANTIC_WARNINGS
#include "png.h"
--- src/opngreduc.c.orig 2011-12-29 14:47:34.000000000 +0100
+++ src/opngreduc.c 2011-12-29 14:48:52.000000000 +0100
@@ -27,6 +27,8 @@
#if PNG_LIBPNG_VER >= 10400
-#include "pngpriv.h"
#ifdef PNG_USER_PRIVATEBUILD
#include "pngpriv.h"
+#else
+#include "libpng/pngpriv.h"
#else
#define trans_alpha trans
#define trans_color trans_values
#endif
#endif

View File

@ -1,5 +1,5 @@
--- src/scripts/unix.mak.in.orig 2008-09-03 23:56:00.000000000 +0100
+++ src/scripts/unix.mak.in 2008-11-14 18:29:12.000000000 +0000
--- src/scripts/unix.mak.in.orig 2011-04-14 15:07:03.000000000 +0400
+++ src/scripts/unix.mak.in 2011-04-14 15:08:29.000000000 +0400
@@ -4,16 +4,16 @@
# Usage: make -f scripts/unix.mak
@ -12,11 +12,10 @@
man1dir=$(mandir)/man1
-CC = cc
-LD = $(CC)
+CC ?= cc
LD = $(CC)
-CFLAGS = -O
-LDFLAGS = -s
+CC ?= cc
+LD = $(CC)
+CFLAGS ?= -O
+LDFLAGS += -s -L${LOCALBASE}/lib
@ -25,9 +24,8 @@
@@ -28,7 +28,7 @@
BACKDIR = ../../src
OBJS = optipng.o opngoptim.o opngreduc.o cbitset.o osys.o strutil.o
OBJS = optipng.o opngoptim.o opngreduc.o cbitset.o osys.o
-INCS = -I$(ZDIR) -I$(PNGDIR) -I$(PNGXDIR)
+INCS = -I$(ZDIR) -I$(PNGDIR) -I$(PNGXDIR) -I${LOCALBASE}/include
LIBS = $(PNGXDIR)/$(PNGXLIB) $(PNGDIR)/$(PNGLIB) $(ZDIR)/$(ZLIB)
SYSLIBS =
SYSLIBS = -lm