Debugging Python C Modules
A specific case of debugging shared libraries is Python(/Perl/whatever) C modules.
These modules are linked as shared libraries, and loaded by Python(/Perl/whatever) when we import(/use) them.
To debug such Python modules:
gdb /usr/bin/python <script [script parameters]>
When we get into gdb, we will set (pending) break-points in our C functions, and then 'run'.
When our break-point is hit, we'll be placed into C code, and be able to debug our code.
: i didn't try using gdb on a Python together with a Python debugger - but do try this at home.
Originally written by