1
0
mirror of https://git.FreeBSD.org/ports.git synced 2024-11-24 00:45:52 +00:00

Properly support png 1.5

Obtained from:	Gentoo
This commit is contained in:
Antoine Brodin 2014-12-24 13:51:30 +00:00
parent a5e9cebcf6
commit 15924ebac8
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=375458
2 changed files with 12 additions and 11 deletions

View File

@ -11,7 +11,7 @@ DISTNAME= Shaaft-${PORTVERSION}
MAINTAINER= ports@FreeBSD.org
COMMENT= OpenGL 3D falling block game similar to Blockout
LIB_DEPENDS= libpng15.so:${PORTSDIR}/graphics/png
LIB_DEPENDS= libpng.so:${PORTSDIR}/graphics/png
CONFLICTS= criticalmass-*

View File

@ -1,14 +1,15 @@
--- utilssdl/PNG.cpp.orig 2003-03-03 03:32:18.000000000 +0100
+++ utilssdl/PNG.cpp 2012-05-09 12:16:57.000000000 +0200
@@ -13,6 +13,7 @@
// FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details
//
#include <PNG.hpp>
+#include <pngpriv.h>
--- utilssdl/PNG.cpp.orig 2003-03-03 02:32:18 UTC
+++ utilssdl/PNG.cpp
@@ -45,7 +45,7 @@ void PNG::writeData( png_structp png, pn
{
png_uint_32 check;
//Save SDL surface as png
bool PNG::Save( SDL_Surface *img, const string &filename)
@@ -72,7 +73,7 @@
- check = fwrite( data, 1, length, (FILE *)(png->io_ptr));
+ check = fwrite( data, 1, length, (FILE *)(png_get_io_ptr(png)));
if( check != length)
{
png_error( png, "Write Error");
@@ -72,7 +72,7 @@ bool PNG::init( FILE *fp, int width, int
return false;
}