aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authornobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2016-05-16 04:29:01 +0000
committernobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2016-05-16 04:29:01 +0000
commit8bb6ef73d9bd0b20fb40b2487e02c29383d710af (patch)
treedbc6abf0d1b882d988038416011a4ed8ad91bafa
parent44620b66926fa3858c6cf9934eb981bf7f444156 (diff)
downloadruby-8bb6ef73d9bd0b20fb40b2487e02c29383d710af.tar.gz
configure.in: revert macro names
* configure.in (FUNC_STDCALL, FUNC_CDECL, FUNC_FASTCALL): set macro names explicitly to the old names, which are accidentally changed at r54985, for backward compatibilities. fiddle also depends on these names to fallback to ANSI names. [ruby-core:75494] [Bug #12377] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@55015 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
-rw-r--r--ChangeLog8
-rw-r--r--configure.in6
-rw-r--r--test/fiddle/test_handle.rb7
3 files changed, 18 insertions, 3 deletions
diff --git a/ChangeLog b/ChangeLog
index 786640f..2fc2f14 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,11 @@
+Mon May 16 13:28:59 2016 Nobuyoshi Nakada <nobu@ruby-lang.org>
+
+ * configure.in (FUNC_STDCALL, FUNC_CDECL, FUNC_FASTCALL): set
+ macro names explicitly to the old names, which are accidentally
+ changed at r54985, for backward compatibilities.
+ fiddle also depends on these names to fallback to ANSI names.
+ [ruby-core:75494] [Bug #12377]
+
Mon May 16 11:39:02 2016 SHIBATA Hiroshi <hsbt@ruby-lang.org>
* lib/xmlrpc.rb, lib/xmlrpc/*, test/xmlrpc: XMLRPC is bundled gem
diff --git a/configure.in b/configure.in
index 5bafeca..c1ccae5 100644
--- a/configure.in
+++ b/configure.in
@@ -1815,9 +1815,9 @@ if test "$rb_cv_func_weak" != x; then
fi
if_i386=${universal_binary+[defined __i386__]}
-RUBY_FUNC_ATTRIBUTE(__stdcall__, [], [], ${if_i386})
-RUBY_FUNC_ATTRIBUTE(__cdecl__, [], [], ${if_i386})
-RUBY_FUNC_ATTRIBUTE(__fastcall__, [], [], ${if_i386})
+RUBY_FUNC_ATTRIBUTE(__stdcall__, FUNC_STDCALL, rb_cv_func_stdcall, ${if_i386})
+RUBY_FUNC_ATTRIBUTE(__cdecl__, FUNC_CDECL, rb_cv_func_cdecl, ${if_i386})
+RUBY_FUNC_ATTRIBUTE(__fastcall__, FUNC_FASTCALL, rb_cv_func_fastcall, ${if_i386})
RUBY_FUNC_ATTRIBUTE(__optimize__("O0"), FUNC_UNOPTIMIZED, rb_cv_func_unoptimized)
RUBY_FUNC_ATTRIBUTE(__optimize__("-Os","-fomit-frame-pointer"), FUNC_MINIMIZED, rb_cv_func_minimized)
diff --git a/test/fiddle/test_handle.rb b/test/fiddle/test_handle.rb
index fecf366..6ac957a 100644
--- a/test/fiddle/test_handle.rb
+++ b/test/fiddle/test_handle.rb
@@ -182,5 +182,12 @@ module Fiddle
def test_no_memory_leak
assert_no_memory_leak(%w[-W0 -rfiddle.so], '', '100_000.times {Fiddle::Handle.allocate}; GC.start', rss: true)
end
+
+ if /cygwin|mingw|mswin/ =~ RUBY_PLATFORM
+ def test_fallback_to_ansi
+ k = Fiddle::Handle.new("kernel32.dll")
+ refute_nil(k["GetFileAttributes"])
+ end
+ end
end
end if defined?(Fiddle)