annotate Makefile @ 152:372a9a836e86

cfgparser fix
author szabii
date Mon, 19 Mar 2001 02:29:37 +0000
parents 2f3e01a1fd87
children 34e9f41cce6d
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
1
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
1 # LINUX Makefile made by A'rpi / Astral
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
2 # Some cleanup by LGB: * 'make -C dir' instead of 'cd dir;make;cd..'
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
3 # * for loops instead of linear sequence of make directories
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
4 # * some minor problems with make clean and distclean were corrected
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
5
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
6 include config.mak
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
7
78
8b89201970f6 cp -> install
szabii
parents: 28
diff changeset
8 #install...
8b89201970f6 cp -> install
szabii
parents: 28
diff changeset
9 OWNER = root
8b89201970f6 cp -> install
szabii
parents: 28
diff changeset
10 GROUP = root
8b89201970f6 cp -> install
szabii
parents: 28
diff changeset
11 PERM = 755
8b89201970f6 cp -> install
szabii
parents: 28
diff changeset
12
1
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
13 PRG = mplayer
118
7c67c52142ed added mplayerHQ
arpi_esp
parents: 78
diff changeset
14 PRG_HQ = mplayerHQ
1
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
15 PRG_AVIP = aviparse
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
16 PRG_TV = tvision
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
17 prefix = /usr/local
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
18 BINDIR = ${prefix}/bin
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
19 # BINDIR = /usr/local/bin
150
2f3e01a1fd87 cfgparse fixes
szabii
parents: 149
diff changeset
20 SRCS = linux/getch2.c linux/timer-lx.c linux/shmem.c xa/xa_gsm.c lirc_mp.c cfgparser.c\
2f3e01a1fd87 cfgparse fixes
szabii
parents: 149
diff changeset
21 cfg-mplayer-func.c
2f3e01a1fd87 cfgparse fixes
szabii
parents: 149
diff changeset
22 OBJS = linux/getch2.o linux/timer-lx.o linux/shmem.o xa/xa_gsm.o lirc_mp.o cfgparser.o\
2f3e01a1fd87 cfgparse fixes
szabii
parents: 149
diff changeset
23 cfg-mplayer-func.o
1
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
24 CFLAGS = $(OPTFLAGS) -Iloader -Ilibvo # -Wall
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
25 A_LIBS = -Lmp3lib -lMP3 -Llibac3 -lac3
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
26 VO_LIBS = -Llibvo -lvo $(X_LIBS)
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
27
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
28 .SUFFIXES: .c .o
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
29
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
30 # .PHONY: all clean
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
31
118
7c67c52142ed added mplayerHQ
arpi_esp
parents: 78
diff changeset
32 all: $(PRG) $(PRG_HQ)
1
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
33 # $(PRG_AVIP)
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
34
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
35 .c.o:
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
36 $(CC) -c $(CFLAGS) -o $@ $<
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
37
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
38 COMMONLIBS = libvo/libvo.a libac3/libac3.a mp3lib/libMP3.a
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
39
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
40 loader/libloader.a:
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
41 $(MAKE) -C loader
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
42
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
43 libmpeg2/libmpeg2.a:
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
44 $(MAKE) -C libmpeg2
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
45
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
46 libvo/libvo.a:
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
47 $(MAKE) -C libvo
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
48
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
49 libac3/libac3.a:
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
50 $(MAKE) -C libac3
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
51
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
52 mp3lib/libMP3.a:
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
53 $(MAKE) -C mp3lib
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
54
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
55 opendivx/libdecore.a:
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
56 $(MAKE) -C opendivx
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
57
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
58 encore/libencore.a:
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
59 $(MAKE) -C encore
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
60
28
4d38b16372ae New dependency system
arpi_esp
parents: 22
diff changeset
61 $(PRG): .depend mplayer.o $(OBJS) loader/libloader.a libmpeg2/libmpeg2.a opendivx/libdecore.a $(COMMONLIBS) encore/libencore.a
1
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
62 $(CC) $(CFLAGS) -o $(PRG) mplayer.o $(OBJS) $(XMM_LIBS) $(LIRC_LIBS) $(A_LIBS) -lm $(TERMCAP_LIB) -Lloader -lloader -ldl -Llibmpeg2 -lmpeg2 -Lopendivx -ldecore $(VO_LIBS) -Lencore -lencore -lpthread
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
63
118
7c67c52142ed added mplayerHQ
arpi_esp
parents: 78
diff changeset
64 $(PRG_HQ): .depend mplayerHQ.o $(OBJS) loader/libloader.a libmpeg2/libmpeg2.a opendivx/libdecore.a $(COMMONLIBS) encore/libencore.a
7c67c52142ed added mplayerHQ
arpi_esp
parents: 78
diff changeset
65 $(CC) $(CFLAGS) -o $(PRG_HQ) mplayerHQ.o $(OBJS) $(XMM_LIBS) $(LIRC_LIBS) $(A_LIBS) -lm $(TERMCAP_LIB) -Lloader -lloader -ldl -Llibmpeg2 -lmpeg2 -Lopendivx -ldecore $(VO_LIBS) -Lencore -lencore -lpthread
7c67c52142ed added mplayerHQ
arpi_esp
parents: 78
diff changeset
66
28
4d38b16372ae New dependency system
arpi_esp
parents: 22
diff changeset
67 $(PRG_AVIP): .depend aviparse.o $(OBJS) loader/libloader.a $(COMMONLIBS)
1
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
68 $(CC) $(CFLAGS) -o $(PRG_AVIP) aviparse.o $(OBJS) $(A_LIBS) -lm $(TERMCAP_LIB) -Lloader -lloader -ldl $(VO_LIBS) -lpthread
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
69
28
4d38b16372ae New dependency system
arpi_esp
parents: 22
diff changeset
70 $(PRG_TV): .depend tvision.o $(OBJS) $(COMMONLIBS)
1
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
71 $(CC) $(CFLAGS) -o $(PRG_TV) tvision.o $(OBJS) -lm $(TERMCAP_LIB) $(VO_LIBS)
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
72
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
73 install: $(PRG)
78
8b89201970f6 cp -> install
szabii
parents: 28
diff changeset
74 install -g $(GROUP) -o $(OWNER) -m $(PERM) -s $(PRG) $(BINDIR)
22
4babbd564f1c added install patch by Dariusz Pietrzak
arpi_esp
parents: 1
diff changeset
75 install -D -m 644 DOCS/mplayer.1 $(prefix)/man/man1/mplayer.1
1
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
76
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
77 clean:
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
78 rm -f *.o *~ $(OBJS)
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
79
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
80 distclean:
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
81 @for a in mp3lib libac3 libmpeg2 opendivx encore libvo loader drivers drivers/syncfb ; do $(MAKE) -C $$a distclean ; done
118
7c67c52142ed added mplayerHQ
arpi_esp
parents: 78
diff changeset
82 rm -f *~ $(PRG) $(PRG_HQ) $(PRG_AVIP) $(PRG_TV) $(OBJS) *.o *.a .depend
1
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
83
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
84 dep: depend
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
85
28
4d38b16372ae New dependency system
arpi_esp
parents: 22
diff changeset
86 depend: .depend
1
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
87 @for a in mp3lib libac3 libmpeg2 libvo opendivx encore ; do $(MAKE) -C $$a dep ; done
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
88
28
4d38b16372ae New dependency system
arpi_esp
parents: 22
diff changeset
89 .depend: Makefile config.mak config.h
118
7c67c52142ed added mplayerHQ
arpi_esp
parents: 78
diff changeset
90 makedepend -f- -- $(CFLAGS) -- mplayer.c mplayerHQ.c aviparse.c tvision.c $(SRCS) 1>.depend 2>/dev/null
22
4babbd564f1c added install patch by Dariusz Pietrzak
arpi_esp
parents: 1
diff changeset
91
28
4d38b16372ae New dependency system
arpi_esp
parents: 22
diff changeset
92 #
4d38b16372ae New dependency system
arpi_esp
parents: 22
diff changeset
93 # include dependency files if they exist
4d38b16372ae New dependency system
arpi_esp
parents: 22
diff changeset
94 #
4d38b16372ae New dependency system
arpi_esp
parents: 22
diff changeset
95 ifneq ($(wildcard .depend),)
4d38b16372ae New dependency system
arpi_esp
parents: 22
diff changeset
96 include .depend
4d38b16372ae New dependency system
arpi_esp
parents: 22
diff changeset
97 endif