Skip to content

Commit e702061

Browse files
committed
ENH: Globally enable Cython free-threading directive
This is the Cython equivalent of adding a `Py_mod_gil` slot with `Py_MOD_GIL_NOT_USED` like we did in pandas-dev#59135.
1 parent 39bd3d3 commit e702061

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

meson.build

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,11 @@ else
4444
meson.add_dist_script(py, versioneer, '-o', '_version_meson.py')
4545
endif
4646

47+
cy = meson.get_compiler('cython')
48+
if cy.version().version_compare('>=3.1.0')
49+
add_global_arguments('-Xfreethreading_compatible=true', language : 'cython')
50+
endif
51+
4752
# Needed by pandas.test() when it looks for the pytest ini options
4853
py.install_sources(
4954
'pyproject.toml',

0 commit comments

Comments
 (0)