-
Notifications
You must be signed in to change notification settings - Fork 19
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
PyPi package doesn't install header files in the header file search path. #24
Comments
Do you know how this should be solved? py3c uses the setuptools' |
I don't. I spent a couple of hours yesterday trying to get to the bottom of it. Here's what I found out:
The only solution I could see was:
It seems like this use case just isn't accommodated with the tools we have today, alas. |
@xoviat, if you have a bit of time, could you sketch how you're using the PyPI package? It seems we're missing something here. |
from sysconfig import get_paths
from wheel.paths import get_install_paths
def get_wheel_header_paths():
return [os.path.dirname(get_install_paths('dummy')['headers'])]
py3c_include_dirs = get_wheel_header_paths() + \
[get_paths()['include']] + \
[get_paths()['platinclude']] |
I think the main problem here is that The
It also installs the OTOH,
The So I think the easiest solution, at least for now, is to teach |
IMO, the best solution is to ignore PyPI and treat |
I'm sorry, but
|
Right, although some see it as a historical mistake. I meant that pip is designed to install to virtualenvs (among other things), so it can't assume a header path or pkgconfig location is available. The packaging formats made for pip/PyPI don't handle *nix system integration well. |
Use case: I maintain a python package which includes an extension module, and which uses the py3c headers, which, up to now, I have bundled with the project. Now that version 1.0 of py3c is available on PyPi, I had hoped that it would be possible to stop bundling the py3c headers and add py3c to the
install_requires
of my packagessetup.py
.Unfortunately, however,
pip install py3c
puts the headers in a place which is not on the header file search path:That's from doing a
pip install py3c
with the virtualenv activated. You can see that this directory is not on the standard compiler search path for header files:The text was updated successfully, but these errors were encountered: