summaryrefslogtreecommitdiff
path: root/ext/win32ole/extconf.rb
diff options
context:
space:
mode:
Diffstat (limited to 'ext/win32ole/extconf.rb')
-rw-r--r--ext/win32ole/extconf.rb3
1 files changed, 2 insertions, 1 deletions
diff --git a/ext/win32ole/extconf.rb b/ext/win32ole/extconf.rb
index c371731..1a17524 100644
--- a/ext/win32ole/extconf.rb
+++ b/ext/win32ole/extconf.rb
@@ -30,6 +30,7 @@ end
case RUBY_PLATFORM
when /mswin/
- $CFLAGS += ' /W3'
+ $CFLAGS.sub!(/((?:\A|\s)[-\/])W\d(?=\z|\s)/, '\1W3') or
+ $CFLAGS += ' -W3'
end
create_win32ole_makefile