Commit 22fed962 authored by Martin Storsjö's avatar Martin Storsjö

configure: Include windows.h before checking the _WIN32_WINNT version

The default value of _WIN32_WINNT isn't something that is built into
the compiler, but is defined by the toolchain headers.

Include windows.h after including ws2tcpip.h/winsock2.h, since those
headers should be included in that particular order.
parent 7729ccef
......@@ -665,10 +665,11 @@ AC_SEARCH_LIBS([inet_pton], [nsl], [
LIBS="${LIBS} ${SOCKET_LIBS}"
AC_LINK_IFELSE([
AC_LANG_PROGRAM([#ifdef _WIN32
#include <ws2tcpip.h>
#include <windows.h>
# if _WIN32_WINNT < 0x600
# error Needs vista+
# endif
#include <ws2tcpip.h>
#else
#include <sys/socket.h>
#include <arpa/inet.h>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment