ccf252c4a8d41b18f5e5e0d6877bc0ce5483486b
[swftools.git] / lib / gfxpoly / Makefile
1 all: test speedtest stroke
2 include ../../Makefile.common
3
4 CC = gcc -DDEBUG -DCHECKS -O2 -g -pg
5 CCO = gcc -O2 -fno-inline -g -pg
6
7 ../libbase.a: ../q.c ../q.h ../mem.c ../mem.h
8         cd ..; make libbase.a
9
10 ../libgfx.a: ../gfxtools.h ../gfxtools.c ../gfxpoly.h ../gfxpoly.c
11         cd ..; make libgfx.a
12
13 testheap: ../libbase.a testheap.c
14         $(CC) testheap.c ../libbase.a -o testheap -lm -lz -ljpeg
15
16 SRC = active.c convert.c poly.c wind.c renderpoly.c xrow.c stroke.c
17 OBJS = active.o convert.o poly.o wind.o renderpoly.o xrow.o stroke.o
18
19 active.o: active.c active.h poly.h Makefile
20         $(CC) -c active.c -o active.o
21
22 convert.o: convert.c convert.h poly.h Makefile
23         $(CC) -c convert.c -o convert.o
24
25 poly.o: poly.c poly.h active.h heap.h ../q.h Makefile
26         $(CC) -c poly.c -o poly.o
27
28 wind.o: wind.c wind.h poly.h Makefile
29         $(CC) -c wind.c -o wind.o
30
31 renderpoly.o: renderpoly.c wind.h poly.h renderpoly.h Makefile
32         $(CC) -c renderpoly.c -o renderpoly.o
33
34 xrow.o: xrow.c xrow.h ../q.h ../mem.h Makefile
35         $(CC) -c xrow.c -o xrow.o
36
37 stroke.o: stroke.c poly.h convert.h wind.h Makefile
38         $(CC) -c stroke.c -o stroke.o
39
40 GFX=../gfxfont.o ../gfxtools.o ../gfximage.o  ../devices/ops.o ../devices/polyops.o ../devices/text.o ../devices/bbox.o ../devices/render.o ../devices/rescale.o ../devices/record.o
41 stroke: test_stroke.c $(OBJS) ../libgfxswf.a ../librfxswf.a ../libbase.a 
42         $(CC) test_stroke.c $(OBJS) ../libgfxswf.a ../librfxswf.a $(GFX) ../libbase.a -o stroke $(LIBS)
43
44 SWF = ../librfxswf.a ../libgfxpdf.a -lstdc++
45 test: ../libbase.a test.c $(OBJS) poly.h convert.h $(GFX)  Makefile
46         $(CC) test.c $(OBJS) $(SWF) $(GFX) ../libbase.a -o test $(LIBS)
47
48 speedtest: ../libbase.a speedtest.c $(SRC) poly.h convert.h $(GFX) 
49         $(CCO) speedtest.c $(SRC) $(GFX) ../libbase.a -o speedtest $(LIBS)
50
51 clean: 
52         rm -f *.o test stroke