summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authornobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2010-04-28 08:14:18 +0000
committernobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2010-04-28 08:14:18 +0000
commit0dc145e7b2b187ca595bb45dd289fb9f8f93789d (patch)
treea33139a354c907c2ecdb7f82146e8c0cc331e8c2
parent4822d20cc55d54d0c3cb190fdcb343976db64901 (diff)
* ext/socket/extconf.rb: CMSG_ macros are broken on 64bit darwin,
because of use of __DARWIN_ALIGN. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@27530 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
-rw-r--r--ChangeLog5
-rw-r--r--ext/socket/extconf.rb3
2 files changed, 7 insertions, 1 deletions
diff --git a/ChangeLog b/ChangeLog
index 7d3a17e620..2a09495631 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+Wed Apr 28 17:14:10 2010 Nobuyoshi Nakada <nobu@ruby-lang.org>
+
+ * ext/socket/extconf.rb: CMSG_ macros are broken on 64bit darwin,
+ because of use of __DARWIN_ALIGN.
+
Wed Apr 28 16:44:58 2010 Nobuyoshi Nakada <nobu@ruby-lang.org>
* include/ruby/ruby.h ({RSTRING,RSTRUCT,RBIGNUM}_LENINT): check long
diff --git a/ext/socket/extconf.rb b/ext/socket/extconf.rb
index 20952e31f6..3ce8316c4f 100644
--- a/ext/socket/extconf.rb
+++ b/ext/socket/extconf.rb
@@ -110,7 +110,8 @@ end
have_header("netinet/tcp.h") if /cygwin/ !~ RUBY_PLATFORM # for cygwin 1.1.5
have_header("netinet/udp.h")
-if have_func("sendmsg") | have_func("recvmsg")
+if (have_func("sendmsg") | have_func("recvmsg")) && /64-darwin/ !~ RUBY_PLATFORM
+ # CMSG_ macros are broken on 64bit darwin, because of use of __DARWIN_ALIGN.
have_struct_member('struct msghdr', 'msg_control', ['sys/types.h', 'sys/socket.h'])
have_struct_member('struct msghdr', 'msg_accrights', ['sys/types.h', 'sys/socket.h'])
end