summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTim Harder <radhermit@gentoo.org>2011-10-04 18:19:58 +0000
committerTim Harder <radhermit@gentoo.org>2011-10-04 18:19:58 +0000
commit96f80f00a536df05362b2958531a0f8fbb1b4e75 (patch)
tree2c5ed043c622f719ba3a0df5c4f62953491c2c88 /media-gfx/shotwell
parentStable for HPPA (bug #355085). (diff)
downloadgentoo-2-96f80f00a536df05362b2958531a0f8fbb1b4e75.tar.gz
gentoo-2-96f80f00a536df05362b2958531a0f8fbb1b4e75.tar.bz2
gentoo-2-96f80f00a536df05362b2958531a0f8fbb1b4e75.zip
Fix build with libraw-0.14.0 (bug #384165, patch by Alexandre Rostovtsev).
(Portage version: 2.2.0_alpha60/cvs/Linux x86_64)
Diffstat (limited to 'media-gfx/shotwell')
-rw-r--r--media-gfx/shotwell/ChangeLog6
-rw-r--r--media-gfx/shotwell/files/shotwell-0.11.2-libraw-0.14.patch109
-rw-r--r--media-gfx/shotwell/shotwell-0.11.2.ebuild8
3 files changed, 120 insertions, 3 deletions
diff --git a/media-gfx/shotwell/ChangeLog b/media-gfx/shotwell/ChangeLog
index fff6405a7e5d..69d3d0218256 100644
--- a/media-gfx/shotwell/ChangeLog
+++ b/media-gfx/shotwell/ChangeLog
@@ -1,6 +1,10 @@
# ChangeLog for media-gfx/shotwell
# Copyright 1999-2011 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/media-gfx/shotwell/ChangeLog,v 1.26 2011/09/23 18:04:05 angelos Exp $
+# $Header: /var/cvsroot/gentoo-x86/media-gfx/shotwell/ChangeLog,v 1.27 2011/10/04 18:19:58 radhermit Exp $
+
+ 04 Oct 2011; Tim Harder <radhermit@gentoo.org> shotwell-0.11.2.ebuild,
+ +files/shotwell-0.11.2-libraw-0.14.patch:
+ Fix build with libraw-0.14.0 (bug #384165, patch by Alexandre Rostovtsev).
*shotwell-0.11.2 (23 Sep 2011)
diff --git a/media-gfx/shotwell/files/shotwell-0.11.2-libraw-0.14.patch b/media-gfx/shotwell/files/shotwell-0.11.2-libraw-0.14.patch
new file mode 100644
index 000000000000..cdf29486dede
--- /dev/null
+++ b/media-gfx/shotwell/files/shotwell-0.11.2-libraw-0.14.patch
@@ -0,0 +1,109 @@
+From 06ce5a48a3dcc6416ac81995bc9d2f7001d624f9 Mon Sep 17 00:00:00 2001
+From: Alexandre Rostovtsev <tetromino@gmail.com>
+Date: Sun, 2 Oct 2011 05:22:07 -0400
+Subject: [PATCH] Do not use libraw API that was dropped in libraw-0.14
+
+add_masked_borders_to_bitmap() and rotate_fuji_raw() were removed from
+0.14 API. We can safely drop their vala wrappers since they weren't
+being used anywhere. And drop CANNOT_ADDMASK error code, since it was
+dropped from the libraw API, and could only result from the removed
+add_masked_borders_to_bitmap().
+
+The LIBRAW_FILTERING_* constans were removed from the public API.
+Fortunately, the only one of them that shotwell code was using was
+LIBRAW_FILTERING_AUTOMATIC - which is now the default libraw behavior.
+Therefore, we can safely drop the LibRaw.Filtering enum.
+---
+ src/photos/GRaw.vala | 12 ------------
+ vapi/libraw.vapi | 14 --------------
+ 2 files changed, 0 insertions(+), 26 deletions(-)
+
+--- a/src/photos/GRaw.vala
++++ b/src/photos/GRaw.vala
+@@ -163,10 +163,6 @@ public class Processor {
+ proc = new LibRaw.Processor(options);
+ }
+
+- public void add_masked_borders_to_bitmap() {
+- proc.add_masked_borders_to_bitmap();
+- }
+-
+ public void adjust_sizes_info_only() throws Exception {
+ throw_exception("adjust_sizes_info_only", proc.adjust_sizes_info_only());
+ }
+@@ -215,10 +211,6 @@ public class Processor {
+ throw_exception("ppm_tiff_writer", proc.ppm_tiff_writer(filename));
+ }
+
+- public void rotate_fuji_raw() throws Exception {
+- throw_exception("rotate_fuji_raw", proc.rotate_fuji_raw());
+- }
+-
+ public void thumb_writer(string filename) throws Exception {
+ throw_exception("thumb_writer", proc.thumb_writer(filename));
+ }
+@@ -262,7 +254,6 @@ public class Processor {
+ // camera_profile
+ // bad_pixels
+ // dark_frame
+- output_params->filtering_mode = LibRaw.Filtering.AUTOMATIC;
+ output_params->output_bps = 8;
+ // output_tiff
+ output_params->user_flip = GRaw.Flip.FROM_SOURCE;
+@@ -303,9 +294,6 @@ private void throw_exception(string caller, LibRaw.Result result) throws Excepti
+ case LibRaw.Result.UNSUPPORTED_THUMBNAIL:
+ throw new Exception.UNSUPPORTED_THUMBNAIL(msg);
+
+- case LibRaw.Result.CANNOT_ADDMASK:
+- throw new Exception.CANNOT_ADDMASK(msg);
+-
+ case LibRaw.Result.UNSUFFICIENT_MEMORY:
+ throw new Exception.OUT_OF_MEMORY(msg);
+
+--- a/vapi/libraw.vapi
++++ b/vapi/libraw.vapi
+@@ -14,17 +14,6 @@ public unowned string version();
+
+ public unowned string versionNumber();
+
+-[CCode (cname="enum libraw_Filtering", cprefix="LIBRAW_FILTERING_")]
+-public enum Filtering {
+- DEFAULT,
+- NOZEROES,
+- NOBLACK,
+- NORAWCURVE,
+- NONE,
+- LIBRAWOWN,
+- AUTOMATIC
+-}
+-
+ [SimpleType]
+ [CCode (cname="libraw_imgother_t")]
+ public struct ImageOther {
+@@ -121,7 +110,6 @@ public struct OutputParams {
+ public bool use_camera_wb;
+ public bool use_camera_matrix;
+ public int output_color;
+- public Filtering filtering_mode;
+ public int output_bps;
+ public bool output_tiff;
+ public int user_flip;
+@@ -171,7 +159,6 @@ public class Processor {
+ [CCode (cname="libraw_init")]
+ public Processor(Options flags = Options.NONE);
+
+- public void add_masked_borders_to_bitmap();
+ public Result adjust_sizes_info_only();
+ [CCode (cname="libraw_dcraw_document_mode_processing")]
+ public Result document_mode_processing();
+@@ -192,7 +179,6 @@ public class Processor {
+ [CCode (cname="libraw_dcraw_ppm_tiff_writer")]
+ public Result ppm_tiff_writer(string outfile);
+ public void recycle();
+- public Result rotate_fuji_raw();
+ [CCode (cname="libraw_dcraw_thumb_writer")]
+ public Result thumb_writer(string outfile);
+ public Result unpack();
+--
+1.7.7
+
diff --git a/media-gfx/shotwell/shotwell-0.11.2.ebuild b/media-gfx/shotwell/shotwell-0.11.2.ebuild
index bfe0ac166706..f35e960d6688 100644
--- a/media-gfx/shotwell/shotwell-0.11.2.ebuild
+++ b/media-gfx/shotwell/shotwell-0.11.2.ebuild
@@ -1,6 +1,6 @@
# Copyright 1999-2011 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/media-gfx/shotwell/shotwell-0.11.2.ebuild,v 1.1 2011/09/23 18:04:05 angelos Exp $
+# $Header: /var/cvsroot/gentoo-x86/media-gfx/shotwell/shotwell-0.11.2.ebuild,v 1.2 2011/10/04 18:19:58 radhermit Exp $
EAPI=4
GCONF_DEBUG="no"
@@ -29,7 +29,7 @@ RDEPEND="
media-libs/lcms:2
>=media-libs/libexif-0.6.16
>=media-libs/libgphoto2-2.4.2
- >=media-libs/libraw-0.9.0
+ >=media-libs/libraw-0.14.0
>=net-libs/libsoup-2.26.0:2.4
>=net-libs/webkit-gtk-1.1.5:2
|| ( >=sys-fs/udev-171[gudev] >=sys-fs/udev-145[extras] )
@@ -48,6 +48,10 @@ pkg_setup() {
--lib=$(get_libdir)"
}
+src_prepare() {
+ epatch "${FILESDIR}"/${P}-libraw-0.14.patch
+}
+
src_compile() {
emake VALAC="$(type -p valac-0.12)"
}