lib/mkmf/lite.rb in mkmf-lite-0.4.0 vs lib/mkmf/lite.rb in mkmf-lite-0.4.1

- old
+ new

@@ -1,15 +1,14 @@ require 'erb' require 'rbconfig' require 'tmpdir' -require 'ptools' require 'open3' module Mkmf module Lite # The version of the mkmf-lite library - MKMF_LITE_VERSION = '0.4.0'.freeze + MKMF_LITE_VERSION = '0.4.1'.freeze private def cpp_command command = RbConfig::CONFIG['CC'] || RbConfig::CONFIG['CPP'] || File.which('cc') || File.which('gcc') || File.which('cl') @@ -169,12 +168,12 @@ command = cpp_command + ' ' command += cpp_out_file + ' ' command += cpp_source_file # Temporarily close these - $stderr.reopen(File.null) - $stdout.reopen(File.null) + $stderr.reopen(IO::NULL) + $stdout.reopen(IO::NULL) if system(command) $stdout.reopen(stdout_orig) # We need this back for open3 to work. conftest = File::ALT_SEPARATOR ? "conftest.exe" : "./conftest.exe" @@ -221,11 +220,11 @@ end command += cpp_out_file + ' ' command += cpp_source_file - $stderr.reopen(File.null) - $stdout.reopen(File.null) + $stderr.reopen(IO::NULL) + $stdout.reopen(IO::NULL) boolean = system(command) } ensure File.delete(cpp_source_file) if File.exists?(cpp_source_file) File.delete(cpp_out_file) if File.exists?(cpp_out_file)