summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDavid Rodríguez <deivid.rodriguez@riseup.net>2021-08-08 10:21:32 +0200
committerHiroshi SHIBATA <hsbt@ruby-lang.org>2021-08-31 19:06:14 +0900
commitafabef5a5ab067ee34e70be54fc1b3cfcad63862 (patch)
tree2a6b52ffe2ba7a4c7ac44f75aa051052e7b7ef9e
parent717ad64f4198066ae1eedfb166e38e8f00f44705 (diff)
[rubygems/rubygems] Remove MacOS specific gem layout
MacOS should properly configure Ruby. They should not expect us to maintain a different layout just for them. https://github.com/rubygems/rubygems/commit/ecad900925
Notes
Notes: Merged: https://github.com/ruby/ruby/pull/4789
-rw-r--r--lib/rubygems/defaults.rb22
1 files changed, 2 insertions, 20 deletions
diff --git a/lib/rubygems/defaults.rb b/lib/rubygems/defaults.rb
index e95bc06792..f29104a1b7 100644
--- a/lib/rubygems/defaults.rb
+++ b/lib/rubygems/defaults.rb
@@ -34,21 +34,7 @@ module Gem
# specified in the environment
def self.default_dir
- path = if defined? RUBY_FRAMEWORK_VERSION
- [
- File.dirname(RbConfig::CONFIG['sitedir']),
- 'Gems',
- RbConfig::CONFIG['ruby_version'],
- ]
- else
- [
- RbConfig::CONFIG['rubylibprefix'],
- 'gems',
- RbConfig::CONFIG['ruby_version'],
- ]
- end
-
- @default_dir ||= File.join(*path)
+ @default_dir ||= File.join(RbConfig::CONFIG['rubylibprefix'], 'gems', RbConfig::CONFIG['ruby_version'])
end
##
@@ -197,11 +183,7 @@ module Gem
# The default directory for binaries
def self.default_bindir
- if defined? RUBY_FRAMEWORK_VERSION # mac framework support
- '/usr/local/bin'
- else # generic install
- RbConfig::CONFIG['bindir']
- end
+ RbConfig::CONFIG['bindir']
end
def self.ruby_engine