Gentoo Logo
Gentoo Spaceship




Note: Due to technical difficulties, the Archives are currently not up to date. GMANE provides an alternative service for most mailing lists.
c.f. bug 424647
List Archive: gentoo-desktop
Navigation:
Lists: gentoo-desktop: < Prev By Thread Next > < Prev By Date Next >
Headers:
To: gentoo-desktop@g.o
From: Jens Rutschmann <Jens.Rutschmann@...>
Subject: [kde-sunset] gwenview-1.4.2-r3 doesn't compile with libpng-1.4.2 (patch included)
Date: Sun, 16 May 2010 23:58:07 +0200
Hi all,

apparently the gwenview code includes some copied source files from qt3.

At least compiling it against libpng-1.4.2 fails with the same errors as qt3 did. Parts of the patch for qt3 from the 
kde-sunset overlay can be applied to gwenview as well.

I modified it a bit and attached it to this email. Place it in the files dir and change the "PATCHES" variable in the 
ebuild as follows and gwenview should compile again.



PATCHES=(
	"${FILESDIR}/gwenview-1.4.2-exiv2.patch"
	"${FILESDIR}/gwenview-1.4.2-desktop-file.diff"
	"${FILESDIR}/gwenview-libpng14.patch"
	)



Best regards,
Jens
--- src/gvcore/pngformattype.cpp	2007-09-15 15:46:13.000000000 +0200
+++ src/gvcore/pngformattype.cpp	2010-05-16 23:40:09.057829081 +0200
@@ -245,7 +245,11 @@
 		image.setColor( i, qRgba(c,c,c,0xff) );
 	    }
 	    if ( png_get_valid(png_ptr, info_ptr, PNG_INFO_tRNS) ) {
-		const int g = info_ptr->trans_values.gray;
+#if PNG_LIBPNG_VER_MAJOR>1 || ( PNG_LIBPNG_VER_MAJOR==1 && PNG_LIBPNG_VER_MINOR>=4 )
+		const int g = info_ptr->trans_color.gray;
+#else
+ 		const int g = info_ptr->trans_values.gray;
+#endif
 		if (g < ncols) {
 		    image.setAlphaBuffer(TRUE);
 		    image.setColor(g, image.color(g) & RGB_MASK);
@@ -273,7 +277,11 @@
 		    info_ptr->palette[i].red,
 		    info_ptr->palette[i].green,
 		    info_ptr->palette[i].blue,
-		    info_ptr->trans[i]
+#if PNG_LIBPNG_VER_MAJOR>1 || ( PNG_LIBPNG_VER_MAJOR==1 && PNG_LIBPNG_VER_MINOR>=4 )
+		    info_ptr->trans_alpha[i]
+#else
+ 		    info_ptr->trans[i]
+#endif
 		    )
 		);
 		i++;
Replies:
Re: [kde-sunset] gwenview-1.4.2-r3 doesn't compile with libpng-1.4.2 (patch included)
-- Ladislav Laska
Navigation:
Lists: gentoo-desktop: < Prev By Thread Next > < Prev By Date Next >
Previous by thread:
hal & KDE
Next by thread:
Re: [kde-sunset] gwenview-1.4.2-r3 doesn't compile with libpng-1.4.2 (patch included)
Previous by date:
Re: hal & KDE
Next by date:
Re: [kde-sunset] gwenview-1.4.2-r3 doesn't compile with libpng-1.4.2 (patch included)


Updated Jun 28, 2012

Summary: Archive of the gentoo-desktop mailing list.

Donate to support our development efforts.

Copyright 2001-2013 Gentoo Foundation, Inc. Questions, Comments? Contact us.