On 9/22/05, Simon Josefsson <[EMAIL PROTECTED]> wrote:
> Mingw32 doesn't have sys/types.h, arpa/inet.h or netinet/in.h.  But if
> you include winsock2.h instead of those three header files, most (?)
> POSIX socket functions work.

I doubt that any POSIX socket functions in winsock2 will conform to
the specification, or even reasonably reliably be useful.  There are a
number of gotchas that need to be considered. e.g. errno is not set.

plibc is a very good POSIX compatibility library for mingw, and as an
example, here is the select implementation:

http://cvs.sourceforge.net/viewcvs.py/plibc/plibc/src/select.c?view=markup

Existing modules inet_ntop, getaddrinfo and poll, and any module that
depends on those (canon-host?), appear to use these headers, but only
a small part of the socket implementation is needed; supporting those
modules on Window sounds like a good start.

> Perhaps this should be considered a mingw32 bug instead?  Problem is
> this mingw32 cross compiler will likely be around for a while, since
> it is shipped with the latest Debian release..  So it might be useful
> to support even if it is broken.

MinGW does not consider this a bug because it aims to provide a
complete and compatible Win32 API, in order that programmers can
interchange MSVC and MinGW.

http://marc.theaimsgroup.com/?t=112472681900001&r=1&w=2

--
John


_______________________________________________
bug-gnulib mailing list
bug-gnulib@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-gnulib

Reply via email to