aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--ChangeLog5
-rwxr-xr-xtool/rbinstall.rb4
2 files changed, 7 insertions, 2 deletions
diff --git a/ChangeLog b/ChangeLog
index 34904e3203..1729cd5eec 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+Sun Oct 30 10:50:36 2011 Nobuyoshi Nakada <nobu@ruby-lang.org>
+
+ * tool/rbinstall.rb (install_recursive, bin-comm): split mere
+ string not path name. [ruby-core:40462] [Bug #5492]
+
Sun Oct 30 10:47:20 2011 Nobuyoshi Nakada <nobu@ruby-lang.org>
* io.c (rb_cloexec_dup, rb_cloexec_dup2): CLOEXEC has been set if
diff --git a/tool/rbinstall.rb b/tool/rbinstall.rb
index 399ca67559..6bfc73e0d1 100755
--- a/tool/rbinstall.rb
+++ b/tool/rbinstall.rb
@@ -241,7 +241,7 @@ def install_recursive(srcdir, dest, options = {})
if dir
makedirs(d)
else
- makedirs(File.dirname(d))
+ makedirs(d[/.*(?=\/)/m])
if block_given?
yield src, d, opts
else
@@ -443,7 +443,7 @@ install?(:local, :comm, :bin, :'bin-comm') do
trans = proc {|base| base}
end
install_recursive(File.join(srcdir, "bin"), bindir) do |src, cmd|
- cmd = File.join(File.dirname(cmd), RbConfig.expand(trans[File.basename(cmd)]))
+ cmd = cmd.sub(/[^\/]*\z/m) {|n| RbConfig.expand(trans[n])}
shebang = ''
body = ''