From ff6520b0f77e25dc269164c1be8853f808de06a0 Mon Sep 17 00:00:00 2001 From: hsbt Date: Tue, 15 May 2018 10:10:33 +0000 Subject: Added workaround to fileutils for `make btest` without rbconfig. Followed up r63430. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63434 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- lib/fileutils.rb | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) (limited to 'lib') diff --git a/lib/fileutils.rb b/lib/fileutils.rb index fa96599b84..e6cff63591 100644 --- a/lib/fileutils.rb +++ b/lib/fileutils.rb @@ -548,7 +548,11 @@ module FileUtils module_function :move def rename_cannot_overwrite_file? #:nodoc: - /emx/ =~ RbConfig::CONFIG['host_os'] + if defined?(RbConfig) + /emx/ =~ RbConfig::CONFIG['host_os'] + else + /emx/ =~ RUBY_PLATFORM + end end private_module_function :rename_cannot_overwrite_file? @@ -1153,7 +1157,11 @@ module FileUtils private def fu_windows? - /mswin|mingw|bccwin|emx/ =~ RbConfig::CONFIG['host_os'] + if defined?(RbConfig) + /mswin|mingw|bccwin|emx/ =~ RbConfig::CONFIG['host_os'] + else + /mswin|mingw|bccwin|emx/ =~ RUBY_PLATFORM + end end def fu_copy_stream0(src, dest, blksize = nil) #:nodoc: -- cgit v1.2.3