diff options
author | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2009-08-21 16:29:33 +0000 |
---|---|---|
committer | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2009-08-21 16:29:33 +0000 |
commit | 7e97b9af8050bf121a81b82609870b24178a7d10 (patch) | |
tree | 814cdeda769c99665eca251a7919feb4bbf8e992 /lib/mkmf.rb | |
parent | 461bd62fec54d1026ef2496fbc9b9fd676f4d9d9 (diff) | |
download | ruby-7e97b9af8050bf121a81b82609870b24178a7d10.tar.gz |
* lib/mkmf.rb (rm_f, rm_rf): pass the last hash through if exists.
[ruby-dev:39153]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@24620 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'lib/mkmf.rb')
-rw-r--r-- | lib/mkmf.rb | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/lib/mkmf.rb b/lib/mkmf.rb index c5e4bd89b4..8d6fc96793 100644 --- a/lib/mkmf.rb +++ b/lib/mkmf.rb @@ -194,11 +194,13 @@ class Array end def rm_f(*files) - FileUtils.rm_f(Dir[*files]) + opt = ([files.pop] if Hash === files.last) + FileUtils.rm_f(Dir[*files], *opt) end def rm_rf(*files) - FileUtils.rm_rf(Dir[*files]) + opt = ([files.pop] if Hash === files.last) + FileUtils.rm_rf(Dir[*files], *opt) end # Returns time stamp of the +target+ file if it exists and is newer |