summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorSamuel Giddins <segiddins@segiddins.me>2023-09-02 15:53:27 -0500
committergit <svn-admin@ruby-lang.org>2023-10-15 04:46:32 +0000
commit83f929316e2ef860469886d8001b69a67f15a406 (patch)
tree698b67a2e4d27d6782469fa3627ce9cb61c0fea3 /lib
parent48c6cea330259a66ccf9757b06418b0653ec1dfb (diff)
[rubygems/rubygems] Fix force_ruby_platform: when the lockfile only locks the ruby platform
https://github.com/rubygems/rubygems/commit/7c50064c3c
Diffstat (limited to 'lib')
-rw-r--r--lib/bundler/spec_set.rb1
1 files changed, 1 insertions, 0 deletions
diff --git a/lib/bundler/spec_set.rb b/lib/bundler/spec_set.rb
index 21630e3a3e..c69392d612 100644
--- a/lib/bundler/spec_set.rb
+++ b/lib/bundler/spec_set.rb
@@ -202,6 +202,7 @@ module Bundler
specs_for_name = lookup[dep.name]
target_platform = dep.force_ruby_platform ? Gem::Platform::RUBY : (platform || Bundler.local_platform)
matching_specs = GemHelpers.select_best_platform_match(specs_for_name, target_platform)
+ matching_specs.each {|s| s.force_ruby_platform = true } if dep.force_ruby_platform
matching_specs.map!(&:materialize_for_installation).compact! if platform.nil?
matching_specs
end