On 16 Aug 2002 09:19:14 -0700, Paul Winkler wrote: > On Fri, Aug 16, 2002 at 04:48:17PM +0200, Kasper Souren wrote: > > The Python documentation about extending/embedding seems okay, but they don't > > mention how to compile the .c file to get an .so file. I think it has been > > written for experienced C programmers. > > http://www.python.org/doc/current/ext/building-on-unix.html > > or if you don't want to bother with distutils, > I just found this in an old comp.lang.python post: > > INC="-I/usr/local/src/Python-2.2/Include/ -I/usr/local/src/Python-2.2/" > OPTS="-shared -Xlinker -export-dynamic -fPIC" > gcc $(INC) $(OPTS) -o foomodule.so foomodule.o
you should use swig to generate the bindings. this makes it all very easy.
