diff --git a/build/cmake/setup.h.in b/build/cmake/setup.h.in index db6e294e51..910ab84305 100644 --- a/build/cmake/setup.h.in +++ b/build/cmake/setup.h.in @@ -691,11 +691,7 @@ #cmakedefine01 wxUSE_GRAPHICS_DIRECT2D #endif -#if defined(_MSC_VER) || defined(__MINGW64_VERSION_MAJOR) - #cmakedefine01 wxUSE_WEBREQUEST_WINHTTP -#else - #cmakedefine01 wxUSE_WEBREQUEST_WINHTTP -#endif +#cmakedefine01 wxUSE_WEBREQUEST_WINHTTP #cmakedefine01 wxUSE_OLE diff --git a/include/wx/gtk/setup.h b/include/wx/gtk/setup.h index 77b1827e0f..6695285e4a 100644 --- a/include/wx/gtk/setup.h +++ b/include/wx/gtk/setup.h @@ -1650,11 +1650,7 @@ // // Recommended setting: 1, can be set to 0 if wxUSE_WEBREQUEST_CURL==1, // otherwise wxWebRequest won't be available at all. -#if defined(_MSC_VER) || defined(__MINGW64_VERSION_MAJOR) - #define wxUSE_WEBREQUEST_WINHTTP 1 -#else - #define wxUSE_WEBREQUEST_WINHTTP 0 -#endif +#define wxUSE_WEBREQUEST_WINHTTP 1 // ---------------------------------------------------------------------------- // Windows-only settings diff --git a/include/wx/msw/chkconf.h b/include/wx/msw/chkconf.h index 87ac46f30d..f9a3ac8aba 100644 --- a/include/wx/msw/chkconf.h +++ b/include/wx/msw/chkconf.h @@ -235,6 +235,11 @@ # define wxUSE_ACTIVITYINDICATOR 0 #endif /* !wxUSE_ACTIVITYINDICATOR && !_MSC_VER */ +/* MinGW-w64 (32 and 64 bit) has winhttp.h available, legacy MinGW does not. */ +#if (!defined(_MSC_VER) && !defined(__MINGW64_VERSION_MAJOR)) + #undef wxUSE_WEBREQUEST_WINHTTP + #define wxUSE_WEBREQUEST_WINHTTP 0 +#endif /* Similarly, turn off wxUSE_WEBREQUEST if we can't enable it because we don't have any of its backends to allow the library to compile with the default diff --git a/include/wx/msw/setup.h b/include/wx/msw/setup.h index 262f732c94..7b4494ce10 100644 --- a/include/wx/msw/setup.h +++ b/include/wx/msw/setup.h @@ -1650,11 +1650,7 @@ // // Recommended setting: 1, can be set to 0 if wxUSE_WEBREQUEST_CURL==1, // otherwise wxWebRequest won't be available at all. -#if defined(_MSC_VER) || defined(__MINGW64_VERSION_MAJOR) - #define wxUSE_WEBREQUEST_WINHTTP 1 -#else - #define wxUSE_WEBREQUEST_WINHTTP 0 -#endif +#define wxUSE_WEBREQUEST_WINHTTP 1 // ---------------------------------------------------------------------------- // Windows-only settings diff --git a/include/wx/msw/setup_inc.h b/include/wx/msw/setup_inc.h index 4957536e92..480b7a9344 100644 --- a/include/wx/msw/setup_inc.h +++ b/include/wx/msw/setup_inc.h @@ -44,11 +44,7 @@ // // Recommended setting: 1, can be set to 0 if wxUSE_WEBREQUEST_CURL==1, // otherwise wxWebRequest won't be available at all. -#if defined(_MSC_VER) || defined(__MINGW64_VERSION_MAJOR) - #define wxUSE_WEBREQUEST_WINHTTP 1 -#else - #define wxUSE_WEBREQUEST_WINHTTP 0 -#endif +#define wxUSE_WEBREQUEST_WINHTTP 1 // ---------------------------------------------------------------------------- // Windows-only settings diff --git a/setup.h.in b/setup.h.in index 711f4dc682..895b8f2b57 100644 --- a/setup.h.in +++ b/setup.h.in @@ -691,11 +691,7 @@ #define wxUSE_GRAPHICS_DIRECT2D 0 #endif -#if defined(_MSC_VER) || defined(__MINGW64_VERSION_MAJOR) - #define wxUSE_WEBREQUEST_WINHTTP 0 -#else - #define wxUSE_WEBREQUEST_WINHTTP 0 -#endif +#define wxUSE_WEBREQUEST_WINHTTP 0 #define wxUSE_OLE 0