You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I've been trying the PEP 803 changes in 3.15.0a8 with Meson, and I've hit the following build failure:
$ cc -I/usr/include/python3.15t -DPy_LIMITED_API=0x030f0000 limited.c
In file included from /usr/include/python3.15t/Python.h:79,
from limited.c:1:
/usr/include/python3.15t/object.h:162:5: error: unknown type name ‘PyMutex’
162 | PyMutex ob_mutex; // per-object lock
| ^~~~~~~
/usr/include/python3.15t/object.h: In function ‘_Py_SET_SIZE_impl’:
/usr/include/python3.15t/object.h:258:5: error: implicit declaration of function ‘_Py_atomic_store_ssize_relaxed’ [-Wimplicit-function-declaration]
258 | _Py_atomic_store_ssize_relaxed(&ob->ob_size, size);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from /usr/include/python3.15t/Python.h:80:
/usr/include/python3.15t/refcount.h: In function ‘_Py_IsImmortal’:
/usr/include/python3.15t/refcount.h:129:13: error: implicit declaration of function ‘_Py_atomic_load_uint32_relaxed’ [-Wimplicit-function-declaration]
129 | return (_Py_atomic_load_uint32_relaxed(&op->ob_ref_local) ==
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Per the description, setting Py_LIMITED_API=0x030f0000 when building with 3.15t should be sufficient to trigger abi3t build. However, the logic resides in patchlevel.h:
Bug report
Bug description:
I've been trying the PEP 803 changes in 3.15.0a8 with Meson, and I've hit the following build failure:
Per the description, setting
Py_LIMITED_API=0x030f0000when building with 3.15t should be sufficient to trigger abi3t build. However, the logic resides inpatchlevel.h:cpython/Include/patchlevel.h
Lines 76 to 79 in eab7dbd
which is included before
pyconfig.h:cpython/Include/Python.h
Lines 13 to 14 in eab7dbd
where
Py_GIL_DISABLEDis declared. As a result, the condition isn't true unless the user explicitly passes-DPy_GIL_DISABLED=1.CC @encukou @ngoldbaum
CPython versions tested on:
3.15, CPython main branch
Operating systems tested on:
Linux