diff options
author | eban <eban@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2003-10-13 14:59:25 +0000 |
---|---|---|
committer | eban <eban@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2003-10-13 14:59:25 +0000 |
commit | 0edd700825c636bc25b7577ccae5424487f09bb5 (patch) | |
tree | 27f9b78b13f64783c678f7a770d8bb86fb79f4fc /test | |
parent | 2bf7c15a49046e4292519aab38a9350f9ab3a266 (diff) | |
download | ruby-0edd700825c636bc25b7577ccae5424487f09bb5.tar.gz ruby-0edd700825c636bc25b7577ccae5424487f09bb5.tar.xz ruby-0edd700825c636bc25b7577ccae5424487f09bb5.zip |
* test/ruby/envutil.rb: use Config::CONFIG["ruby_install_name"],
not "ruby".
git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@4752 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'test')
-rw-r--r-- | test/ruby/envutil.rb | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/test/ruby/envutil.rb b/test/ruby/envutil.rb index 186fcae1e..4bae3d9e3 100644 --- a/test/ruby/envutil.rb +++ b/test/ruby/envutil.rb @@ -5,9 +5,17 @@ module EnvUtil if File.exist? miniruby or File.exist? miniruby+".exe" return File.expand_path(miniruby) end - miniruby = "../"+miniruby + miniruby = File.join("..", miniruby) + end + begin + require "rbconfig" + File.join( + Config::CONFIG["bindir"], + Config::CONFIG["ruby_install_name"] + Config::CONFIG["EXEEXT"] + ) + rescue LoadError + "ruby" end - "ruby" end module_function :rubybin end |