diff --git a/Misc/NEWS.d/next/Windows/2025-05-07-11-25-29.gh-issue-133568.oYV0d8.rst b/Misc/NEWS.d/next/Windows/2025-05-07-11-25-29.gh-issue-133568.oYV0d8.rst new file mode 100644 index 00000000000000..1e2a5b582cbe7f --- /dev/null +++ b/Misc/NEWS.d/next/Windows/2025-05-07-11-25-29.gh-issue-133568.oYV0d8.rst @@ -0,0 +1 @@ +Fix compile error when using a WinAPI partition that doesn't support the RPC runtime library. diff --git a/Modules/socketmodule.h b/Modules/socketmodule.h index 63624d511c35a0..200b2b8c7d8310 100644 --- a/Modules/socketmodule.h +++ b/Modules/socketmodule.h @@ -259,7 +259,7 @@ typedef int SOCKET_T; #endif // AF_HYPERV is only supported on Windows -#if defined(AF_HYPERV) && defined(MS_WINDOWS) +#if defined(AF_HYPERV) && (defined(MS_WINDOWS_APP) || defined(MS_WINDOWS_SYSTEM)) # define HAVE_AF_HYPERV #endif