How to use my dynamic link libraries in python??

Diez B. Roggisch deets at nospam.web.de
Fri Apr 11 03:50:51 EDT 2008


郭勇军 schrieb:
> Hello:
>           My OS is Linux, I  compile my dynamic link libraries , and
> want to call the function of my dynamic library through python!
>           How can I realize the function? Please give me some advices! Thanks

If the module has a plain C-interface, consider using ctypes to wrap it. 
It comes with python2.5, see the docs.

If it is C++, I suggest using SIP, a very good C++-wrapper-generator. 
There are other options as well, SWIG and Boost-Python, which I can't 
comment though.

Diez



More information about the Python-list mailing list