From owner-svn-ports-head@FreeBSD.ORG Wed Dec 24 12:26:47 2014 Return-Path: Delivered-To: svn-ports-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 36947F33; Wed, 24 Dec 2014 12:26:47 +0000 (UTC) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 0849366EFE; Wed, 24 Dec 2014 12:26:47 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.9/8.14.9) with ESMTP id sBOCQkcw000628; Wed, 24 Dec 2014 12:26:46 GMT (envelope-from antoine@FreeBSD.org) Received: (from antoine@localhost) by svn.freebsd.org (8.14.9/8.14.9/Submit) id sBOCQkgL000625; Wed, 24 Dec 2014 12:26:46 GMT (envelope-from antoine@FreeBSD.org) Message-Id: <201412241226.sBOCQkgL000625@svn.freebsd.org> X-Authentication-Warning: svn.freebsd.org: antoine set sender to antoine@FreeBSD.org using -f From: Antoine Brodin Date: Wed, 24 Dec 2014 12:26:46 +0000 (UTC) To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org Subject: svn commit: r375449 - in head/games/xbubble: . files X-SVN-Group: ports-head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-ports-head@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: SVN commit messages for the ports tree for head List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 24 Dec 2014 12:26:47 -0000 Author: antoine Date: Wed Dec 24 12:26:45 2014 New Revision: 375449 URL: https://svnweb.freebsd.org/changeset/ports/375449 QAT: https://qat.redports.org/buildarchive/r375449/ Log: Properly support png 1.5 Obtained from: OpenBSD ports Modified: head/games/xbubble/Makefile head/games/xbubble/files/patch-src-loadpng.c Modified: head/games/xbubble/Makefile ============================================================================== --- head/games/xbubble/Makefile Wed Dec 24 12:26:38 2014 (r375448) +++ head/games/xbubble/Makefile Wed Dec 24 12:26:45 2014 (r375449) @@ -13,13 +13,13 @@ COMMENT= Puzzle Bobble clone for Unix/X1 LICENSE= GPLv2 # or later LICENSE_FILE= ${WRKSRC}/COPYING -LIB_DEPENDS= libpng15.so:${PORTSDIR}/graphics/png +LIB_DEPENDS= libpng.so:${PORTSDIR}/graphics/png USE_XORG= x11 xmu GNU_CONFIGURE= yes USES= gmake -CPPFLAGS+= -I${LOCALBASE}/include/libpng15 +CPPFLAGS+= -I${LOCALBASE}/include LDFLAGS+= -L${LOCALBASE}/lib OPTIONS_DEFINE= NLS Modified: head/games/xbubble/files/patch-src-loadpng.c ============================================================================== --- head/games/xbubble/files/patch-src-loadpng.c Wed Dec 24 12:26:38 2014 (r375448) +++ head/games/xbubble/files/patch-src-loadpng.c Wed Dec 24 12:26:45 2014 (r375449) @@ -1,28 +1,24 @@ ---- src/loadpng.c.orig 2003-09-30 14:55:20.000000000 +0200 -+++ src/loadpng.c 2012-04-29 13:39:04.000000000 +0200 -@@ -21,6 +21,7 @@ - #include - #include - #include -+#include - - #include "gettext.h" - -@@ -55,7 +56,7 @@ - } - /* ensure that we opened a PNG file */ - fread( header, 1, 8, fd ); -- if ( ! png_check_sig( header, 8 ) ) { -+ if ( png_sig_cmp( header, 0, 8 ) ) { - fclose(fd); - fprintf(stderr,_("File %s does not have a valid PNG signature.\n"), file); - return NULL; -@@ -73,7 +74,7 @@ +$OpenBSD: patch-src_loadpng_c,v 1.1 2011/07/08 20:38:01 naddy Exp $ + +Fix build with png-1.5. + +--- src/loadpng.c.orig Wed Jul 6 15:26:00 2011 ++++ src/loadpng.c Wed Jul 6 15:28:42 2011 +@@ -73,7 +73,7 @@ unsigned char * load_png_file( const char *file, return NULL; } /* libpng does a longjmp here when it encounters an error */ - if ( setjmp( png_ptr->jmpbuf ) ) { -+ if ( setjmp( png_jmpbuf(png_ptr) ) ) { ++ if ( setjmp( png_jmpbuf( png_ptr ) ) ) { png_destroy_read_struct( &png_ptr, &info_ptr, NULL); fclose(fd); return NULL; +@@ -95,7 +95,7 @@ unsigned char * load_png_file( const char *file, + png_set_gray_to_rgb(png_ptr); + + /* detect alpha layer */ +- if (( info_ptr->color_type & PNG_COLOR_MASK_ALPHA )|| ++ if (( png_get_color_type ( png_ptr, info_ptr ) & PNG_COLOR_MASK_ALPHA )|| + ( png_get_valid( png_ptr, info_ptr, PNG_INFO_tRNS ))) + *has_alpha = 1; + else