From f63873e7a2d07e23694148ea500da3baf09cc680 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?David=20Rodr=C3=ADguez?= Date: Wed, 2 Oct 2024 16:35:23 +0200 Subject: [rubygems/rubygems] Remove more compatibility code with old RubyGems https://github.com/rubygems/rubygems/commit/74e8eff779 --- lib/bundler/rubygems_integration.rb | 9 --------- lib/bundler/source/git.rb | 2 +- lib/bundler/source/rubygems.rb | 2 +- 3 files changed, 2 insertions(+), 11 deletions(-) (limited to 'lib') diff --git a/lib/bundler/rubygems_integration.rb b/lib/bundler/rubygems_integration.rb index e77704aa0a..e952eea776 100644 --- a/lib/bundler/rubygems_integration.rb +++ b/lib/bundler/rubygems_integration.rb @@ -57,15 +57,6 @@ module Bundler nil end - def spec_missing_extensions?(spec, default = true) - return spec.missing_extensions? if spec.respond_to?(:missing_extensions?) - - return false if spec.default_gem? - return false if spec.extensions.empty? - - default - end - def stub_set_spec(stub, spec) stub.instance_variable_set(:@spec, spec) end diff --git a/lib/bundler/source/git.rb b/lib/bundler/source/git.rb index 3b934adbb2..ef36efb3f4 100644 --- a/lib/bundler/source/git.rb +++ b/lib/bundler/source/git.rb @@ -210,7 +210,7 @@ module Bundler checkout end - generate_bin_options = { disable_extensions: !Bundler.rubygems.spec_missing_extensions?(spec), build_args: options[:build_args] } + generate_bin_options = { disable_extensions: !spec.missing_extensions?, build_args: options[:build_args] } generate_bin(spec, generate_bin_options) requires_checkout? ? spec.post_install_message : nil diff --git a/lib/bundler/source/rubygems.rb b/lib/bundler/source/rubygems.rb index 3b6ef8bd58..4219bda3bd 100644 --- a/lib/bundler/source/rubygems.rb +++ b/lib/bundler/source/rubygems.rb @@ -357,7 +357,7 @@ module Bundler @installed_specs ||= Index.build do |idx| Bundler.rubygems.installed_specs.reverse_each do |spec| spec.source = self - if Bundler.rubygems.spec_missing_extensions?(spec, false) + if spec.missing_extensions? Bundler.ui.debug "Source #{self} is ignoring #{spec} because it is missing extensions" next end -- cgit v1.2.3