]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
bpo-39026: Fix Python.h when building with Xcode (GH-29488) (GH-29776)
authorVictor Stinner <vstinner@python.org>
Fri, 26 Nov 2021 09:59:31 +0000 (10:59 +0100)
committerGitHub <noreply@github.com>
Fri, 26 Nov 2021 09:59:31 +0000 (10:59 +0100)
Fix Python.h to build C extensions with Xcode: remove a relative
include from Include/cpython/pystate.h.

(cherry picked from commit 4ae26b9c1d0c33e3db92c6f305293f9240dea358)

Include/Python.h
Include/cpython/pystate.h
Misc/NEWS.d/next/C API/2021-11-09-15-42-11.bpo-39026.sUnYWn.rst [new file with mode: 0644]

index 6ee52e7492837321c7337e65b4d3e6b943dd1b40..7f7ed5981c5c77dcc7bca11786f20026e4dcb5c3 100644 (file)
 #include "sliceobject.h"
 #include "cellobject.h"
 #include "iterobject.h"
+#include "cpython/initconfig.h"
 #include "genobject.h"
 #include "descrobject.h"
 #include "genericaliasobject.h"
 
 #include "codecs.h"
 #include "pyerrors.h"
-
-#include "cpython/initconfig.h"
 #include "pythread.h"
 #include "pystate.h"
 #include "context.h"
index f292da1d3c6c5ee48ceaad0639b9cb42d4414d9f..0eb601fd7c55ece76d5f75cb94af9fd0921efc5c 100644 (file)
@@ -6,8 +6,6 @@
 extern "C" {
 #endif
 
-#include "cpython/initconfig.h"
-
 PyAPI_FUNC(int) _PyInterpreterState_RequiresIDRef(PyInterpreterState *);
 PyAPI_FUNC(void) _PyInterpreterState_RequireIDRef(PyInterpreterState *, int);
 
diff --git a/Misc/NEWS.d/next/C API/2021-11-09-15-42-11.bpo-39026.sUnYWn.rst b/Misc/NEWS.d/next/C API/2021-11-09-15-42-11.bpo-39026.sUnYWn.rst
new file mode 100644 (file)
index 0000000..77a0119
--- /dev/null
@@ -0,0 +1,2 @@
+Fix Python.h to build C extensions with Xcode: remove a relative include
+from ``Include/cpython/pystate.h``.