summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSamuli Suominen <ssuominen@gentoo.org>2010-05-12 12:03:26 +0000
committerSamuli Suominen <ssuominen@gentoo.org>2010-05-12 12:03:26 +0000
commit5da5e7b2c251502f3831976541fd09239c395662 (patch)
treeb3262277075a8426c389276ee929d824d749ed92 /media-gfx/exact-image
parentBackport -libpng14.patch to -r0 of 2.0.0 because -r1 can't be stabilized. (diff)
downloadgentoo-2-5da5e7b2c251502f3831976541fd09239c395662.tar.gz
gentoo-2-5da5e7b2c251502f3831976541fd09239c395662.tar.bz2
gentoo-2-5da5e7b2c251502f3831976541fd09239c395662.zip
Fix building with libpng14 wrt #319399 by Helmut Jarausch.
(Portage version: 2.2_rc67/cvs/Linux x86_64)
Diffstat (limited to 'media-gfx/exact-image')
-rw-r--r--media-gfx/exact-image/ChangeLog6
-rw-r--r--media-gfx/exact-image/exact-image-0.7.5.ebuild8
-rw-r--r--media-gfx/exact-image/files/exact-image-0.7.5-libpng14.patch69
3 files changed, 81 insertions, 2 deletions
diff --git a/media-gfx/exact-image/ChangeLog b/media-gfx/exact-image/ChangeLog
index 8f5d9c74c1a4..a8b361de68f6 100644
--- a/media-gfx/exact-image/ChangeLog
+++ b/media-gfx/exact-image/ChangeLog
@@ -1,6 +1,10 @@
# ChangeLog for media-gfx/exact-image
# Copyright 1999-2010 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/media-gfx/exact-image/ChangeLog,v 1.1 2010/01/07 14:44:48 hwoarang Exp $
+# $Header: /var/cvsroot/gentoo-x86/media-gfx/exact-image/ChangeLog,v 1.2 2010/05/12 12:03:26 ssuominen Exp $
+
+ 12 May 2010; Samuli Suominen <ssuominen@gentoo.org>
+ exact-image-0.7.5.ebuild, +files/exact-image-0.7.5-libpng14.patch:
+ Fix building with libpng14 wrt #319399 by Helmut Jarausch.
*exact-image-0.7.5 (07 Jan 2010)
diff --git a/media-gfx/exact-image/exact-image-0.7.5.ebuild b/media-gfx/exact-image/exact-image-0.7.5.ebuild
index 959ae5b14e15..a2b55388e834 100644
--- a/media-gfx/exact-image/exact-image-0.7.5.ebuild
+++ b/media-gfx/exact-image/exact-image-0.7.5.ebuild
@@ -1,8 +1,9 @@
# Copyright 1999-2010 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/media-gfx/exact-image/exact-image-0.7.5.ebuild,v 1.1 2010/01/07 14:44:48 hwoarang Exp $
+# $Header: /var/cvsroot/gentoo-x86/media-gfx/exact-image/exact-image-0.7.5.ebuild,v 1.2 2010/05/12 12:03:26 ssuominen Exp $
EAPI="2"
+inherit eutils
DESCRIPTION="A fast, modern and generic image processing library"
HOMEPAGE="http://www.exactcode.de/site/open_source/exactimage/"
@@ -36,6 +37,11 @@ RDEPEND="agg? ( x11-libs/agg[truetype] )
DEPEND="${RDEPEND}
swig? ( dev-lang/swig )"
+src_prepare() {
+ # this is broken ebuild: automagic libpng depend.
+ epatch "${FILESDIR}"/${P}-libpng14.patch
+}
+
src_configure() {
# evas support is disabled since evas is not on main tree. You can find it
# on enlightenment overlay
diff --git a/media-gfx/exact-image/files/exact-image-0.7.5-libpng14.patch b/media-gfx/exact-image/files/exact-image-0.7.5-libpng14.patch
new file mode 100644
index 000000000000..f25b9af02da9
--- /dev/null
+++ b/media-gfx/exact-image/files/exact-image-0.7.5-libpng14.patch
@@ -0,0 +1,69 @@
+--- codecs/png.cc
++++ codecs/png.cc
+@@ -71,7 +71,7 @@
+ /* Allocate/initialize the memory for image information. REQUIRED. */
+ info_ptr = png_create_info_struct(png_ptr);
+ if (info_ptr == NULL) {
+- png_destroy_read_struct(&png_ptr, png_infopp_NULL, png_infopp_NULL);
++ png_destroy_read_struct(&png_ptr, NULL, NULL);
+ return 0;
+ }
+
+@@ -82,7 +82,7 @@
+
+ if (setjmp(png_jmpbuf(png_ptr))) {
+ /* Free all of the memory associated with the png_ptr and info_ptr */
+- png_destroy_read_struct(&png_ptr, &info_ptr, png_infopp_NULL);
++ png_destroy_read_struct(&png_ptr, &info_ptr, NULL);
+ /* If we get here, we had a problem reading the file */
+ return 0;
+ }
+@@ -99,7 +99,7 @@
+ png_read_info (png_ptr, info_ptr);
+
+ png_get_IHDR (png_ptr, info_ptr, &width, &height, &bit_depth, &color_type,
+- &interlace_type, int_p_NULL, int_p_NULL);
++ &interlace_type, NULL, NULL);
+
+ image.w = width;
+ image.h = height;
+@@ -132,7 +132,7 @@
+ #if 0 // no longer needed
+ /* Expand grayscale images to the full 8 bits from 2, or 4 bits/pixel */
+ if (color_type == PNG_COLOR_TYPE_GRAY && bit_depth > 1 && bit_depth < 8) {
+- png_set_gray_1_2_4_to_8(png_ptr);
++ png_set_expand_gray_1_2_4_to_8(png_ptr);
+ image.bps = 8;
+ }
+ #endif
+@@ -196,11 +196,11 @@
+ for (int pass = 0; pass < number_passes; ++pass)
+ for (unsigned int y = 0; y < height; ++y) {
+ row_pointers[0] = image.getRawData() + y * stride;
+- png_read_rows(png_ptr, row_pointers, png_bytepp_NULL, 1);
++ png_read_rows(png_ptr, row_pointers, NULL, 1);
+ }
+
+ /* clean up after the read, and free any memory allocated - REQUIRED */
+- png_destroy_read_struct(&png_ptr, &info_ptr, png_infopp_NULL);
++ png_destroy_read_struct(&png_ptr, &info_ptr, NULL);
+
+ /* that's it */
+ return true;
+@@ -224,7 +224,7 @@
+ /* Allocate/initialize the memory for image information. REQUIRED. */
+ info_ptr = png_create_info_struct(png_ptr);
+ if (info_ptr == NULL) {
+- png_destroy_write_struct(&png_ptr, png_infopp_NULL);
++ png_destroy_write_struct(&png_ptr, NULL);
+ return false;
+ }
+
+@@ -244,7 +244,6 @@
+ else if (quality > Z_BEST_COMPRESSION) quality = Z_BEST_COMPRESSION;
+ png_set_compression_level(png_ptr, quality);
+
+- png_info_init (info_ptr);
+
+ /* Set up our STL stream output control */
+ png_set_write_fn (png_ptr, stream, &stdstream_write_data, &stdstream_flush_data);