[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: gai_strerror on mingw32
From: |
Eric Blake |
Subject: |
Re: gai_strerror on mingw32 |
Date: |
Wed, 27 Jun 2007 22:35:50 +0000 (UTC) |
User-agent: |
Loom/3.14 (http://gmane.org/) |
Bruno Haible <bruno <at> clisp.org> writes:
> How about this?
>
> 2007-06-27 Simon Josefsson <simon <at> josefsson.org>
> Bruno Haible <bruno <at> clisp.org>
>
> * m4/getaddrinfo.m4 (gl_GETADDRINFO): Check for ws2tcpip.h before
> using HAVE_WS2TCPIP_H. Check for gai_strerror through an explicit
> link test, rather than AC_REPLACE_FUNCS - for mingw.
> (gl_PREREQ_GETADDRINFO): Check for sys/socket.h and ws2tcpip.h
> before using HAVE_SYS_SOCKET_H and HAVE_WS2TCPIP_H.
Won't work on cygwin.
> - AC_REPLACE_FUNCS(gai_strerror)
> + # We can't use AC_REPLACE_FUNCS here because gai_strerror may be an
> + # inline function declared in ws2tcpip.h, so we need to get that
> + # header included somehow.
> + AC_CHECK_HEADERS_ONCE(sys/socket.h netdb.h ws2tcpip.h)
Checking for ws2tcpip.h is problematic. Instead, you need to reuse the check
made in m4/sys_socket_h.m4, since ws2tcpip.h is present but cannot be compiled
on cygwin.
--
Eric Blake