[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
MinGW-w64 Compatibility
From: |
Hoyt, David |
Subject: |
MinGW-w64 Compatibility |
Date: |
Tue, 14 Sep 2010 11:28:15 -0700 |
Hello,
The guys in the gnutls project mentioned that I should forward this on to you.
I don't know the structure or layout of gnulib, so I don't know how cleanly
what I'm talking about applies to the project, so please take it in context of
gnutls. Here was my message to the gnutls folks:
A build using the latest from MinGW-w64 fails with a redefinition error b/c it
finds socklen_t in two places. Configure finds both winsock2.h and ws2tcipip.h
and when it finds winsock.h, it does a "typedef int socklen_t" in
gl/sys_socket.in.h but this is already defined in ws2tcpip.h. When I specified
-D_WIN32_WINNT=0x0501 for Windows XP or higher support only, it compiled
cleanly. It looks like a guard is needed at line 154 of gl/sys_socket.in.h -
something along the lines of (this has not been tested):
#ifndef @HAVE_WS2TCPIP_H@
typedef int socklen_t;
#endif
Thanks,
- David Hoyt
- MinGW-w64 Compatibility,
Hoyt, David <=