Integrating Python into a C++ app

Ben Sizer kylotan at gmail.com
Mon Jan 3 20:13:50 EST 2005


I know the conventional wisdom is to write the whole app in Python and
only extend with C++ where speed is an issue, but I already have a
large C++ app that I'd like to add Python to. Ideally I'd rewrite the
whole app in Python but I don't have time to do that and maintain the
old system at the same time. So my next thought was to perhaps
integrate the two and slowly migrate modules and classes across from
C++ to Python. If it matters, the main reason I'm interested in doing
this is because I appreciate the productivity of Python and would like
to take advantage of that as I add features to the current code, to
reduce bugs and cut development time.

I've read a few good things in this group about Elmer
(http://elmer.sourceforge.net), but I'm not sure how simply that
accommodates calls in the reverse direction (from Python code back into
C++). Are there any other options that would require a minimum of
rewriting of code? Does anybody have any experience of such a project?
-- 
Ben Sizer




More information about the Python-list mailing list