Update of /cvsroot/fink/dists/10.4/stable/main/finkinfo/graphics In directory sfp-cvs-1.v30.ch3.sourceforge.com:/tmp/cvs-serv5623
Modified Files: bmp2png.info Added Files: bmp2png.patch Log Message: sync libpng15 fix from 10.7 Index: bmp2png.info =================================================================== RCS file: /cvsroot/fink/dists/10.4/stable/main/finkinfo/graphics/bmp2png.info,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- bmp2png.info 16 Feb 2012 17:46:22 -0000 1.1 +++ bmp2png.info 3 Jun 2013 20:45:22 -0000 1.2 @@ -1,13 +1,16 @@ Package: bmp2png Version: 1.62 -Revision: 1 +Revision: 2 Homepage: http://cetus.sakura.ne.jp/softlab/b2p-home/ Source: http://cetus.sakura.ne.jp/softlab/b2p-home/archives/%n-%v.tar.gz Source-MD5: 29562be8cb5300ecf0361904abff54dd -BuildDepends: libpng3, unzip -Depends: libpng3-shlibs +BuildDepends: libpng15, unzip +Depends: libpng15-shlibs Suggests: pngcrush, gif2png, tiff2png +PatchFile: %n.patch +PatchFile-MD5: 4b8267b69afc01f6c17158519582585d PatchScript: << + %{default_script} perl -pi -e 's,/usr/local,%p,g' Makefile << SetCFLAGS: -I%p/include @@ -34,7 +37,7 @@ << License: OSI-Approved DescPort: << -Needs to use libpng3. Can't be upgraded w/out massive patching to use libpng14+ +Patches for libpng15 posted on upstream site but not in any released version (as of 1.62) << Maintainer: None <fink-de...@lists.sourceforge.net> DescPackaging: << --- NEW FILE: bmp2png.patch --- --- a/png2bmp.c.orig 2005-09-04 01:00:00.000000000 +0900 +++ b/png2bmp.c 2010-03-03 01:38:20.000000000 +0900 @@ -370,16 +370,21 @@ */ static int skip_macbinary(png_structp png_ptr) { - void png_read_data(png_structp, png_bytep, png_size_t); - enum { PNG_BYTES_TO_CHECK = 8, MACBIN_SIZE = 128 }; /* ^ in pngrio.c */ + enum { PNG_BYTES_TO_CHECK = 8, MACBIN_SIZE = 128 }; png_byte buf[MACBIN_SIZE]; png_bytep sig; + png_size_t check; + png_FILE_p fp = (png_FILE_p)png_get_io_ptr(png_ptr); + + check = (png_size_t)fread(buf, 1, PNG_BYTES_TO_CHECK, fp); + if (check != PNG_BYTES_TO_CHECK) png_error(png_ptr, "Read Error"); - png_read_data(png_ptr, buf, PNG_BYTES_TO_CHECK); if (png_sig_cmp(buf, 0, PNG_BYTES_TO_CHECK) == 0) return PNG_BYTES_TO_CHECK; - png_read_data(png_ptr, buf, MACBIN_SIZE); + check = (png_size_t)fread(buf, 1, MACBIN_SIZE, fp); + if (check != MACBIN_SIZE) png_error(png_ptr, "Read Error"); + sig = buf + MACBIN_SIZE - PNG_BYTES_TO_CHECK; if (png_sig_cmp(sig, 0, PNG_BYTES_TO_CHECK) == 0) return PNG_BYTES_TO_CHECK; --- a/common.h.orig 2005-09-04 01:00:00.000000000 +0900 +++ b/common.h 2012-09-25 15:31:52.000000000 +0900 @@ -80,6 +80,7 @@ # include <fcntl.h> #endif +#include "zlib.h" #include "png.h" #if (PNG_LIBPNG_VER < 10004) ------------------------------------------------------------------------------ How ServiceNow helps IT people transform IT departments: 1. A cloud service to automate IT design, transition and operations 2. Dashboards that offer high-level views of enterprise services 3. A single system of record for all IT processes http://p.sf.net/sfu/servicenow-d2d-j _______________________________________________ Fink-commits mailing list Fink-commits@lists.sourceforge.net http://news.gmane.org/gmane.os.apple.fink.cvs