1
0
mirror of https://git.FreeBSD.org/ports.git synced 2025-01-11 07:22:22 +00:00

- Update to 1.0

PR:		ports/156417
Submitted by:	Anton Yuzhaninov (citrin@citrin.ru)
Approved by:	(stb@lassitu.de)(maintainer)
		itetcu (mentor)(implicit)
This commit is contained in:
Beech Rintoul 2011-04-20 20:02:25 +00:00
parent fe009b21b2
commit 9a0fa027e8
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=272966
5 changed files with 26 additions and 40 deletions

View File

@ -6,40 +6,30 @@
#
PORTNAME= pngnq
PORTVERSION= 0.5
PORTREVISION= 2
PORTVERSION= 1.0
CATEGORIES= graphics
MASTER_SITES= SF
DISTNAME= ${PORTNAME}-${PORTVERSION}-src
MAINTAINER= stb@lassitu.de
COMMENT= A tool for quantizing PNG images in RGBA format
LIB_DEPENDS= png.6:${PORTSDIR}/graphics/png
WRKSRC= ${WRKDIR}/${PORTVERSION}
GNU_CONFIGURE= yes
USE_GMAKE= yes
MAKE_ARGS= CC="${CC}" CFLAGS="${CFLAGS} -I${LOCALBASE}/include -DVERSION='\"${PORTVERSION}\"'" \
LDFLAGS="-lpng -lz -lm -L${LOCALBASE}/lib"
CPPFLAGS+= -I${LOCALBASE}/include
CONFIGURE_ENV+= LDFLAGS="${LDFLAGS} -L${LOCALBASE}/lib" LIBS=-lpng
PORTDOCS= README LICENSE README.pngcomp
PORTDOCS= README COPYING
PLIST_FILES= bin/pngcomp bin/pngnq
.if !defined(NO_INSTALL_MANPAGES)
MAN1= pngnq.1
.endif
do-install:
${INSTALL_PROGRAM} ${WRKSRC}/pngcomp ${PREFIX}/bin
${INSTALL_PROGRAM} ${WRKSRC}/pngnq ${PREFIX}/bin
post-install:
.if !defined(NOPORTDOCS)
@${MKDIR} ${DOCSDIR}
.for i in ${PORTDOCS}
${INSTALL_DATA} ${WRKSRC}/${i} ${DOCSDIR}
.endfor
.endif
.if !defined(NO_INSTALL_MANPAGES)
${INSTALL_MAN} ${WRKSRC}/pngnq.1 ${MAN1PREFIX}/man/man1
.endif
.include <bsd.port.mk>

View File

@ -1,3 +1,2 @@
MD5 (pngnq-0.5-src.tar.gz) = 14aff764008dfd55e816d3fe08636cb9
SHA256 (pngnq-0.5-src.tar.gz) = c9f2f4239e07d23064176909cd59ef12d96573599a3fa29bed59fe554b769b92
SIZE (pngnq-0.5-src.tar.gz) = 26115
SHA256 (pngnq-1.0.tar.gz) = 3413cb72af4e1a25268892ad182f6f9f516c5b67d9ff873968e5a60c293c00a7
SIZE (pngnq-1.0.tar.gz) = 105155

View File

@ -0,0 +1,18 @@
--- src/errors.h.orig 2011-04-14 19:57:13.000000000 +0400
+++ src/errors.h 2011-04-14 20:00:25.000000000 +0400
@@ -20,9 +20,11 @@
PNGNQ_LOG_ERR(__VA_ARGS__)\
fflush(stderr);
-#define PNGNQ_WARNING(...) (fprintf(stderr,"pngnq - Warning: "));\
- fprintf(stderr, __VA_ARGS__);\
- PNGNQ_LOG_WARNING(__VA_ARGS__)\
- fflush(stderr);
+#define PNGNQ_WARNING(...) \
+ do { \
+ fprintf(stderr, "pngnq - Warning: " __VA_ARGS__); \
+ PNGNQ_LOG_WARNING(__VA_ARGS__) \
+ fflush(stderr); \
+ } while (0)
#define PNGNQ_MESSAGE(...) {if(verbose) {fprintf(stderr,__VA_ARGS__);fflush(stderr);}}

View File

@ -1,10 +0,0 @@
--- pngcomp.c.orig 2007-11-12 13:59:38.000000000 +0100
+++ pngcomp.c 2009-05-10 15:07:38.000000000 +0200
@@ -41,6 +41,7 @@
#include <string.h>
#include <math.h>
#include <ctype.h>
+#include <unistd.h>
#include "png.h"
#include "rwpng.h"

View File

@ -1,11 +0,0 @@
--- rwpng.c.orig 2006-06-15 11:39:29.000000000 +0200
+++ rwpng.c 2010-03-29 15:35:32.000000000 +0200
@@ -77,7 +77,7 @@
* have used slightly more general png_sig_cmp() function instead */
fread(sig, 1, 8, infile);
- if (!png_check_sig(sig, 8)) {
+ if (png_sig_cmp(sig, 0, 8)) {
mainprog_ptr->retval = 21; /* bad signature */
return mainprog_ptr->retval;
}