install_headers command support
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Buildout |
New
|
Undecided
|
Unassigned |
Bug Description
distutils supports a command install_headers. If any C headers are listed in the 'headers' section in setup.py, these will be installed. The default behavior of distutils is to try to create a new '/usr/include/
I imagine buildout has no support for this. I would therefore like to request such support. :)
We could have a new section in [buildout] that lists all the eggs that need their headers installed. These headers will then be placed in a special 'headers-directory' in buildout (which can also be modified by placing 'headers-directory' in the [buildout] section).
That takes care of header installation. Now as to how to use them. These headers are typically needed during the extension build process. An extension can then access the C headers of an extension during its own build process.
If the system can track which headers were installed by which egg somehow, we could place these headers on the C include path during build. Alternatively and more simply we could simply place the entire headers-directory on the C include path always, though this might lead to versioning issues.
If don't need precise control over versions (the simpler solution) would have a layout of the headers-directory as follows:
headers-
headers-
headers-directory would then be placed on the include path.
If we need precise control of versions we'd instead want something like this:
headers-
headers-
where package_a-1.3 etc are placed on the include path.
I do not know whether any special care about linking needs to be taken - I haven't set things up that far yet. Since everything will be linked together dynamically I think we should be fine as long as python extensions can share headers.