]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
gh-79218: Define `MS_WIN64` macro for Mingw-w64 64bit on Windows (GH-100137)
authorGalaxySnail <me@glxys.nl>
Mon, 12 Dec 2022 13:39:23 +0000 (21:39 +0800)
committerGitHub <noreply@github.com>
Mon, 12 Dec 2022 13:39:23 +0000 (13:39 +0000)
Misc/NEWS.d/next/Windows/2022-12-09-22-47-42.gh-issue-79218.Yiot2e.rst [new file with mode: 0644]
PC/pyconfig.h

diff --git a/Misc/NEWS.d/next/Windows/2022-12-09-22-47-42.gh-issue-79218.Yiot2e.rst b/Misc/NEWS.d/next/Windows/2022-12-09-22-47-42.gh-issue-79218.Yiot2e.rst
new file mode 100644 (file)
index 0000000..e2e6ca3
--- /dev/null
@@ -0,0 +1 @@
+Define ``MS_WIN64`` for Mingw-w64 64bit, fix cython compilation failure.
index 1a33d4c5a1e4fcf982698073bde678415ac0302c..1d8408b363a66a5953d2a2f6f656216c938c7b3e 100644 (file)
@@ -209,6 +209,16 @@ typedef int pid_t;
 
 #endif /* _MSC_VER */
 
+/* ------------------------------------------------------------------------*/
+/* mingw and mingw-w64 define __MINGW32__ */
+#ifdef __MINGW32__
+
+#ifdef _WIN64
+#define MS_WIN64
+#endif
+
+#endif /* __MINGW32__*/
+
 /* ------------------------------------------------------------------------*/
 /* egcs/gnu-win32 defines __GNUC__ and _WIN32 */
 #if defined(__GNUC__) && defined(_WIN32)