On Friday 16 August 2002 18:19, Paul Winkler wrote:
> http://www.python.org/doc/current/ext/building-on-unix.html

Ok. I should have carefully RTF docs :)

> 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

This seemed easier for me to fiddle with. So I used the modulator.py script to 
make a basic libsndfilemodule.c, downloaded the source, which I only needed 
to ./configure. My Makefile is now something like this:

PYTHON_PATH=*your-python-source-dir*
INC=-I$(PYTHON_PATH)/Include/ -I$(PYTHON_PATH)/
OPTS=-shared -Xlinker -export-dynamic -fPIC
all: libsndfilemodule.c
        ls $(PYTHON_PATH)
        gcc $(INC) $(OPTS) -o libsndfilemodule.so libsndfilemodule.c

(I needed to get rid of the quotes.)
So now I can start hacking in C :)

greetz,
Kasper

Reply via email to