Remove --skip-depends and --default-source-index gem install options,
no longer needed. OK landry@
This commit is contained in:
parent
fe64996c4a
commit
2a9bbcdcc4
@ -1,11 +1,11 @@
|
||||
# $OpenBSD: Makefile,v 1.20 2010/10/06 18:12:19 jeremy Exp $
|
||||
# $OpenBSD: Makefile,v 1.21 2010/11/08 23:21:47 jeremy Exp $
|
||||
|
||||
COMMENT= package management framework for the Ruby language
|
||||
|
||||
V= 1.3.7
|
||||
DISTNAME= rubygems-$V
|
||||
PKGNAME= ruby-gems-$V
|
||||
REVISION = 0
|
||||
REVISION = 1
|
||||
CATEGORIES= devel
|
||||
|
||||
HOMEPAGE= http://docs.rubygems.org/
|
||||
|
@ -1,41 +0,0 @@
|
||||
$OpenBSD: patch-lib_rubygems_dependency_installer_rb,v 1.5 2010/10/06 18:12:19 jeremy Exp $
|
||||
|
||||
This is for GEM_SKIPDEPENDS in ruby.port.mk.
|
||||
|
||||
--- lib/rubygems/dependency_installer.rb.orig Wed Apr 21 21:43:02 2010
|
||||
+++ lib/rubygems/dependency_installer.rb Wed Oct 6 10:26:54 2010
|
||||
@@ -23,6 +23,7 @@ class Gem::DependencyInstaller
|
||||
:prerelease => false,
|
||||
:security_policy => nil, # HACK NoSecurity requires OpenSSL. AlmostNo? Low?
|
||||
:wrappers => true,
|
||||
+ :skip_dependencies => false
|
||||
}
|
||||
|
||||
##
|
||||
@@ -44,7 +45,7 @@ class Gem::DependencyInstaller
|
||||
# :wrappers:: See Gem::Installer::new
|
||||
|
||||
def initialize(options = {})
|
||||
- if options[:install_dir] then
|
||||
+ if options[:install_dir] and not options[:default_source_index] then
|
||||
spec_dir = options[:install_dir], 'specifications'
|
||||
@source_index = Gem::SourceIndex.from_gems_in spec_dir
|
||||
else
|
||||
@@ -64,6 +65,7 @@ class Gem::DependencyInstaller
|
||||
@security_policy = options[:security_policy]
|
||||
@user_install = options[:user_install]
|
||||
@wrappers = options[:wrappers]
|
||||
+ @skip_dependencies = options[:skip_dependencies]
|
||||
|
||||
@installed_gems = []
|
||||
|
||||
@@ -272,7 +274,8 @@ class Gem::DependencyInstaller
|
||||
:security_policy => @security_policy,
|
||||
:source_index => @source_index,
|
||||
:user_install => @user_install,
|
||||
- :wrappers => @wrappers
|
||||
+ :wrappers => @wrappers,
|
||||
+ :skip_dependencies => @skip_dependencies
|
||||
|
||||
spec = inst.install
|
||||
|
@ -1,23 +0,0 @@
|
||||
$OpenBSD: patch-lib_rubygems_install_update_options_rb,v 1.5 2010/10/06 18:12:19 jeremy Exp $
|
||||
|
||||
This is for GEM_SKIPDEPENDS in ruby.port.mk.
|
||||
|
||||
--- lib/rubygems/install_update_options.rb.orig Mon Apr 19 22:13:19 2010
|
||||
+++ lib/rubygems/install_update_options.rb Wed Oct 6 10:26:54 2010
|
||||
@@ -104,6 +104,16 @@ module Gem::InstallUpdateOptions
|
||||
"dependencies") do |value, options|
|
||||
options[:development] = true
|
||||
end
|
||||
+
|
||||
+ add_option(:"Install/Update", '-S', '--skip-dependencies DEPENDENCIES',
|
||||
+ 'Skip the given dependencies') do |value, options|
|
||||
+ options[:skip_dependencies] = value.split(' ')
|
||||
+ end
|
||||
+
|
||||
+ add_option(:"Install/Update", '--default-source-index',
|
||||
+ 'Use the default source-index') do |value, options|
|
||||
+ options[:default_source_index] = true
|
||||
+ end
|
||||
end
|
||||
|
||||
##
|
@ -1,28 +0,0 @@
|
||||
$OpenBSD: patch-lib_rubygems_installer_rb,v 1.9 2010/10/06 18:12:19 jeremy Exp $
|
||||
|
||||
This is for GEM_SKIPDEPENDS in ruby.port.mk.
|
||||
|
||||
--- lib/rubygems/installer.rb.orig Mon Apr 19 23:47:36 2010
|
||||
+++ lib/rubygems/installer.rb Wed Oct 6 10:26:54 2010
|
||||
@@ -113,6 +113,7 @@ class Gem::Installer
|
||||
@bin_dir = options[:bin_dir]
|
||||
@development = options[:development]
|
||||
@source_index = options[:source_index]
|
||||
+ @skip_dependencies = options[:skip_dependencies]
|
||||
|
||||
begin
|
||||
@format = Gem::Format.from_file_by_path @gem, @security_policy
|
||||
@@ -178,7 +179,12 @@ class Gem::Installer
|
||||
deps |= @spec.development_dependencies if @development
|
||||
|
||||
deps.each do |dep_gem|
|
||||
- ensure_dependency @spec, dep_gem
|
||||
+ if @skip_dependencies && @skip_dependencies.include?(dep_gem.name)
|
||||
+ say "Skipping '#{dep_gem.name}' dependency."
|
||||
+ @spec.dependencies.delete(dep_gem)
|
||||
+ else
|
||||
+ ensure_dependency @spec, dep_gem
|
||||
+ end
|
||||
end
|
||||
end
|
||||
end
|
Loading…
x
Reference in New Issue
Block a user