1
|
1
|
|
2 include config.mak
|
|
3
|
|
4 SRCS = sr1.c d_cpu.s decode_i586.s $(OPTIONAL_SRCS)
|
|
5 OBJS = sr1.o d_cpu.o decode_i586.o $(OPTIONAL_OBJS)
|
|
6 CFLAGS = $(OPTFLAGS)
|
|
7
|
|
8 .SUFFIXES: .c .o
|
|
9
|
|
10 # .PHONY: all clean
|
|
11
|
|
12 .c.o:
|
|
13 $(CC) -c $(CFLAGS) -o $@ $<
|
|
14
|
|
15 .s.o:
|
|
16 $(CC) -c $(CFLAGS) -o $@ $<
|
|
17
|
26
|
18 libMP3.a: .depend $(OBJS)
|
1
|
19 $(AR) r libMP3.a $(OBJS)
|
|
20
|
788
|
21 test: libMP3.a test.c
|
|
22 $(CC) $(CFLAGS) test.c -o test -I.. -L. -lMP3
|
|
23
|
1
|
24 all: libMP3.a
|
|
25
|
|
26 clean:
|
|
27 rm -f *~ *.o *.a
|
|
28
|
|
29 distclean:
|
26
|
30 rm -f *~ *.o *.a Makefile.bak .depend
|
|
31
|
|
32 dep: depend
|
|
33 depend: .depend
|
1
|
34
|
26
|
35 .depend: Makefile config.mak ../config.mak ../config.h
|
|
36 makedepend -f- -- $(CFLAGS) -- $(SRCS) 1>.depend 2>/dev/null
|
1
|
37
|
26
|
38 #
|
|
39 # include dependency files if they exist
|
|
40 #
|
|
41 ifneq ($(wildcard .depend),)
|
|
42 include .depend
|
|
43 endif
|