summaryrefslogtreecommitdiff
path: root/ext/extmk.rb
diff options
context:
space:
mode:
authorkosaki <kosaki@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2012-05-18 06:19:25 +0000
committerkosaki <kosaki@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2012-05-18 06:19:25 +0000
commit899bf4981a17846ac205383e47fa0cf8428dacd0 (patch)
tree1dddb57b3d43037fe67358208ee94483812615e3 /ext/extmk.rb
parentd17b97ce641ffa055f22ef8badcf4340909f643a (diff)
* ext/extmk.rb: Show a message when extconf.rb raised an exception.
* ext/openssl/extconf.rb: Use exception raising instead of message and/or abort. We want to display error message to console _and_ logging into mkmf.log. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@35685 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'ext/extmk.rb')
-rwxr-xr-xext/extmk.rb12
1 files changed, 11 insertions, 1 deletions
diff --git a/ext/extmk.rb b/ext/extmk.rb
index e7593ac..a498268 100755
--- a/ext/extmk.rb
+++ b/ext/extmk.rb
@@ -205,6 +205,8 @@ def extmake(target)
end
rescue SystemExit
# ignore
+ rescue => error
+ ok = false
ensure
rm_f "conftest*"
$0 = $PROGRAM_NAME
@@ -217,7 +219,15 @@ def extmake(target)
f.puts "# " + DUMMY_SIGNATURE
f.print(*dummy_makefile(CONFIG["srcdir"]))
end
- print "Failed to configure #{target}. It will not be installed.\n"
+
+ mess = "Failed to configure #{target}. It will not be installed.\n"
+ if error
+ mess.prepend(error.to_s + "\n")
+ end
+
+ Logging::message(mess)
+ print(mess)
+ $stdout.flush
return true
end
args = sysquote($mflags)