summaryrefslogtreecommitdiff
path: root/lib/bundler/rubygems_ext.rb
diff options
context:
space:
mode:
authorHan Young <hanyang.tony@bytedance.com>2023-11-01 11:58:31 +0800
committergit <svn-admin@ruby-lang.org>2023-11-08 12:40:22 +0000
commitb4bf8c9ee2d716adf5fc08e67c4b26d6a8f929c2 (patch)
tree89b7673621de3d6a70f20cddecb473a0ecfe933d /lib/bundler/rubygems_ext.rb
parent7efe0669ae6194962dbd2abad359a761cee3f552 (diff)
[rubygems/rubygems] Ensure we are using the same extension dir
Since #6945 the extension dir changed to Gem::BasicSpecification's implementation, we didn't hook that in rubygems_ext.rb. So for universal rubies, we ended up using the universal platform name when installing, but arch replaced platform name when checking. This lead to native extensions can never be correctly installed on universal rubies. Hook Gem::BasicSpecifications so the behavior is consistent on installing and checking. https://github.com/rubygems/rubygems/commit/8d699ed096
Diffstat (limited to 'lib/bundler/rubygems_ext.rb')
-rw-r--r--lib/bundler/rubygems_ext.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/bundler/rubygems_ext.rb b/lib/bundler/rubygems_ext.rb
index dadac408b7..0296fc543d 100644
--- a/lib/bundler/rubygems_ext.rb
+++ b/lib/bundler/rubygems_ext.rb
@@ -338,7 +338,7 @@ module Gem
end
# On universal Rubies, resolve the "universal" arch to the real CPU arch, without changing the extension directory.
- class Specification
+ class BasicSpecification
if /^universal\.(?<arch>.*?)-/ =~ (CROSS_COMPILING || RUBY_PLATFORM)
local_platform = Platform.local
if local_platform.cpu == "universal"