pkgsrc/misc/rubygems/patches/patch-ab
minskim ba5c5dc0b8 Update rubygems to 1.3.4.
New features since 1.3.1:
* RubyGems now loads plugins from rubygems_plugin.rb in installed gems.
This can be used to add commands (See Gem::CommandManager) or add
install/uninstall hooks (See Gem::Installer and Gem::Uninstaller).
* Gem::Version now understands prerelease versions using letters. (eg.
'1.2.1.b') Thanks to Josh Susser, Alex Vollmer and Phil Hagelberg.
* RubyGems now includes a Rake task for creating gems which replaces rake's
Rake::GemPackageTask. See Gem::PackageTask.
* Gem::find_files now returns paths in $LOAD_PATH.
* Added Gem::promote_load_path for use with Gem::find_files
* Added Gem::bin_path to make finding executables easier. Patch #24114 by
James Tucker.
* Various improvements to build arguments for installing gems.
* `gem contents` added --all and --no-prefix.
* Gem::Specification
* #validate strips directories and errors on not-files.
* #description no longer removes newlines.
* #name must be a String.
* FIXME and TODO are no longer allowed in various fields.
* Added support for a license attribute. Feature #11041 (partial).
* Removed Gem::Specification::list, too much process growth. Bug #23668 by
Steve Purcell.
* `gem generate_index`
* Can now generate an RSS feed.
* Modern indicies can now be updated incrementally.
* Legacy indicies can be updated separately from modern.
* `gem server` allows port names (from /etc/services) with --port.
* `gem server` now has search that jumps to RDoc. Patch #22959 by Vladimir
Dobriakov.
* `gem spec` can retrieve single fields from a spec (like `gem spec rake
authors`).
* Gem::Specification#has_rdoc= is deprecated and ignored (defaults to true)
* RDoc is now generated regardless of Gem::Specification#has_rdoc?
2009-06-10 21:44:30 +00:00

47 lines
2.1 KiB
Text

$NetBSD: patch-ab,v 1.10 2009/06/10 21:44:31 minskim Exp $
--- lib/rubygems/dependency_installer.rb.orig 2009-03-04 17:07:04.000000000 -0800
+++ lib/rubygems/dependency_installer.rb
@@ -38,6 +38,7 @@ class Gem::DependencyInstaller
# :format_executable:: See Gem::Installer#initialize.
# :ignore_dependencies:: Don't install any dependencies.
# :install_dir:: See Gem::Installer#install.
+ # :install_root: See Gem::Installer#install.
# :prerelease:: Allow prerelease versions
# :security_policy:: See Gem::Installer::new and Gem::Security.
# :user_install:: See Gem::Installer.new
@@ -45,7 +46,11 @@ class Gem::DependencyInstaller
def initialize(options = {})
if options[:install_dir] then
- spec_dir = options[:install_dir], 'specifications'
+ if options[:install_root].nil? or options[:install_root] == "" then
+ spec_dir = options[:install_dir], 'specifications'
+ else
+ spec_dir = options[:install_root], options[:install_dir], 'specifications'
+ end
@source_index = Gem::SourceIndex.from_gems_in spec_dir
else
@source_index = Gem.source_index
@@ -68,7 +73,12 @@ class Gem::DependencyInstaller
@installed_gems = []
@install_dir = options[:install_dir] || Gem.dir
- @cache_dir = options[:cache_dir] || @install_dir
+ @install_root = options[:install_root]
+ install_dir = @install_dir
+ unless @install_root.nil? or @install_root == ""
+ install_dir = File.join(@install_root, @install_dir)
+ end
+ @cache_dir = options[:cache_dir] || install_dir
end
##
@@ -244,6 +254,7 @@ class Gem::DependencyInstaller
:format_executable => @format_executable,
:ignore_dependencies => @ignore_dependencies,
:install_dir => @install_dir,
+ :install_root => @install_root,
:security_policy => @security_policy,
:source_index => @source_index,
:user_install => @user_install,