mirror of
https://github.com/python/cpython.git
synced 2025-07-07 19:35:27 +00:00
gh-133779: Revert Windows generation of pyconfig.h and go back to a static header. (GH-133966)
Extension builders must specify Py_GIL_DISABLED if they want to link to the free-threaded builds. This was usually the case already, but this change guarantees it in all circumstances.
This commit is contained in:
parent
d55e11b804
commit
986c367028
13 changed files with 63 additions and 78 deletions
|
@ -3,7 +3,7 @@
|
|||
<Fragment>
|
||||
<ComponentGroup Id="dev_pyconfig">
|
||||
<Component Id="include_pyconfig.h" Directory="include" Guid="*">
|
||||
<File Id="include_pyconfig.h" Name="pyconfig.h" Source="pyconfig.h" KeyPath="yes" />
|
||||
<File Id="include_pyconfig.h" Name="pyconfig.h" Source="!(bindpath.src)PC\pyconfig.h" KeyPath="yes" />
|
||||
</Component>
|
||||
</ComponentGroup>
|
||||
</Fragment>
|
||||
|
|
|
@ -108,6 +108,8 @@ def compile_c_extension(
|
|||
extra_compile_args.append("-DPy_BUILD_CORE_MODULE")
|
||||
# Define _Py_TEST_PEGEN to not call PyAST_Validate() in Parser/pegen.c
|
||||
extra_compile_args.append("-D_Py_TEST_PEGEN")
|
||||
if sys.platform == "win32" and sysconfig.get_config_var("Py_GIL_DISABLED"):
|
||||
extra_compile_args.append("-DPy_GIL_DISABLED")
|
||||
extra_link_args = get_extra_flags("LDFLAGS", "PY_LDFLAGS_NODIST")
|
||||
if keep_asserts:
|
||||
extra_compile_args.append("-UNDEBUG")
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue