extending python with a C-written dll
Jean Brouwers
mrjean1ATcomcastDOTnet at no.spam.net
Mon Dec 20 15:03:46 EST 2004
First, you might check the calldll module available here
<http://www.nightmare.com/software.html>
Take a look at Pyrex, it may fit your requirements to access C from
Python.
<http://nz.cosc.canterbury.ac.nz/~greg/python/Pyrex/>
If you do not have these already, you may need the Win32 API extension
<http://www.python.org/windows/win32/>
/Jean Brouwers
In article <cq6qi8$hk9$1 at s5.feed.news.oleane.net>, Jean-Baptiste PERIN
<jb_perin at yahoo.fr> wrote:
> Grant Edwards a écrit :
> > On 2004-12-20, Jean-Baptiste PERIN <jb_perin at yahoo.fr> wrote:
> >
> >
> >>I'm trying to make a windows dll reachable from a python script..
> >
> >
> > FWIW, you can call dll's using the ctypes modules without
> > mucking around in C. There may be performance reasons to build
> > a "real" python module, but I haven't run across them yet.
> >
>
> Not really a performance reason .. but mainly because I have a huge code
> produced in C and no time to port it in python ..
> Moreover .. I need the python program to interact with the C code
> ..(perfom calls to dll-defined functions)
>
> I don't know ctypes module .. do you really think it can help ?
> Do you have a link to quickly learn about it ?
>
> The only thing I found is :
> http://www.python.org/workshops/1994-11/BuiltInClasses/BuiltInClasses_5.html
>
>
>
>
>
More information about the Python-list
mailing list