becc93a883b805abfba93eb5be1193d33a466b6a
[swftools.git] / src / Makefile.in
1 top_builddir = ..
2 srcdir = @srcdir@
3 top_srcdir = @top_srcdir@
4 include ../Makefile.common
5
6 programs = wav2swf$(E) @PNG2SWF@ swfcombine$(E) swfstrings$(E) swfextract$(E) swfdump$(E) swfc$(E) @JPEG2SWF@ swfbbox$(E)
7
8 all: $(programs)
9
10 wav2swf.o: wav2swf.c wav.h
11         $(C) wav2swf.c -o $@
12 wav.o: wav.c wav.h
13         $(C) wav.c -o $@
14 png2swf.o: png2swf.c
15         $(C) png2swf.c -o $@
16 swfcombine.o: swfcombine.c
17         $(C) swfcombine.c -o $@
18 swfdump.o: swfdump.c
19         $(C) swfdump.c -o $@
20 swfextract.o: swfextract.c
21         $(C) swfextract.c -o $@
22 swfstrings.o: swfstrings.c
23         $(C) swfstrings.c -o $@
24 swfbbox.o: swfbbox.c
25         $(C) swfbbox.c -o $@
26 jpeg2swf.o: jpeg2swf.c
27         $(C) jpeg2swf.c -o $@
28 swfc.o: swfc.c parser.h ../lib/q.h
29         $(C) swfc.c -o $@
30 parser.o: parser.yy.c parser.h ../lib/q.h
31         $(C) parser.yy.c -o $@
32
33 # TODO: include the following rule only if lex is available
34 parser.yy.c: parser.lex
35         lex -Bs -oparser.yy.c parser.lex
36
37 wav2swf$(E): wav2swf.o wav.o ../lib/librfxswf.a
38         $(L) wav2swf.o wav.o -o $@ ../lib/librfxswf.a $(LIBS)
39         $(STRIP) $@
40 png2swf$(E): png2swf.o ../lib/librfxswf.a
41         $(L) png2swf.o -o $@ ../lib/librfxswf.a $(LIBS)
42         $(STRIP) $@
43 swfcombine$(E): swfcombine.o ../lib/librfxswf.a
44         $(L) swfcombine.o -o $@ ../lib/librfxswf.a $(LIBS)
45         $(STRIP) $@
46 swfdump$(E): swfdump.o ../lib/librfxswf.a
47         $(L) swfdump.o -o $@ ../lib/librfxswf.a $(LIBS)
48         $(STRIP) $@
49 swfextract$(E): swfextract.o ../lib/librfxswf.a
50         $(L) swfextract.o -o $@ ../lib/librfxswf.a $(LIBS)
51         $(STRIP) $@
52 swfstrings$(E): swfstrings.o ../lib/librfxswf.a
53         $(L) swfstrings.o -o $@ ../lib/librfxswf.a $(LIBS)
54         $(STRIP) $@
55 swfbbox$(E): swfbbox.o ../lib/librfxswf.a
56         $(L) swfbbox.o -o $@ ../lib/librfxswf.a $(LIBS)
57         $(STRIP) $@
58 jpeg2swf$(E): jpeg2swf.o ../lib/librfxswf.a
59         $(L) jpeg2swf.o -o $@ ../lib/librfxswf.a $(LIBS)
60         $(STRIP) $@
61 swfc$(E): parser.o swfc.o ../lib/q.o wav.o ../lib/librfxswf.a
62         $(L) parser.o swfc.o ../lib/q.o wav.o -o $@ ../lib/librfxswf.a $(LIBS)
63         $(STRIP) $@
64
65 install:
66         $(mkinstalldirs) $(bindir)
67         $(mkinstalldirs) $(man1dir)
68         @for file in $(programs); do $(INSTALL_BIN);$(INSTALL_MAN1);done
69         
70 uninstall:
71         @for file in $(programs); do $(UNINSTALL_BIN);$(UNINSTALL_MAN1);done
72
73 clean: 
74         rm -f *.o *.lo *.a *.la *~ gmon.out
75         rm -f swfbbox swfdump wav2swf png2swf swfcombine swfextract swfstrings png2swf jpeg2swf
76         @rm -f swfbbox.exe swfdump.exe wav2swf.exe png2swf.exe swfcombine.exe swfextract.exe swfstrings.exe png2swf.exe jpeg2swf.exe
77         @rm -f swfbbox$(E) swfdump$(E) wav2swf$(E) png2swf$(E) swfcombine$(E) swfextract$(E) swfstrings$(E) png2swf$(E) jpeg2swf$(E)
78