ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/AnyEvent/constants.pl.PL
(Generate patch)

Comparing AnyEvent/constants.pl.PL (file contents):
Revision 1.1 by root, Sun Feb 21 09:28:18 2010 UTC vs.
Revision 1.2 by root, Fri Mar 12 23:30:06 2010 UTC

15i CYGWIN => $^O =~ /cygwin/i; 15i CYGWIN => $^O =~ /cygwin/i;
16i WIN32 => $WIN32; 16i WIN32 => $WIN32;
17 17
18use Fcntl (); 18use Fcntl ();
19 19
20i F_SETFL => Fcntl::F_SETFL(); 20i F_SETFL => eval { Fcntl::F_SETFL() };
21i F_SETFD => Fcntl::F_SETFD(); 21i F_SETFD => eval { Fcntl::F_SETFD() };
22i O_NONBLOCK => Fcntl::O_NONBLOCK(); 22i O_NONBLOCK => eval { Fcntl::O_NONBLOCK() };
23i FD_CLOEXEC => Fcntl::FD_CLOEXEC(); 23i FD_CLOEXEC => eval { Fcntl::FD_CLOEXEC() };
24 24
25print "package AnyEvent::Util;\n"; 25print "package AnyEvent::Util;\n";
26 26
27# broken windows perls use undocumented error codes... 27# broken windows perls use undocumented error codes...
28if ($WIN32) { 28if ($WIN32) {
36 i WSAEINPROGRESS => -1e99; 36 i WSAEINPROGRESS => -1e99;
37} 37}
38 38
39my $af_inet6; 39my $af_inet6;
40 40
41$af_inet6 ||= eval { use Socket ; Socket::AF_INET6 () }; 41$af_inet6 ||= eval { require Socket ; Socket::AF_INET6 () };
42$af_ine6t ||= eval { use Socket6; Socket6::AF_INET6() }; 42$af_ine6t ||= eval { require Socket6; Socket6::AF_INET6() };
43 43
44# uhoh 44# uhoh
45$af_inet6 ||= 10 if $^O =~ /linux/; 45$af_inet6 ||= 10 if $^O =~ /linux/;
46$af_inet6 ||= 23 if $^O =~ /cygwin/i; 46$af_inet6 ||= 23 if $^O =~ /cygwin/i;
47$af_inet6 ||= 23 if AnyEvent::WIN32; 47$af_inet6 ||= 23 if AnyEvent::WIN32;

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines