We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent f55e188 commit b641d4bCopy full SHA for b641d4b
1 file changed
Lib/test/test_cext/setup.py
@@ -17,11 +17,14 @@
17
# The purpose of test_cext extension is to check that building a C
18
# extension using the Python C API does not emit C compiler warnings.
19
'-Werror',
20
-
21
- # gh-116869: The Python C API must be compatible with building
22
- # with the -Werror=declaration-after-statement compiler flag.
23
- '-Werror=declaration-after-statement',
24
]
+ # Free Threading doesn't build with -Werror=declaration-after-statement
+ if not sysconfig.get_config_var('Py_GIL_DISABLED'):
+ CFLAGS.append(
+ # gh-116869: The Python C API must be compatible with building
25
+ # with the -Werror=declaration-after-statement compiler flag.
26
+ '-Werror=declaration-after-statement',
27
+ )
28
else:
29
# Don't pass any compiler flag to MSVC
30
CFLAGS = []
0 commit comments