[rubygem-rdoc/f18: 1/2] Fix the location of Ruby documentation.

Vít Ondruch vondruch at fedoraproject.org
Thu Sep 6 12:29:34 UTC 2012


commit 959b1350c57a8ce9db99b4b5e4bde0783151afcc
Author: Vít Ondruch <vondruch at redhat.com>
Date:   Thu Sep 6 14:28:10 2012 +0200

    Fix the location of Ruby documentation.

 ruby-1.9.3-disable-versioned-paths.patch |   21 +++++++++++++++++++++
 rubygem-rdoc.spec                        |   10 +++++++++-
 2 files changed, 30 insertions(+), 1 deletions(-)
---
diff --git a/ruby-1.9.3-disable-versioned-paths.patch b/ruby-1.9.3-disable-versioned-paths.patch
new file mode 100644
index 0000000..babf5b4
--- /dev/null
+++ b/ruby-1.9.3-disable-versioned-paths.patch
@@ -0,0 +1,21 @@
+From fa1a50ad10814f724b8713865dc222724cb955ab Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?V=C3=ADt=20Ondruch?= <vondruch at redhat.com>
+Date: Thu, 25 Aug 2011 14:33:51 +0200
+Subject: [PATCH] Allow to disable versioned paths.
+
+diff --git a/lib/rdoc/ri/paths.rb b/lib/rdoc/ri/paths.rb
+index a3c65bf..0575730 100644
+--- a/lib/rdoc/ri/paths.rb
++++ b/lib/rdoc/ri/paths.rb
+@@ -11,9 +11,9 @@ module RDoc::RI::Paths
+   version = RbConfig::CONFIG['ruby_version']
+ 
+   base    = if RbConfig::CONFIG.key? 'ridir' then
+-              File.join RbConfig::CONFIG['ridir'], version
++              File.join [RbConfig::CONFIG['ridir'], RbConfig::CONFIG['USE_VERSIONED_PATHS'] == 'YES' ? version : nil].compact
+             else
+-              File.join RbConfig::CONFIG['datadir'], 'ri', version
++              File.join [RbConfig::CONFIG['datadir'], 'ri', RbConfig::CONFIG['USE_VERSIONED_PATHS'] == 'YES' ? version : nil].compact
+             end
+ 
+   SYSDIR  = File.join base, "system"
diff --git a/rubygem-rdoc.spec b/rubygem-rdoc.spec
index 9cce01b..6be04a3 100644
--- a/rubygem-rdoc.spec
+++ b/rubygem-rdoc.spec
@@ -6,11 +6,12 @@
 Summary: RDoc produces HTML and command-line documentation for Ruby projects
 Name: rubygem-%{gem_name}
 Version: 3.12
-Release: 4%{?dist}
+Release: 5%{?dist}
 Group: Development/Languages
 License: GPLv2 and Ruby and MIT
 URL: http://docs.seattlerb.org/rdoc/
 Source0: http://rubygems.org/gems/%{gem_name}-%{version}.gem
+Patch0: ruby-1.9.3-disable-versioned-paths.patch
 Requires: ruby(rubygems)
 Requires: ruby(abi) = %{rubyabi}
 Requires: rubygem(json) => 1.4
@@ -48,6 +49,10 @@ gem install --local --install-dir .%{gem_dir} \
             --bindir .%{_bindir} \
             --force %{SOURCE0}
 
+pushd .%{gem_instdir}
+%patch0 -p1
+popd
+
 %build
 
 %install
@@ -97,6 +102,9 @@ popd
 
 
 %changelog
+* Thu Sep 06 2012 Vít Ondruch <vondruch at redhat.com> - 3.12-5
+- Fix the location of Ruby documentation.
+
 * Sat Jul 21 2012 Fedora Release Engineering <rel-eng at lists.fedoraproject.org> - 3.12-4
 - Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
 


More information about the scm-commits mailing list