[issue39026] Include/cpython/pystate.h contains non-relative of initconfig.h include causing macOS Framework include failure

STINNER Victor report at bugs.python.org
Wed Sep 29 05:36:53 EDT 2021


STINNER Victor <vstinner at python.org> added the comment:

I'm not sure why Include/cpython/ is part of the compiler include directories. I am not sure why Include/ is *not* part of the compiler include directory.

Anyway, it's hard to control how people build Python and there are always legit use cases where you fall into such issue.

That's why I suggest to fix any risk of confusion by renaming Include/cpython/ header files to add a "cpython_" prefix. For example, rename Include/cpython/pystate.h to Include/cpython/cpython_pystate.h.

In the Include/internal/ directory, header files already have a prefix for the exact same reason. For example, there is a pycore_pystate.h file there.

----------

_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue39026>
_______________________________________


More information about the Python-bugs-list mailing list