Steve Dower <steve.do...@python.org> added the comment:

distutils.sysconfig doesn't expose the headers path either, it's only there as 
a default value for the install command (Lib/distutils/command/install.py).

So it doesn't seem unreasonable to provide a recommendation on where to put 
shared header files and let installers do their own calculation. If an 
installer wants to install into _another_ environment, it can't rely on 
sysconfig anyway, so we need the spec as well as any implementation. And if we 
don't have the spec then people will have to reverse-engineer the 
implementation anyway, so we may as well start with the spec.

Now, whether we actually need or want packages dumping all their headers in one 
directory is a different question. At least on some platforms they'll also need 
to import libraries too, and tools like Cython have different files yet again. 
Many existing project keep these files inside their package and offer the path 
on request (e.g. pybind11), so perhaps we actually want to standardise 
pkg-config-like metadata instead?

(Also crossposting back to the discuss thread)

----------

_______________________________________
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue44445>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to