On Monday 06 September 2010 08:15:39 David Aldrich wrote: > I have only looked at the boost.python tutorial that demonstrates a 'Hello > world' Python extension. For our project we would be dealing with > something very much bigger, with many classes, singleton classes and > (possibly) global data. My question is, would it be practical to make all > of those entities Python extensions?
Yes. PyOGRE or cctbx are excellent exmples of larger projects which use boost.python. You may want to use py++ to automate binding generation to save yourself quite some time. > We would also want to continue to support the application as a wholly C++ > application. Currently, we use gnu make to build it. Would I have to > add a parallel build system using bjam to build the extensions? And then > maintain both make's makefiles and bjam's Jamroot files? No. The python modules can be compiled using regular make. My recommendation is to avoid using bjam, even if it is technically superior, as it is not used widely enough to have the critical mass that other tools (autotools, cmake, scons) have which means that finding help is pretty painful (as there seem to be only a couple of people with knowledge sufficient to answer any non-trivial questions). > Can .pyd files be loaded by the C++ linker? These are simply shared libraries (on POSIX). So the linker can read them. Avoid storing the python bindings in the same shared libraries as your core code since the coupling will be hard to undo while gaining nothing. Regards, Ravi _______________________________________________ Cplusplus-sig mailing list Cplusplus-sig@python.org http://mail.python.org/mailman/listinfo/cplusplus-sig