Python/pip: How to do an editable package install with extension modules?
Asked Answered
F

0

7

I am developing a python package with a C++ extension module that interops with the python code via pybind11, and which I am building using CMake (based on this answer).

I have the package installed as editable to aid in development via pip install -e .

I frequently update the C++ extension module, and each time I do so, the only way to get my changes to work has been to completely clean every build file, uninstall, then re-install the package, which mostly defeats the purpose of having an editable install for development purposes.

Is there a way to do an editable install with extension modules such that I can rebuild the module when I make changes to it without cleaning and reinstalling the whole package each time?

Follower answered 26/9, 2022 at 2:48 Comment(0)

© 2022 - 2025 — McMap. All rights reserved.