summaryrefslogtreecommitdiffstats
path: root/PCbuild
diff options
context:
space:
mode:
authorSteve Dower <steve.dower@python.org>2024-02-26 19:14:14 (GMT)
committerGitHub <noreply@github.com>2024-02-26 19:14:14 (GMT)
commit37a13b941394a1337576c67bff35d4a44a1157e2 (patch)
tree226b0d2647c251a3ccb12fe2e3b25de476929dc5 /PCbuild
parent72cff8d8e5a476d3406efb0491452bf9d6b02feb (diff)
downloadcpython-37a13b941394a1337576c67bff35d4a44a1157e2.zip
cpython-37a13b941394a1337576c67bff35d4a44a1157e2.tar.gz
cpython-37a13b941394a1337576c67bff35d4a44a1157e2.tar.bz2
gh-115582: Make default PC/pyconfig.h work for free-threaded builds with manual /DPy_GIL_DISABLED (GH-115850)
Diffstat (limited to 'PCbuild')
-rw-r--r--PCbuild/pythoncore.vcxproj2
1 files changed, 1 insertions, 1 deletions
diff --git a/PCbuild/pythoncore.vcxproj b/PCbuild/pythoncore.vcxproj
index c7b698f..ef21f85 100644
--- a/PCbuild/pythoncore.vcxproj
+++ b/PCbuild/pythoncore.vcxproj
@@ -677,7 +677,7 @@
<OldPyConfigH Condition="Exists('$(IntDir)pyconfig.h')">$([System.IO.File]::ReadAllText('$(IntDir)pyconfig.h'))</OldPyConfigH>
</PropertyGroup>
<PropertyGroup Condition="$(DisableGil) == 'true'">
- <PyConfigHText>$(PyConfigHText.Replace('#undef Py_GIL_DISABLED', '#define Py_GIL_DISABLED 1'))</PyConfigHText>
+ <PyConfigHText>$(PyConfigHText.Replace('/* #define Py_GIL_DISABLED 1 */', '#define Py_GIL_DISABLED 1'))</PyConfigHText>
</PropertyGroup>
<Message Text="Updating pyconfig.h" Condition="$(PyConfigHText.TrimEnd()) != $(OldPyConfigH.TrimEnd())" />
<WriteLinesToFile File="$(IntDir)pyconfig.h"