[DRE-commits] [rubygems-integration] 07/10: Add workaround for Ruby 2.2 and gem2deb < 0.18.2

Antonio Terceiro terceiro at moszumanska.debian.org
Wed Jun 17 22:17:13 UTC 2015


This is an automated email from the git hooks/post-receive script.

terceiro pushed a commit to branch master
in repository rubygems-integration.

commit f460cb11667c30857e1f7e5f0652509456855b46
Author: Antonio Terceiro <terceiro at softwarelivre.org>
Date:   Wed Jun 17 19:10:29 2015 -0300

    Add workaround for Ruby 2.2 and gem2deb < 0.18.2
    
    gem2deb < 0.18.2 installed gemspecs to directories named after the short Ruby
    version (2.2) instead of the API_VERSION (2.2.0). There was already a similar
    workaround for Ruby 2.1, so this should have been fixed a long time ago.
---
 debian/changelog                          | 6 +++++-
 lib/rubygems/defaults/operating_system.rb | 2 ++
 2 files changed, 7 insertions(+), 1 deletion(-)

diff --git a/debian/changelog b/debian/changelog
index 6709b83..7046661 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,9 +1,13 @@
 rubygems-integration (1.9) UNRELEASED; urgency=medium
 
-  * Include /usr/lib/$(triplet)/rubygems-integration/$(ruby_version) in the
+  * Include /usr/lib/$(triplet)/rubygems-integration/$(api_version) in the
     Rubygems path. This will be used to support Debian packages that install
     as "proper gems".
   * debian/tests/control: run specs against installed package.
+  * Add workaround for Ruby 2.2 because gem2deb < 0.18.2 installed
+    gemspecs to directories named after the short Ruby version (2.2) instead
+    of the API_VERSION (2.2.0). There was already a similar workaround for
+    Ruby 2.1, so this should have been fixed a long time ago.
 
  -- Antonio Terceiro <terceiro at debian.org>  Thu, 02 Oct 2014 11:24:35 -0300
 
diff --git a/lib/rubygems/defaults/operating_system.rb b/lib/rubygems/defaults/operating_system.rb
index 0df294d..f25584a 100644
--- a/lib/rubygems/defaults/operating_system.rb
+++ b/lib/rubygems/defaults/operating_system.rb
@@ -20,6 +20,8 @@ class << Gem
     extra_path = nil
     if RbConfig::CONFIG['ruby_version'] == '2.1.0'
       extra_path = File.join('/usr/share/rubygems-integration', '2.1')
+    elsif RbConfig::CONFIG['ruby_version'] == '2.2.0'
+      extra_path = File.join('/usr/share/rubygems-integration', '2.2')
     end
 
     arch = Gem::ConfigMap[:arch]

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-ruby-extras/rubygems-integration.git



More information about the Pkg-ruby-extras-commits mailing list