* ext/socket/extconf.rb (in_pktinfo, in6_pktinfo),
ext/socket/ancdata.c: defined in w32api/ws2tcpip.h on cygwin but cannot compile for some reason. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@21985 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
e53c88a44f
commit
b256c5fb8f
@ -1,3 +1,9 @@
|
|||||||
|
Tue Feb 3 07:57:58 2009 Nobuyoshi Nakada <nobu@ruby-lang.org>
|
||||||
|
|
||||||
|
* ext/socket/extconf.rb (in_pktinfo, in6_pktinfo),
|
||||||
|
ext/socket/ancdata.c: defined in w32api/ws2tcpip.h on cygwin but
|
||||||
|
cannot compile for some reason.
|
||||||
|
|
||||||
Tue Feb 3 07:02:11 2009 Nobuyoshi Nakada <nobu@ruby-lang.org>
|
Tue Feb 3 07:02:11 2009 Nobuyoshi Nakada <nobu@ruby-lang.org>
|
||||||
|
|
||||||
* missing/langinfo.c (nl_langinfo_codeset): accepts iso-8859
|
* missing/langinfo.c (nl_langinfo_codeset): accepts iso-8859
|
||||||
|
@ -188,7 +188,7 @@ ancillary_int(VALUE self)
|
|||||||
static VALUE
|
static VALUE
|
||||||
ancillary_s_ip_pktinfo(VALUE self, VALUE v_addr, VALUE v_ifindex, VALUE v_spec_dst)
|
ancillary_s_ip_pktinfo(VALUE self, VALUE v_addr, VALUE v_ifindex, VALUE v_spec_dst)
|
||||||
{
|
{
|
||||||
#if defined(IPPROTO_IP) && defined(IP_PKTINFO) /* GNU/Linux */
|
#if defined(IPPROTO_IP) && defined(IP_PKTINFO) && defined(HAVE_TYPE_STRUCT_IN_PKTINFO) /* GNU/Linux */
|
||||||
unsigned int ifindex;
|
unsigned int ifindex;
|
||||||
struct sockaddr_in sa;
|
struct sockaddr_in sa;
|
||||||
struct in_pktinfo pktinfo;
|
struct in_pktinfo pktinfo;
|
||||||
@ -226,7 +226,7 @@ ancillary_s_ip_pktinfo(VALUE self, VALUE v_addr, VALUE v_ifindex, VALUE v_spec_d
|
|||||||
static VALUE
|
static VALUE
|
||||||
ancillary_ip_pktinfo(VALUE self)
|
ancillary_ip_pktinfo(VALUE self)
|
||||||
{
|
{
|
||||||
#if defined(IPPROTO_IP) && defined(IP_PKTINFO) /* GNU/Linux */
|
#if defined(IPPROTO_IP) && defined(IP_PKTINFO) && defined(HAVE_TYPE_STRUCT_IN_PKTINFO) /* GNU/Linux */
|
||||||
int level, type;
|
int level, type;
|
||||||
VALUE data;
|
VALUE data;
|
||||||
struct in_pktinfo pktinfo;
|
struct in_pktinfo pktinfo;
|
||||||
@ -397,7 +397,7 @@ anc_inspect_ip_recvdstaddr(int level, int type, VALUE data, VALUE ret)
|
|||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if defined(IPPROTO_IP) && defined(IP_PKTINFO) /* GNU/Linux */
|
#if defined(IPPROTO_IP) && defined(IP_PKTINFO) && defined(HAVE_TYPE_STRUCT_IN_PKTINFO) /* GNU/Linux */
|
||||||
static int
|
static int
|
||||||
anc_inspect_ip_pktinfo(int level, int type, VALUE data, VALUE ret)
|
anc_inspect_ip_pktinfo(int level, int type, VALUE data, VALUE ret)
|
||||||
{
|
{
|
||||||
@ -426,7 +426,7 @@ anc_inspect_ip_pktinfo(int level, int type, VALUE data, VALUE ret)
|
|||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if defined(IPPROTO_IPV6) && defined(IPV6_PKTINFO) /* IPv6 RFC3542 */
|
#if defined(IPPROTO_IPV6) && defined(IPV6_PKTINFO) && defined(HAVE_TYPE_STRUCT_IN6_PKTINFO) /* IPv6 RFC3542 */
|
||||||
static int
|
static int
|
||||||
anc_inspect_ipv6_pktinfo(int level, int type, VALUE data, VALUE ret)
|
anc_inspect_ipv6_pktinfo(int level, int type, VALUE data, VALUE ret)
|
||||||
{
|
{
|
||||||
@ -508,7 +508,7 @@ ancillary_inspect(VALUE self)
|
|||||||
# if defined(IP_RECVDSTADDR) /* 4.4BSD */
|
# if defined(IP_RECVDSTADDR) /* 4.4BSD */
|
||||||
case IP_RECVDSTADDR: if (anc_inspect_ip_recvdstaddr(level, type, data, ret) == -1) goto dump; break;
|
case IP_RECVDSTADDR: if (anc_inspect_ip_recvdstaddr(level, type, data, ret) == -1) goto dump; break;
|
||||||
# endif
|
# endif
|
||||||
# if defined(IP_PKTINFO) /* GNU/Linux */
|
# if defined(IP_PKTINFO) && defined(HAVE_TYPE_STRUCT_IN_PKTINFO) /* GNU/Linux */
|
||||||
case IP_PKTINFO: if (anc_inspect_ip_pktinfo(level, type, data, ret) == -1) goto dump; break;
|
case IP_PKTINFO: if (anc_inspect_ip_pktinfo(level, type, data, ret) == -1) goto dump; break;
|
||||||
# endif
|
# endif
|
||||||
default: goto dump;
|
default: goto dump;
|
||||||
|
@ -299,6 +299,14 @@ end
|
|||||||
|
|
||||||
have_header("sys/un.h")
|
have_header("sys/un.h")
|
||||||
have_header("sys/uio.h")
|
have_header("sys/uio.h")
|
||||||
|
have_type("struct in_pktinfo") {|src|
|
||||||
|
src.sub(%r'^/\*top\*/', '\1'"\n#if defined(IPPROTO_IP) && defined(IP_PKTINFO)") <<
|
||||||
|
"#else\n" << "#error\n" << ">>>>>> no in_pktinfo <<<<<<\n" << "#endif\n"
|
||||||
|
}
|
||||||
|
have_type("struct in6_pktinfo") {|src|
|
||||||
|
src.sub(%r'^/\*top\*/', '\1'"\n#if defined(IPPROTO_IPV6) && defined(IPV6_PKTINFO)") <<
|
||||||
|
"#else\n" << "#error\n" << ">>>>>> no in6_pktinfo <<<<<<\n" << "#endif\n"
|
||||||
|
}
|
||||||
|
|
||||||
$distcleanfiles << "constants.h" << "constdefs.*"
|
$distcleanfiles << "constants.h" << "constdefs.*"
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user