Skip to content

Commit 728a881

Browse files
authored
[3.13] gh-135151: Fix incorrect packaging of pyconfig.h in Windows installer (GH-135180)
1 parent 922dc2c commit 728a881

File tree

3 files changed

+13
-1
lines changed

3 files changed

+13
-1
lines changed

Doc/howto/free-threading-extensions.rst

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,14 @@ You can use it to enable code that only runs under the free-threaded build::
2323
/* code that only runs in the free-threaded build */
2424
#endif
2525

26+
.. note::
27+
28+
On Windows, this macro is not defined automatically, but must be specified
29+
to the compiler when building. The :func:`sysconfig.get_config_var` function
30+
can be used to determine whether the current running interpreter had the
31+
macro defined.
32+
33+
2634
Module Initialization
2735
=====================
2836

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
Avoid distributing modified :file:`pyconfig.h` in the traditional installer.
2+
Extension module builds must always specify ``Py_GIL_DISABLED`` when
3+
targeting the free-threaded runtime.

Tools/msi/dev/dev_files.wxs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,8 @@
33
<Fragment>
44
<ComponentGroup Id="dev_pyconfig">
55
<Component Id="include_pyconfig.h" Directory="include" Guid="*">
6-
<File Id="include_pyconfig.h" Name="pyconfig.h" Source="pyconfig.h" KeyPath="yes" />
6+
<!-- gh-135151 Always use the unmodified header for the installer. -->
7+
<File Id="include_pyconfig.h" Name="pyconfig.h" Source="!(bindpath.src)PC\pyconfig.h.in" KeyPath="yes" />
78
</Component>
89
</ComponentGroup>
910
</Fragment>

0 commit comments

Comments
 (0)