зеркало из https://github.com/github/ruby.git
* ext/socket/extconf.rb: don't define socklen_t here, just test.
* ext/socket/rubysocket.h: define socklen_t if not available. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@39225 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
Родитель
4b75145278
Коммит
22a04e5720
|
@ -1,3 +1,9 @@
|
||||||
|
Wed Feb 13 20:59:48 2013 Tanaka Akira <akr@fsij.org>
|
||||||
|
|
||||||
|
* ext/socket/extconf.rb: don't define socklen_t here, just test.
|
||||||
|
|
||||||
|
* ext/socket/rubysocket.h: define socklen_t if not available.
|
||||||
|
|
||||||
Wed Feb 13 18:37:50 2013 Nobuyoshi Nakada <nobu@ruby-lang.org>
|
Wed Feb 13 18:37:50 2013 Nobuyoshi Nakada <nobu@ruby-lang.org>
|
||||||
|
|
||||||
* proc.c (mnew): skip prepending modules and return the method bound
|
* proc.c (mnew): skip prepending modules and return the method bound
|
||||||
|
|
|
@ -56,9 +56,7 @@ have_header("ucred.h", headers)
|
||||||
|
|
||||||
have_type("struct addrinfo", headers)
|
have_type("struct addrinfo", headers)
|
||||||
|
|
||||||
unless have_type("socklen_t", headers)
|
have_type("socklen_t", headers)
|
||||||
$defs << "-Dsocklen_t=int"
|
|
||||||
end
|
|
||||||
|
|
||||||
have_type("struct in_pktinfo", headers) {|src|
|
have_type("struct in_pktinfo", headers) {|src|
|
||||||
src.sub(%r'^/\*top\*/', '\&'"\n#if defined(IPPROTO_IP) && defined(IP_PKTINFO)") <<
|
src.sub(%r'^/\*top\*/', '\&'"\n#if defined(IPPROTO_IP) && defined(IP_PKTINFO)") <<
|
||||||
|
|
|
@ -86,6 +86,10 @@
|
||||||
#include <ucred.h>
|
#include <ucred.h>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#ifndef HAVE_TYPE_SOCKLEN_T
|
||||||
|
typedef int socklen_t;
|
||||||
|
#endif
|
||||||
|
|
||||||
#ifndef EWOULDBLOCK
|
#ifndef EWOULDBLOCK
|
||||||
#define EWOULDBLOCK EAGAIN
|
#define EWOULDBLOCK EAGAIN
|
||||||
#endif
|
#endif
|
||||||
|
|
Загрузка…
Ссылка в новой задаче