0ab8c4b660db5bcb6c7bd0be2a84cc3325f084cb
[swftools.git] / lib / python / Makefile
1 all: mypython SWF.so
2
3 LIB=-L/usr/lib/python2.2/config/ -lpython2.2
4
5 primitives.o: primitives.c primitives.h
6         gcc -g -O2 -Wall -Wno-unused -fPIC -I/usr/include/python2.2 -c primitives.c -o primitives.o
7 tagmap.o: tagmap.c tagmap.h
8         gcc -g -O2 -Wall -Wno-unused -fPIC -I/usr/include/python2.2 -c tagmap.c -o tagmap.o
9 taglist.o: taglist.c taglist.h tagmap.h
10         gcc -g -O2 -Wall -Wno-unused -fPIC -I/usr/include/python2.2 -c taglist.c -o taglist.o
11 tag.o: tag.c tag.h tagmap.h
12         gcc -g -O2 -Wall -Wno-unused -fPIC -I/usr/include/python2.2 -c tag.c -o tag.o
13 action.o: action.c action.h
14         gcc -g -O2 -Wall -Wno-unused -fPIC -I/usr/include/python2.2 -c action.c -o action.o
15 pyutils.o: pyutils.c pyutils.h
16         gcc -g -O2 -Wall -Wno-unused -fPIC -I/usr/include/python2.2 -c pyutils.c -o pyutils.o
17
18 SWF.o: SWF.c pyutils.h primitives.h
19         gcc -g -O2 -Wall -Wno-unused -fPIC -I/usr/include/python2.2 -c SWF.c -o SWF.o
20
21 SWF.so: SWF.o taglist.o tag.o tagmap.o action.o primitives.o pyutils.o ../librfxswf.a
22         gcc -shared SWF.o tagmap.o taglist.o tag.o action.o primitives.o pyutils.o  -o SWF.so $(LIB) ../librfxswf.a -ljpeg -lz -lt1 -lfreetype
23         cp SWF.so test
24
25 mypython: mypython.c
26         gcc -g -I/usr/include/python2.2 mypython.c -o mypython $(LIB) -ldl -lm -lpthread -lutil
27
28 test: SWF.so
29         cd test;./test_create.py
30         #python fonts.py
31         swfdump -p test/test.swf
32 clean:
33         rm *.o *.so mypython
34
35 .PHONY: test