summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSamuli Suominen <ssuominen@gentoo.org>2011-09-17 16:06:43 +0000
committerSamuli Suominen <ssuominen@gentoo.org>2011-09-17 16:06:43 +0000
commitee51483dbed2e19a6efaaa16a0f3286efa387c6f (patch)
tree2ebda377ca51f2520c82c35ee32b8f0e8abb4558 /media-gfx/exact-image
parentVersion bump (diff)
downloadgentoo-2-ee51483dbed2e19a6efaaa16a0f3286efa387c6f.tar.gz
gentoo-2-ee51483dbed2e19a6efaaa16a0f3286efa387c6f.tar.bz2
gentoo-2-ee51483dbed2e19a6efaaa16a0f3286efa387c6f.zip
Fix building with libpng15 wrt #383203 by Diego Elio Pettenò
(Portage version: 2.2.0_alpha55/cvs/Linux x86_64)
Diffstat (limited to 'media-gfx/exact-image')
-rw-r--r--media-gfx/exact-image/ChangeLog8
-rw-r--r--media-gfx/exact-image/exact-image-0.8.1.ebuild10
-rw-r--r--media-gfx/exact-image/files/exact-image-0.8.1-libpng15.patch34
3 files changed, 47 insertions, 5 deletions
diff --git a/media-gfx/exact-image/ChangeLog b/media-gfx/exact-image/ChangeLog
index b76432f171ad..ab537a756e2b 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.6 2010/11/08 22:36:11 maekke Exp $
+# Copyright 1999-2011 Gentoo Foundation; Distributed under the GPL v2
+# $Header: /var/cvsroot/gentoo-x86/media-gfx/exact-image/ChangeLog,v 1.7 2011/09/17 16:06:43 ssuominen Exp $
+
+ 17 Sep 2011; Samuli Suominen <ssuominen@gentoo.org> exact-image-0.8.1.ebuild,
+ +files/exact-image-0.8.1-libpng15.patch:
+ Fix building with libpng15 wrt #383203 by Diego Elio Pettenò
08 Nov 2010; Markus Meier <maekke@gentoo.org> exact-image-0.8.1.ebuild:
change jpeg dep to virtual/jpeg
diff --git a/media-gfx/exact-image/exact-image-0.8.1.ebuild b/media-gfx/exact-image/exact-image-0.8.1.ebuild
index 84596e9226d6..bd69a3fde67c 100644
--- a/media-gfx/exact-image/exact-image-0.8.1.ebuild
+++ b/media-gfx/exact-image/exact-image-0.8.1.ebuild
@@ -1,6 +1,6 @@
-# Copyright 1999-2010 Gentoo Foundation
+# Copyright 1999-2011 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.8.1.ebuild,v 1.3 2010/11/08 22:36:11 maekke Exp $
+# $Header: /var/cvsroot/gentoo-x86/media-gfx/exact-image/exact-image-0.8.1.ebuild,v 1.4 2011/09/17 16:06:43 ssuominen Exp $
EAPI=2
@@ -49,7 +49,11 @@ pkg_setup() {
src_prepare() {
python_convert_shebangs -r 2 .
- epatch "${FILESDIR}"/${PN}-0.7.5-libpng14.patch
+
+ epatch \
+ "${FILESDIR}"/${PN}-0.7.5-libpng14.patch \
+ "${FILESDIR}"/${P}-libpng15.patch
+
# fix python hardcoded path wrt bug #327171
sed -i -e "s:python2.5:python$(python_get_version):" \
-e "s:\$(libdir):usr/$(get_libdir):" \
diff --git a/media-gfx/exact-image/files/exact-image-0.8.1-libpng15.patch b/media-gfx/exact-image/files/exact-image-0.8.1-libpng15.patch
new file mode 100644
index 000000000000..44c94726e35c
--- /dev/null
+++ b/media-gfx/exact-image/files/exact-image-0.8.1-libpng15.patch
@@ -0,0 +1,34 @@
+--- codecs/png.cc
++++ codecs/png.cc
+@@ -16,6 +16,7 @@
+ */
+
+ #include <stdlib.h>
++#include <zlib.h>
+ #include <png.h>
+
+ #include <iostream>
+@@ -104,7 +105,7 @@
+ image.w = width;
+ image.h = height;
+ image.bps = bit_depth;
+- image.spp = info_ptr->channels;
++ image.spp = png_get_channels(png_ptr, info_ptr);
+
+ png_uint_32 res_x, res_y;
+ res_x = png_get_x_pixels_per_meter(png_ptr, info_ptr);
+@@ -120,10 +121,13 @@
+ // png_set_packswap(png_ptr);
+
+ /* Expand paletted colors into true RGB triplets */
++
++ int num_trans;
++
+ if (color_type == PNG_COLOR_TYPE_PALETTE) {
+ png_set_palette_to_rgb(png_ptr);
+ image.bps = 8;
+- if (info_ptr->num_trans)
++ if (num_trans)
+ image.spp = 4;
+ else
+ image.spp = 3;