Predefine __USE_W32_SOCKETS for Cygwin in allheaders test

This is required to avoid warnings (and worse, probably) due to
conflicting function declarations in the platform SDK and Cygwin headers
that have started happening since 8dfcb582da (Regenerate configure after
enabling IPv6 support by default, 2021-06-15).
This commit is contained in:
Vadim Zeitlin 2021-06-15 16:44:24 +01:00
parent c0f2430ee4
commit 3d7f9877fb

View File

@ -36,6 +36,13 @@
// We have to include this one first in order to check for wxUSE_XXX below. // We have to include this one first in order to check for wxUSE_XXX below.
#include "wx/setup.h" #include "wx/setup.h"
// Normally this is done in wx/defs.h, but as we don't include it here, we need
// to do it manually to avoid warnings inside the standard headers included
// from catch.hpp.
#if defined(__CYGWIN__) && defined(__WINDOWS__)
#define __USE_W32_SOCKETS
#endif
#include "catch.hpp" #include "catch.hpp"
#if defined(__WXQT__) #if defined(__WXQT__)