[rubygem-fog] Patch for Ruby 2.2 support

Josef Stribny jstribny at fedoraproject.org
Tue Mar 10 06:51:15 UTC 2015


commit 72594c3e68f42525d76fe7d157abdf77a72bb395
Author: Josef Stribny <jstribny at redhat.com>
Date:   Tue Mar 10 07:51:08 2015 +0100

    Patch for Ruby 2.2 support

 rubygem-fog.spec | 16 +++++++++++++---
 1 file changed, 13 insertions(+), 3 deletions(-)
---
diff --git a/rubygem-fog.spec b/rubygem-fog.spec
index 60b7b98..06bd1ca 100644
--- a/rubygem-fog.spec
+++ b/rubygem-fog.spec
@@ -3,12 +3,13 @@
 Summary: Brings clouds to you
 Name: rubygem-%{gem_name}
 Version: 1.23.0
-Release: 1%{?dist}
+Release: 2%{?dist}
 Group: Development/Languages
 License: MIT
 URL: http://github.com/geemus/fog
 Source0: http://rubygems.org/gems/%{gem_name}-%{version}.gem
-
+Patch0: rubygem-fog-1.27.0-support-ruby-2.2.patch
+Patch1: rubygem-fog-1.27.0-require-version.patch
 
 BuildRequires: rubygems-devel
 BuildRequires: rubygem(fog-brightbox)
@@ -40,6 +41,10 @@ Documentation for %{name}
 %setup -q -c -T
 %gem_install -n %{SOURCE0}
 
+pushd .%{gem_instdir}
+%patch0 -p1
+%patch1 -p1
+popd
 
 %build
 
@@ -73,7 +78,9 @@ sed -i "/require 'simplecov'/ s/^/#/" tests/helper.rb
 # https://github.com/fog/fog/issues/2986
 mv tests/hp/block_storage_tests.rb{,.bak}
 
-COVERAGE=false FOG_MOCK=true shindo
+# 1 failure: Newer fog-core puts itself to user agent
+# See https://github.com/fog/fog-core/blob/v1.27.0/lib/fog/core/connection.rb#L37
+COVERAGE=false FOG_MOCK=true shindo | grep '1 failed'
 popd
 
 
@@ -105,6 +112,9 @@ popd
 %doc %{gem_docdir}
 
 %changelog
+* Tue Mar 10 2015 Josef Stribny <jstribny at redhat.com> - 1.23.0-2
+- Patch for Ruby 2.2 support
+
 * Tue Jul 29 2014 Brett Lentz <blentz at redhat.com> - 1.23.0-1
 - Update to Fog 1.23.0.
 


More information about the scm-commits mailing list