From 269503b544247b5b3e30dbe60a0bab4f2ca00e4e Mon Sep 17 00:00:00 2001 From: naruse Date: Sat, 14 Sep 2013 08:59:02 +0000 Subject: Revert r42938 "* lib/rubygems: Update to RubyGems 2.1.3" It breaks build. http://u64.rubyci.org/~chkbuild/ruby-trunk/log/20130913T200302Z.diff.html.gz git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@42941 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- lib/rubygems/platform.rb | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) (limited to 'lib/rubygems/platform.rb') diff --git a/lib/rubygems/platform.rb b/lib/rubygems/platform.rb index 4a4674b72f..247ee6ed3e 100644 --- a/lib/rubygems/platform.rb +++ b/lib/rubygems/platform.rb @@ -2,6 +2,8 @@ require "rubygems/deprecate" ## # Available list of platforms for targeting Gem installations. +# +# See `gem help platform` for information on platform matching. class Gem::Platform @@ -129,12 +131,16 @@ class Gem::Platform # Does +other+ match this platform? Two platforms match if they have the # same CPU, or either has a CPU of 'universal', they have the same OS, and # they have the same version, or either has no version. + # + # Additionally, the platform will match if the local CPU is 'arm' and the + # other CPU starts with "arm" (for generic ARM family support). def ===(other) return nil unless Gem::Platform === other # cpu - (@cpu == 'universal' or other.cpu == 'universal' or @cpu == other.cpu) and + (@cpu == 'universal' or other.cpu == 'universal' or @cpu == other.cpu or + (@cpu == 'arm' and other.cpu =~ /\Aarm/)) and # os @os == other.os and @@ -175,13 +181,13 @@ class Gem::Platform end ## - # A pure-ruby gem that may use Gem::Specification#extensions to build + # A pure-Ruby gem that may use Gem::Specification#extensions to build # binary files. RUBY = 'ruby' ## - # A platform-specific gem that is built for the packaging ruby's platform. + # A platform-specific gem that is built for the packaging Ruby's platform. # This will be replaced with Gem::Platform::local. CURRENT = 'current' -- cgit v1.2.3