mirror of
https://github.com/pybind/pybind11.git
synced 2024-11-21 20:55:11 +00:00
1be0a0a610
For single-file extensions, a convenient pattern offered by cython is to place the source files directly in the python source tree (`foo/__init__.py`, `foo/ext.pyx`), deriving the package names from their filesystem location. Adapt this pattern for pybind11, using an `intree_extensions` helper, which should be thought of as the moral equivalent to `cythonize`. Differences with cythonize: I chose not to include globbing support (`intree_extensions(glob.glob("**/*.cpp"))` seems sufficient), nor to provide extension-customization kwargs (directly setting the attributes on the resulting Pybind11Extension objects seems sufficient). We could choose to have `intree_extension` (singular instead) and make users write `[*map(intree_extension, glob.glob("**/*.cpp"))]`; no strong opinion here. Co-authored-by: Aaron Gokaslan <skylion.aaron@gmail.com> |
||
---|---|---|
.. | ||
_static | ||
advanced | ||
cmake | ||
basics.rst | ||
benchmark.py | ||
benchmark.rst | ||
changelog.rst | ||
classes.rst | ||
compiling.rst | ||
conf.py | ||
Doxyfile | ||
faq.rst | ||
index.rst | ||
installing.rst | ||
limitations.rst | ||
Makefile | ||
pybind11_vs_boost_python1.png | ||
pybind11_vs_boost_python1.svg | ||
pybind11_vs_boost_python2.png | ||
pybind11_vs_boost_python2.svg | ||
pybind11-logo.png | ||
reference.rst | ||
release.rst | ||
requirements.txt | ||
upgrade.rst |