summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'dev-lang/ruby/files/3.1/010-default-gem-location.patch')
-rw-r--r--dev-lang/ruby/files/3.1/010-default-gem-location.patch20
1 files changed, 20 insertions, 0 deletions
diff --git a/dev-lang/ruby/files/3.1/010-default-gem-location.patch b/dev-lang/ruby/files/3.1/010-default-gem-location.patch
new file mode 100644
index 000000000000..039a44b0530b
--- /dev/null
+++ b/dev-lang/ruby/files/3.1/010-default-gem-location.patch
@@ -0,0 +1,20 @@
+--- a/tool/rbinstall.rb.~1~ 2020-12-25 04:33:01.000000000 +0100
++++ b/tool/rbinstall.rb 2020-12-25 10:05:34.629096405 +0100
+@@ -897,7 +897,7 @@
+ end
+
+ def install_default_gem(dir, srcdir, bindir)
+- gem_dir = Gem.default_dir
++ gem_dir = ENV['GEM_DESTDIR']
+ install_dir = with_destdir(gem_dir)
+ prepare "default gems from #{dir}", gem_dir
+ makedirs(Gem.ensure_default_gem_subdirectories(install_dir, $dir_mode).map {|d| File.join(gem_dir, d)})
+@@ -1018,7 +1018,7 @@
+ end
+ Gem.instance_variable_set(:@ruby, ruby_path) if Gem.ruby != ruby_path
+
+- gem_dir = Gem.default_dir
++ gem_dir = ENV['GEM_DESTDIR']
+ install_dir = with_destdir(gem_dir)
+ prepare "bundled gems", gem_dir
+ RbInstall.no_write do