summaryrefslogtreecommitdiff
path: root/ext/dl/extconf.rb
diff options
context:
space:
mode:
authorttate <ttate@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2002-04-03 11:59:01 +0000
committerttate <ttate@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2002-04-03 11:59:01 +0000
commit74b4c8139695c52123e8db0761c78bb071a61271 (patch)
tree5d135f00ed93cc1fffa4675aeeccc56e2fa245e9 /ext/dl/extconf.rb
parent493c57f65a3cde9c0268584aacd93a55782484ef (diff)
Merge Nakada's patch and define StringValuePtr for ruby-1.6.
CV ---------------------------------------------------------------------- git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2330 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'ext/dl/extconf.rb')
-rw-r--r--ext/dl/extconf.rb11
1 files changed, 5 insertions, 6 deletions
diff --git a/ext/dl/extconf.rb b/ext/dl/extconf.rb
index 372f1b1384..ea4ebfdf9a 100644
--- a/ext/dl/extconf.rb
+++ b/ext/dl/extconf.rb
@@ -20,8 +20,7 @@ end
($CPPFLAGS || $CFLAGS) << " -I."
-case RUBY_PLATFORM # from Win32API
-when /cygwin/,/mingw/
+if (Config::CONFIG['CC'] =~ /gcc/) # from Win32API
$CFLAGS << " -fno-defer-pop -fno-omit-frame-pointer"
end
@@ -56,11 +55,11 @@ $with_type_voidp &= DLTYPE[VOIDP][:sym]
$with_cbtype_voidp = DLTYPE[VOIDP][:cb]
-$with_type_char = with_config("type-char") ? true : false
-$with_type_short = with_config("type-short") ? true : false
-$with_type_float = with_config("type-float") ? true : false
+$with_type_char = enable_config("type-char", $with_type_char)
+$with_type_short = enable_config("type-short", $with_type_short)
+$with_type_float = enable_config("type-float", $with_type_float)
-$with_asm = with_config("asm") ? true : $with_asm
+$with_asm = enable_config("asm", $with_asm)
args = with_config("args")
max_arg = max_cbarg = max_cbent = nil