From 84c0fef51206bffd6d2a95417dd7ba1ea04128c0121c59f67646436e8a02fd68 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ismail=20D=C3=B6nmez?= Date: Fri, 18 May 2012 11:36:55 +0000 Subject: [PATCH] Accepting request 121387 from home:dimstar:branches:graphics Fix build on Factory with ruby 1.9 OBS-URL: https://build.opensuse.org/request/show/121387 OBS-URL: https://build.opensuse.org/package/show/graphics/gegl?expand=0&rev=26 --- gegl-ruby19.patch | 43 +++++++++++++++++++++++++++++++++++++++++++ gegl.changes | 7 +++++++ gegl.spec | 5 +++++ 3 files changed, 55 insertions(+) create mode 100644 gegl-ruby19.patch diff --git a/gegl-ruby19.patch b/gegl-ruby19.patch new file mode 100644 index 0000000..8b0d265 --- /dev/null +++ b/gegl-ruby19.patch @@ -0,0 +1,43 @@ +commit 809642a08787638d9682149de25d36ee273902ff +Author: Øvind Kolå +Date: Thu Apr 5 18:49:54 2012 +0200 + + tools/create-reference.rb: fix utf8 handling for ruby >= 1.9.x + + A patch from Tim Mooney, fixing bug #673523 + + tools/create-reference.rb | 5 +++++ + 1 files changed, 5 insertions(+), 0 deletions(-) +--- +Index: gegl-0.2.0/tools/create-reference.rb +=================================================================== +--- gegl-0.2.0.orig/tools/create-reference.rb ++++ gegl-0.2.0/tools/create-reference.rb +@@ -5,6 +5,11 @@ + # Use under a public domain license. + # + ++if RUBY_VERSION =~ /^1.9/ or RUBY_VERSION =~ /^[2345]/ ++ Encoding.default_external = Encoding::UTF_8 ++ Encoding.default_internal = Encoding::UTF_8 ++end ++ + class Argument + attr_accessor :name, :data_type, :doc + def initialize +Index: gegl-0.2.0/tools/gobj2dot.rb +=================================================================== +--- gegl-0.2.0.orig/tools/gobj2dot.rb ++++ gegl-0.2.0/tools/gobj2dot.rb +@@ -15,6 +15,11 @@ + # + # Copyright (C) 2009 Henrik Akesson + ++if RUBY_VERSION =~ /^1.9/ or RUBY_VERSION =~ /^[2345]/ ++ Encoding.default_external = Encoding::UTF_8 ++ Encoding.default_internal = Encoding::UTF_8 ++end ++ + require 'find' + + if ARGV[0] == nil or ARGV.length != 1 or ARGV[0] == "-h" diff --git a/gegl.changes b/gegl.changes index 318338f..e33c900 100644 --- a/gegl.changes +++ b/gegl.changes @@ -1,3 +1,10 @@ +------------------------------------------------------------------- +Fri May 18 09:50:52 UTC 2012 - dimstar@opensuse.org + +- Add gegl-ruby19.patch: Fix build with ruby 1.9. +- Add liberation-fonts: the documentation references bitstream + vera sans font, so we need to provide it for the build. + ------------------------------------------------------------------- Tue Apr 3 08:45:42 UTC 2012 - vuntz@opensuse.org diff --git a/gegl.spec b/gegl.spec index e716538..a5a14d1 100644 --- a/gegl.spec +++ b/gegl.spec @@ -32,6 +32,8 @@ BuildRequires: graphviz-gd BuildRequires: gtk2-devel BuildRequires: intltool BuildRequires: lensfun-devel +# Needed to build the doc, as Bitstream Vera Sans is the referenced font. +BuildRequires: liberation-fonts BuildRequires: libexiv2-devel BuildRequires: libjasper-devel >= 1.900.1 BuildRequires: libjpeg-devel @@ -66,6 +68,8 @@ Group: System/Libraries Source: http://ftp.gtk.org/pub/gegl/0.2/%{name}-%{version}.tar.bz2 # PATCH-FIX-UPSTREAM gegl-lua52.patch bgo#667675 vuntz@opensuse.org -- Fix build with lua 5.2 Patch0: gegl-lua52.patch +# PATCH-FIX-UPSTREAM gegl-ruby19.patch dimstar@opensuse.org -- Fix build with ruby 1.9 +Patch1: gegl-ruby19.patch BuildRoot: %{_tmppath}/%{name}-%{version}-build %define debug_package_requires libgegl-0_2-0 = %{version}-%{release} @@ -144,6 +148,7 @@ input and output. %prep %setup -q %patch0 -p1 +%patch1 -p1 # docs-build-fix.diff %build