summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
-rw-r--r--build_config.rb10
1 files changed, 7 insertions, 3 deletions
diff --git a/build_config.rb b/build_config.rb
index c565d390f..bc9e69e42 100644
--- a/build_config.rb
+++ b/build_config.rb
@@ -123,9 +123,13 @@ MRuby::Build.new('test') do |conf|
end
MRuby::Build.new('bench') do |conf|
- toolchain :gcc
-
- conf.cc.flags << '-O3'
+ # Gets set by the VS command prompts.
+ if ENV['VisualStudioVersion'] || ENV['VSINSTALLDIR']
+ toolchain :visualcpp
+ else
+ toolchain :gcc
+ conf.cc.flags << '-O3'
+ end
conf.gembox 'default'
end