The pybind11 documentation is generally good, but one area in which it is not is explaining the install process and the process of getting and running examples using cmake.
I've managed to figure out how to get and build examples. But it leads to more questions. Almost all the examples count on downloading the pybind11 repo into the examples folder and including the root folder of the repo in a cmake run (the root folder contains a cmakelists.txt file). The contents of that repo have a lot in common with the content which is added to a python environment when you install pybind11 using pip or conda. But the folder organization is completely different.
So I'm curious:
- Why the difference?
- Is there a way to use the content in the environment install in such a way that you don't also have to download the repo in order to build examples using cmake?
- Failing that, what is the best way to put the pybind11 repo in a common place so it doesn't have to be copied all over the place in order to build examples, or in order to provide the important added cmake functionality for one's own code?
I'm really uncomfortable in general not understanding the "how this works" aspect of such things, so this will really help me.