pkgsrc-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc/graphics/pngcrush Fix building on Darwin



details:   https://anonhg.NetBSD.org/pkgsrc/rev/e11bfee0619f
branches:  trunk
changeset: 515697:e11bfee0619f
user:      adam <adam%pkgsrc.org@localhost>
date:      Thu Jul 06 20:51:25 2006 +0000

description:
Fix building on Darwin

diffstat:

 graphics/pngcrush/Makefile         |   4 +-
 graphics/pngcrush/distinfo         |   3 +-
 graphics/pngcrush/patches/patch-aa |  53 ++++++++++++++++++++++++++++++++++++++
 3 files changed, 57 insertions(+), 3 deletions(-)

diffs (86 lines):

diff -r 5d0c2e5331c6 -r e11bfee0619f graphics/pngcrush/Makefile
--- a/graphics/pngcrush/Makefile        Thu Jul 06 20:36:44 2006 +0000
+++ b/graphics/pngcrush/Makefile        Thu Jul 06 20:51:25 2006 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.24 2006/06/10 07:43:11 adam Exp $
+# $NetBSD: Makefile,v 1.25 2006/07/06 20:51:25 adam Exp $
 
 DISTNAME=      pngcrush-1.6.4-nolib
 PKGNAME=       pngcrush-1.6.4
@@ -16,7 +16,7 @@
 do-build:
        cd ${WRKSRC} && ${CC} -DPNG_USE_LOCAL_ARRAYS \
                ${CFLAGS} `libpng-config --cflags` -o pngcrush pngcrush.c \
-               `libpng-config --ldflags`
+               `libpng-config --ldflags` -lz
 
 do-install:
        ${INSTALL_PROGRAM} ${WRKSRC}/pngcrush ${PREFIX}/bin
diff -r 5d0c2e5331c6 -r e11bfee0619f graphics/pngcrush/distinfo
--- a/graphics/pngcrush/distinfo        Thu Jul 06 20:36:44 2006 +0000
+++ b/graphics/pngcrush/distinfo        Thu Jul 06 20:51:25 2006 +0000
@@ -1,5 +1,6 @@
-$NetBSD: distinfo,v 1.12 2006/06/10 07:43:11 adam Exp $
+$NetBSD: distinfo,v 1.13 2006/07/06 20:51:25 adam Exp $
 
 SHA1 (pngcrush-1.6.4-nolib.tar.bz2) = 6d5c871b94bda8bdc605277501432f74b1a85f23
 RMD160 (pngcrush-1.6.4-nolib.tar.bz2) = 56cf59f968187c81e6dc5e0f1acd935c0058ebd9
 Size (pngcrush-1.6.4-nolib.tar.bz2) = 41061 bytes
+SHA1 (patch-aa) = 2c9138f28a0e03c75f33e931f26a2dee86cdac40
diff -r 5d0c2e5331c6 -r e11bfee0619f graphics/pngcrush/patches/patch-aa
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/graphics/pngcrush/patches/patch-aa        Thu Jul 06 20:51:25 2006 +0000
@@ -0,0 +1,53 @@
+$NetBSD: patch-aa,v 1.6 2006/07/06 20:51:25 adam Exp $
+
+--- pngcrush.c.orig    2006-07-06 22:32:25.000000000 +0200
++++ pngcrush.c 2006-07-06 22:41:02.000000000 +0200
+@@ -444,9 +444,6 @@
+ int png_crc_error(png_structp png_ptr);
+ int png_crc_finish(png_structp png_ptr, png_uint_32 skip);
+ 
+-png_uint_32 png_get_uint_31(png_structp png_ptr, png_bytep buf);
+-png_uint_32 png_get_uint_32(png_bytep buf);
+-void png_save_uint_32(png_bytep buf, png_uint_32 i);
+ 
+ #ifdef PNG_USER_MEM_SUPPORTED
+ png_voidp png_debug_malloc(png_structp png_ptr, png_uint_32 size);
+@@ -482,38 +479,6 @@
+  * ============================================================
+  */
+ 
+-#ifndef PNG_READ_BIG_ENDIAN_SUPPORTED
+-/* Grab an unsigned 32-bit integer from a buffer in big-endian format. */
+-png_uint_32 /* PRIVATE */
+-png_get_uint_32(png_bytep buf)
+-{
+-   png_uint_32 i = ((png_uint_32)(*buf) << 24) +
+-      ((png_uint_32)(*(buf + 1)) << 16) +
+-      ((png_uint_32)(*(buf + 2)) << 8) +
+-      (png_uint_32)(*(buf + 3));
+-
+-   return (i);
+-}
+-#else
+-#  define png_get_uint_32(buf) ( *((png_uint_32p) (buf)))
+-#endif
+-png_uint_32 /* PRIVATE */
+-png_get_uint_31(png_structp png_ptr, png_bytep buf)
+-{
+-   png_uint_32 i = png_get_uint_32(buf);
+-   if (i > PNG_UINT_31_MAX)
+-     png_error(png_ptr, "PNG unsigned integer out of range.\n");
+-   return (i);
+-}
+-void /* PRIVATE */
+-png_save_uint_32(png_bytep buf, png_uint_32 i)
+-{
+-   buf[0] = (png_byte)((i >> 24) & 0xff);
+-   buf[1] = (png_byte)((i >> 16) & 0xff);
+-   buf[2] = (png_byte)((i >> 8) & 0xff);
+-   buf[3] = (png_byte)(i & 0xff);
+-}
+-
+ /* Reset the CRC variable to 32 bits of 1's.  Care must be taken
+  * in case CRC is > 32 bits to leave the top bits 0.
+  */



Home | Main Index | Thread Index | Old Index