8683e279cb241477b3b9d54fd69167ff0cbcd857
[platform/upstream/libvorbis.git] / examples / Makefile.in
1 # vorbis makefile configured for use with gcc on any platform
2
3 # $Id: Makefile.in,v 1.13 2000/08/15 11:53:18 xiphmont Exp $
4
5 ###############################################################################
6 #                                                                             #
7 # To build a production vorbis (preferrably using gmake), just type 'make'.   #
8 # To build with debugging or profiling information, use 'make debug' or       #
9 # 'make profile' respectively.  'make clean' is a good idea between builds    #
10 # with different target names, or before a final build.                       #
11 #                                                                             #
12 ###############################################################################
13
14
15 # DO NOT EDIT BELOW! ##########################################################
16 # (unless, of course, you know what you are doing :) ##########################
17
18 @SET_MAKE@
19 FLAGS=-I. -I../include @CFLAGS@ 
20 OPT=@OPT@ $(FLAGS)
21 DEBUG=@DEBUG@ $(FLAGS)
22 PROFILE=@PROFILE@ $(FLAGS)
23 CC=@CC@
24 LD=@CC@
25 LDFLAGS=@LDFLAGS@ $(FLAGS)
26 AR=@AR@
27 RANLIB=@RANLIB@
28 LIBS=@LIBS@
29
30 HFILES =        ../include/vorbis/codec.h ../include/vorbis/vorbisfile.h \
31                 ../include/vorbis/internal.h ../include/vorbis/backends.h \
32                 ../include/vorbis/codebook.h
33 OFILES =        encoder_example.o decoder_example.o chaining_example.o \
34                 vorbisfile_example.o seeking_test.o
35 BINFILES =      encoder_example decoder_example chaining_example \
36                 vorbisfile_example seeking_test
37
38 all:
39         $(MAKE) target CFLAGS="$(OPT)"
40
41 debug:  
42         $(MAKE) target CFLAGS="$(DEBUG)"
43
44 profile: 
45         $(MAKE) target CFLAGS="$(PROFILE)"
46
47 target: $(BINFILES)
48
49 encoder_example.o:      ../include/vorbis/modes.h 
50
51 encoder_example:        $(OFILES) ../lib/libvorbis.a
52         $(CC) $(CFLAGS) $(LDFLAGS) encoder_example.o ../lib/libvorbis.a -o \
53                         encoder_example $(LIBS)
54
55 decoder_example:        $(OFILES) ../lib/libvorbis.a
56         $(CC) $(CFLAGS) $(LDFLAGS) decoder_example.o ../lib/libvorbis.a -o \
57                         decoder_example $(LIBS)
58
59 chaining_example:       $(OFILES) ../lib/libvorbis.a ../lib/vorbisfile.a
60         $(CC) $(CFLAGS) $(LDFLAGS) chaining_example.o \
61                         ../lib/vorbisfile.a ../lib/libvorbis.a \
62                         -o chaining_example $(LIBS)
63 vorbisfile_example:     $(OFILES) ../lib/libvorbis.a ../lib/vorbisfile.a
64         $(CC) $(CFLAGS) $(LDFLAGS) vorbisfile_example.o \
65                         ../lib/vorbisfile.a ../lib/libvorbis.a \
66                         -o vorbisfile_example $(LIBS)
67
68 seeking_test:   $(OFILES) ../lib/libvorbis.a ../lib/vorbisfile.a
69         $(CC) $(CFLAGS) $(LDFLAGS) seeking_test.o \
70                         ../lib/vorbisfile.a ../lib/libvorbis.a \
71                         -o seeking_test $(LIBS)
72
73 selftest:       
74
75 $(OFILES):      $(HFILES)
76
77 .c.o:
78         $(CC) $(CFLAGS) -c $<
79
80 clean:
81         -rm -f *.o *.a test* *~ *.out ogg config.* \
82                 encoder_example decoder_example chaining_example \
83                 vorbisfile_example seeking_test
84
85 distclean:      clean
86         -rm -f Makefile
87