Re: How to browse a C Library with Python

2007-12-07 Thread georg.heiss
On 5 Dez., 21:03, "Rafael Sachetto" <[EMAIL PROTECTED]> wrote: > This could be a solution > > import commands > > callables = commands.getoutput("nm -D /lib/libc.so.6 | egrep ' T ' > ").split("\n") > callables = [c.split()[2] for c in callables] > > print callables > > On Dec 5, 2007 5:26 PM, Rafae

Re: How to browse a C Library with Python

2007-12-05 Thread Rafael Sachetto
This could be a solution import commands callables = commands.getoutput("nm -D /lib/libc.so.6 | egrep ' T ' ").split("\n") callables = [c.split()[2] for c in callables] print callables On Dec 5, 2007 5:26 PM, Rafael Sachetto <[EMAIL PROTECTED]> wrote: > > > with Python it is simple to call dire

Re: How to browse a C Library with Python

2007-12-05 Thread Rafael Sachetto
> > with Python it is simple to call direct functions from c-librarys. > > Is there a way to browse over a library i.e. '/lib/libc.so' with > > python, to see all possible functions in a library? > > You could use the subprocess module to execute 'nm /lib/libc.so' and look > at lines with type T.

Re: How to browse a C Library with Python

2007-12-05 Thread Gabriel Genellina
En Wed, 05 Dec 2007 12:32:31 -0300, georg.heiss <[EMAIL PROTECTED]> escribi�: > with Python it is simple to call direct functions from c-librarys. > Is there a way to browse over a library i.e. '/lib/libc.so' with > python, to see all possible functions in a library? You could use the subproces