Get rid of code I neither know nor use anymore.
[mplayer/glamo.git] / mp3lib / Makefile
blob4676e1cf209b48e4d6f288ce90e26993010c3e80
2 include ../config.mak
4 SRCS = sr1.c
5 OBJS = sr1.o
6 # OBJS = $(SRCS:.c,.s=.o)
7 ifeq ($(TARGET_ARCH_SGI_MIPS),yes)
8 OPTFLAGS := $(OPTFLAGS:-O4=-O0)
9 endif
10 CFLAGS = -I.. $(OPTFLAGS)
11 ifeq ($(TARGET_ARCH_X86),yes)
12 SRCS += decode_i586.c
13 OBJS += decode_i586.o
14 ifeq ($(TARGET_MMX),yes)
15 SRCS += decode_MMX.c dct64_MMX.c tabinit_MMX.c
16 OBJS += decode_MMX.o dct64_MMX.o tabinit_MMX.o
17 endif
18 ifeq ($(TARGET_3DNOW),yes)
19 SRCS += dct36_3dnow.c dct64_3dnow.c
20 OBJS += dct36_3dnow.o dct64_3dnow.o
21 endif
22 ifeq ($(TARGET_3DNOWEX),yes)
23 SRCS += dct36_k7.c dct64_k7.c
24 OBJS += dct36_k7.o dct64_k7.o
25 endif
26 ifeq ($(TARGET_SSE),yes)
27 SRCS += dct64_sse.c
28 OBJS += dct64_sse.o
29 endif
30 endif
31 ifeq ($(TARGET_ARCH_POWERPC),yes)
32 ifeq ($(TARGET_ALTIVEC),yes)
33 SRCS += dct64_altivec.c
34 OBJS += dct64_altivec.o
35 ifeq ($(TARGET_OS),Darwin)
36 CFLAGS += -faltivec
37 else
38 CFLAGS += -maltivec -mabi=altivec
39 endif
40 endif
41 endif
43 .SUFFIXES: .c .o
45 # .PHONY: all clean
47 all: libMP3.a
49 .c.o:
50 $(CC) -c $(CFLAGS) -o $@ $<
52 decode_i586.o: decode_i586.c
53 $(CC) -c $(CFLAGS) -fomit-frame-pointer -o $@ $<
55 .s.o:
56 $(CC) -c $(CFLAGS) -o $@ $<
58 libMP3.a: $(OBJS)
59 $(AR) r libMP3.a $(OBJS)
60 $(RANLIB) libMP3.a
62 test1: libMP3.a test.c
63 $(CC) $(CFLAGS) test.c ../libvo/aclib.c -o test1 -I.. ./libMP3.a ../mp_msg-mencoder.o ../cpudetect.o -lm
65 test2: libMP3.a test2.c
66 $(CC) $(CFLAGS) test2.c ../libvo/aclib.c -o test2 -I.. ./libMP3.a ../mp_msg-mencoder.o ../cpudetect.o -lm
68 clean:
69 rm -f *~ *.o *.a test1 test2
71 distclean: clean
72 rm -f .depend
74 dep: depend
76 depend:
77 $(CC) -MM $(CFLAGS) $(SRCS) 1>.depend
80 # include dependency files if they exist
82 ifneq ($(wildcard .depend),)
83 include .depend
84 endif