-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
31 lines (22 loc) · 1.04 KB
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
LFLAGS=-l pthread -l wiringPiDev -l wiringPi -l mpdclient -lasound -lm
INCLUDE=include
CFLAGS=-g
all: objects/main.o objects/input.o objects/lcd.o objects/mpd.o objects/ctrl.o objects/alsa.o objects/menu.o
gcc ${LFLAGS} objects/*.o -o raspi-mpd
objects/main.o: src/main.c include/logging.h
gcc -c ${CFLAGS} -I ${INCLUDE} src/main.c -o objects/main.o
objects/input.o: src/input.c include/logging.h
gcc -c ${CFLAGS} -I ${INCLUDE} src/input.c -o objects/input.o
objects/lcd.o: src/lcd.c include/logging.h
gcc -c ${CFLAGS} -I ${INCLUDE} src/lcd.c -o objects/lcd.o
objects/mpd.o: src/mpd.c include/logging.h
gcc -c ${CFLAGS} -I ${INCLUDE} src/mpd.c -o objects/mpd.o
objects/ctrl.o: src/ctrl.c include/logging.h
gcc -c ${CFLAGS} -I ${INCLUDE} src/ctrl.c -o objects/ctrl.o
objects/alsa.o: src/alsa.c include/logging.h
gcc -c ${CFLAGS} -I ${INCLUDE} src/alsa.c -o objects/alsa.o
objects/menu.o: src/menu.c include/logging.h
gcc -c ${CFLAGS} -I ${INCLUDE} src/menu.c -o objects/menu.o
clean:
rm -f objects/* 2> /dev/null
[ -e raspi-mpd ] && rm raspi-mpd