Skip to content

Commit 5787ba4

Browse files
authored
bpo-41111: Don't build xxlimited with Py_TRACE_REFS macro (GH-25180)
1 parent 354b015 commit 5787ba4

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

setup.py

+4-3
Original file line numberDiff line numberDiff line change
@@ -1864,9 +1864,10 @@ def detect_modules(self):
18641864
## # Uncomment these lines if you want to play with xxmodule.c
18651865
## self.add(Extension('xx', ['xxmodule.c']))
18661866

1867-
# Limited C API
1868-
self.add(Extension('xxlimited', ['xxlimited.c']))
1869-
self.add(Extension('xxlimited_35', ['xxlimited_35.c']))
1867+
# The limited C API is not compatible with the Py_TRACE_REFS macro.
1868+
if not sysconfig.get_config_var('Py_TRACE_REFS'):
1869+
self.add(Extension('xxlimited', ['xxlimited.c']))
1870+
self.add(Extension('xxlimited_35', ['xxlimited_35.c']))
18701871

18711872
def detect_tkinter_fromenv(self):
18721873
# Build _tkinter using the Tcl/Tk locations specified by

0 commit comments

Comments
 (0)