From 7d79f355fcfb39c52f5b47f44c99c0e645d1878a Mon Sep 17 00:00:00 2001 From: nobu Date: Tue, 4 Sep 2012 01:40:11 +0000 Subject: rbinstall.rb: skip symlinks * tool/rbinstall.rb (install_recursive): skip symlinks, which are made by `make runnable'. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@36897 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- tool/rbinstall.rb | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'tool') diff --git a/tool/rbinstall.rb b/tool/rbinstall.rb index c36057af59..26eab1cd01 100755 --- a/tool/rbinstall.rb +++ b/tool/rbinstall.rb @@ -227,9 +227,11 @@ def install_recursive(srcdir, dest, options = {}) Dir.foreach(file) do |f| src = File.join(file, f) d = File.join(dest, dir = src[subpath]) - stat = File.stat(src) rescue next + stat = File.lstat(src) rescue next if stat.directory? files << [src, d, true] if /\A\./ !~ f and !prune[dir] + elsif stat.symlink? + # skip else files << [src, d, false] if File.fnmatch?(glob, f) and !skip[f] end -- cgit v1.2.3