191c13f2c2af5da94f3a9542b21098390e8f925f
[swftools.git] / src / Makefile.in
1 top_builddir = ..
2 srcdir = @srcdir@
3 top_srcdir = @top_srcdir@
4 include ../Makefile.common
5
6 programs = wav2swf @PNG2SWF@ swfcombine swfstrings swfextract swfdump swfc @JPEG2SWF@
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 jpeg2swf.o: jpeg2swf.c
25         $(C) jpeg2swf.c -o $@
26 swfc.o: swfc.c parser.h ../lib/q.h
27         $(C) swfc.c -o $@
28 parser.o: parser.yy.c parser.h ../lib/q.h
29         $(C) parser.yy.c -o $@
30
31 # TODO: include the following rule only if lex is available
32 parser.yy.c: parser.lex
33         lex -Bs -oparser.yy.c parser.lex
34
35 wav2swf: wav2swf.o wav.o
36         $(L) wav2swf.o wav.o -o $@ ../lib/librfxswf.a $(LIBS)
37         $(STRIP) wav2swf
38 png2swf: png2swf.o
39         $(L) png2swf.o -o $@ ../lib/librfxswf.a $(LIBS)
40         $(STRIP) png2swf
41 swfcombine: swfcombine.o
42         $(L) swfcombine.o -o $@ ../lib/librfxswf.a $(LIBS)
43         $(STRIP) swfcombine
44 swfdump: swfdump.o
45         $(L) swfdump.o -o $@ ../lib/librfxswf.a $(LIBS)
46         $(STRIP) swfdump
47 swfextract: swfextract.o
48         $(L) swfextract.o -o $@ ../lib/librfxswf.a $(LIBS)
49         $(STRIP) swfextract
50 swfstrings: swfstrings.o
51         $(L) swfstrings.o -o $@ ../lib/librfxswf.a $(LIBS)
52         $(STRIP) swfstrings
53 jpeg2swf: jpeg2swf.o
54         $(L) jpeg2swf.o -o $@ ../lib/librfxswf.a $(LIBS)
55         $(STRIP) jpeg2swf
56 swfc: parser.o swfc.o ../lib/q.o wav.o
57         $(L) parser.o swfc.o ../lib/q.o wav.o -o $@ ../lib/librfxswf.a $(LIBS)
58         $(STRIP) swfc
59
60 install:
61         $(mkinstalldirs) $(bindir)
62         $(mkinstalldirs) $(man1dir)
63         @for file in $(programs); do $(INSTALL_BIN);$(INSTALL_MAN1);done
64         
65 uninstall:
66         @for file in $(programs); do $(UNINSTALL_BIN);$(UNINSTALL_MAN1);done
67
68 clean: 
69         rm -f *.o *.lo *.a *.la wav2swf png2swf swfcombine swfextract swfstrings png2swf jpeg2swf *~
70