- Fix RHASH_SIZE related fix failure
This commit is contained in:
Mamoru TASAKA 2015-01-18 02:58:16 +09:00
parent cf4c5a985e
commit 30b385f1da
2 changed files with 28 additions and 8 deletions

View File

@ -0,0 +1,14 @@
--- ferret-0.11.8.4/ext/r_analysis.c.ruby22hash 2015-01-18 02:41:02.096371434 +0900
+++ ferret-0.11.8.4/ext/r_analysis.c 2015-01-18 02:46:51.435722105 +0900
@@ -65,7 +65,11 @@
frb_rb_hash_size(VALUE hash)
{
#ifdef FRT_RUBY_VERSION_1_9
+#ifdef RHASH_SIZE
+ return RHASH_SIZE(hash);
+#else
return RHASH(hash)->ntbl->num_entries;
+#endif
#else
return RHASH(hash)->tbl->num_entries;
#endif

View File

@ -3,7 +3,7 @@
Summary: Full-featured text search engine library
Name: rubygem-%{gem_name}
Version: 0.11.8.4
Release: 8%{?dist}
Release: 9%{?dist}
Group: Development/Languages
# License from
# - MIT-LICENSE: MIT
@ -19,6 +19,8 @@ Patch0: rubygem-ferret-0.11.8.4-Fix-compatibily-with-minitest.patch
# https://github.com/jkraemer/ferret/pull/5
Patch1: rubygem-ferret-0.11.8.4-make-rake-just-development-dependency.patch
Patch2: rubygem-ferret-0.11.8.4-Block-variables-has-local-scopes.patch
# See https://bugs.ruby-lang.org/issues/9889
Patch3: rubygem-ferret-0.11.8.4-ruby22-hashsize.patch
BuildRequires: rubygems-devel
BuildRequires: ruby-devel
BuildRequires: rubygem(minitest) < 5
@ -39,19 +41,19 @@ BuildArch: noarch
This package contains documentation for %{name}.
%prep
%setup -q -c -T
%gem_install -n %{SOURCE0}
gem unpack %{SOURCE0}
%setup -q -D -T -n %{gem_name}-%{version}
pushd .%{gem_instdir}
%patch0 -p2
%patch2 -p2
popd
%patch3 -p1
pushd .%{gem_dir}
%patch1
popd
gem spec %{SOURCE0} -l --ruby > %{gem_name}-%{version}.gemspec
%patch1 -p1
%build
gem build %{gem_name}-%{version}.gemspec
%gem_install
%install
mkdir -p %{buildroot}%{gem_dir}
@ -108,6 +110,10 @@ popd
%{gem_instdir}/test/
%changelog
* Sun Jan 18 2015 Mamoru TASAKA <mtasaka@fedoraproject.org> - 0.11.8.4-9
- Rebuild for https://fedoraproject.org/wiki/Changes/Ruby_2.2
- Fix RHASH_SIZE related fix failure
* Mon Aug 18 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.11.8.4-8
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_22_Mass_Rebuild