1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

socket/extconf.rb: check struct in_addr6

* ext/socket/extconf.rb: check struct in_addr6, which is defined in
  VC6 instead of in6_addr.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@40192 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
nobu 2013-04-08 17:42:48 +00:00
parent 99ad10df32
commit f12df1a752
2 changed files with 8 additions and 1 deletions

View file

@ -1,4 +1,7 @@
Tue Apr 9 02:40:53 2013 Nobuyoshi Nakada <nobu@ruby-lang.org>
Tue Apr 9 02:42:44 2013 Nobuyoshi Nakada <nobu@ruby-lang.org>
* ext/socket/extconf.rb: check struct in_addr6, which is defined in
VC6 instead of in6_addr.
* ext/socket/option.c (optname_to_sym): fix macro name.

View file

@ -477,6 +477,10 @@ EOS
if getaddr_info_ok == :wide or
!have_func("getnameinfo", headers) or !have_func("getaddrinfo", headers)
if !have_type("struct in6_addr", headers) and have_type("struct in_addr6", headers)
$defs.pop(2)
$defs << "-Din_addr6=in6_addr"
end
if have_struct_member("struct in6_addr", "s6_addr8", headers)
$defs[-1] = "s6_addr=s6_addr8"
end