[Geowanking] c++/python binding wisdom

Mateusz Loskot mateusz at loskot.net
Thu May 22 08:42:59 PDT 2008


On May 22, 2008, at 5:18 PM, nino at urbanmapping.com wrote:
> Hopefully, y'all with experience writing or using swig bindings or  
> other c/py framework can weigh in.  Rants, gotchas, resources,  
> whatever great or token wisdom will be sincerely appreciated.

In the subject you use C++/Python but above you use C/Python, both are  
very different cases. If you wrap C++ API, I'd go with Boost Python  
[1]. IMHO, there is nothing better than Boost Python for C++, it beats  
SWIG regarding C++ language support.
I don't have much experience with wrapping C for Python, but some  
users say ctypes may be better than SWIG.

[1] http://www.boost.org/doc/libs/1_35_0/libs/python/doc/index.html
-- 
Mateusz Loskot, http://mateusz.loskot.net
Charter Member of OSGeo, http://osgeo.org







More information about the Geowanking mailing list