mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
* tool/rbinstall.rb (prepare): skip if basedir is not defined.
[ruby-core:39135][Bug #5238] * tool/rbinstall.rb (CONFIG.[]): check for mandatory configurations. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@34993 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
8a8936cbd0
commit
7e82db2e1e
2 changed files with 31 additions and 14 deletions
|
@ -1,3 +1,11 @@
|
||||||
|
Tue Mar 13 10:59:48 2012 Nobuyoshi Nakada <nobu@ruby-lang.org>
|
||||||
|
|
||||||
|
* tool/rbinstall.rb (prepare): skip if basedir is not defined.
|
||||||
|
[ruby-core:39135][Bug #5238]
|
||||||
|
|
||||||
|
* tool/rbinstall.rb (CONFIG.[]): check for mandatory
|
||||||
|
configurations.
|
||||||
|
|
||||||
Tue Mar 13 00:09:18 2012 Shugo Maeda <shugo@ruby-lang.org>
|
Tue Mar 13 00:09:18 2012 Shugo Maeda <shugo@ruby-lang.org>
|
||||||
|
|
||||||
* enumerator.c (enumerable_lazy): added documentation.
|
* enumerator.c (enumerable_lazy): added documentation.
|
||||||
|
|
|
@ -270,6 +270,7 @@ def with_destdir(dir)
|
||||||
end
|
end
|
||||||
|
|
||||||
def prepare(mesg, basedir, subdirs=nil)
|
def prepare(mesg, basedir, subdirs=nil)
|
||||||
|
return unless basedir
|
||||||
case
|
case
|
||||||
when !subdirs
|
when !subdirs
|
||||||
dirs = basedir
|
dirs = basedir
|
||||||
|
@ -286,31 +287,39 @@ def prepare(mesg, basedir, subdirs=nil)
|
||||||
makedirs(dirs)
|
makedirs(dirs)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
def CONFIG.[](name, mandatory = false)
|
||||||
|
value = super(name)
|
||||||
|
if mandatory
|
||||||
|
raise "CONFIG['#{name}'] must be set" if !value or value.empty?
|
||||||
|
end
|
||||||
|
value
|
||||||
|
end
|
||||||
|
|
||||||
exeext = CONFIG["EXEEXT"]
|
exeext = CONFIG["EXEEXT"]
|
||||||
|
|
||||||
ruby_install_name = CONFIG["ruby_install_name"]
|
ruby_install_name = CONFIG["ruby_install_name", true]
|
||||||
rubyw_install_name = CONFIG["rubyw_install_name"]
|
rubyw_install_name = CONFIG["rubyw_install_name"]
|
||||||
goruby_install_name = "go" + ruby_install_name
|
goruby_install_name = "go" + ruby_install_name
|
||||||
|
|
||||||
bindir = CONFIG["bindir"]
|
bindir = CONFIG["bindir", true]
|
||||||
libdir = CONFIG["libdir"]
|
libdir = CONFIG["libdir", true]
|
||||||
archhdrdir = rubyhdrdir = CONFIG["rubyhdrdir"]
|
archhdrdir = rubyhdrdir = CONFIG["rubyhdrdir", true]
|
||||||
archhdrdir += "/" + CONFIG["arch"]
|
archhdrdir += "/" + CONFIG["arch", true]
|
||||||
rubylibdir = CONFIG["rubylibdir"]
|
rubylibdir = CONFIG["rubylibdir", true]
|
||||||
archlibdir = CONFIG["archdir"]
|
archlibdir = CONFIG["archdir", true]
|
||||||
sitelibdir = CONFIG["sitelibdir"]
|
sitelibdir = CONFIG["sitelibdir"]
|
||||||
sitearchlibdir = CONFIG["sitearchdir"]
|
sitearchlibdir = CONFIG["sitearchdir"]
|
||||||
vendorlibdir = CONFIG["vendorlibdir"]
|
vendorlibdir = CONFIG["vendorlibdir"]
|
||||||
vendorarchlibdir = CONFIG["vendorarchdir"]
|
vendorarchlibdir = CONFIG["vendorarchdir"]
|
||||||
mandir = CONFIG["mandir"]
|
mandir = CONFIG["mandir", true]
|
||||||
capidir = CONFIG["docdir"]
|
capidir = CONFIG["docdir", true]
|
||||||
configure_args = Shellwords.shellwords(CONFIG["configure_args"])
|
configure_args = Shellwords.shellwords(CONFIG["configure_args"])
|
||||||
enable_shared = CONFIG["ENABLE_SHARED"] == 'yes'
|
enable_shared = CONFIG["ENABLE_SHARED"] == 'yes'
|
||||||
dll = CONFIG["LIBRUBY_SO"]
|
dll = CONFIG["LIBRUBY_SO", enable_shared]
|
||||||
lib = CONFIG["LIBRUBY"]
|
lib = CONFIG["LIBRUBY", true]
|
||||||
arc = CONFIG["LIBRUBY_A"]
|
arc = CONFIG["LIBRUBY_A", true]
|
||||||
major = CONFIG["MAJOR"]
|
major = CONFIG["MAJOR", true]
|
||||||
minor = CONFIG["MINOR"]
|
minor = CONFIG["MINOR", true]
|
||||||
load_relative = configure_args.include?("--enable-load-relative")
|
load_relative = configure_args.include?("--enable-load-relative")
|
||||||
|
|
||||||
install?(:local, :arch, :bin, :'bin-arch') do
|
install?(:local, :arch, :bin, :'bin-arch') do
|
||||||
|
|
Loading…
Reference in a new issue