aboutsummaryrefslogtreecommitdiff
path: root/Makefile
blob: f186a158f2d5e9c19c348b3a4b7e38545d9bc0dc (plain)
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
CFLAGS:=-Wall -O0 -ggdb

pkgmodules:=glib-2.0 libpulse-mainloop-glib sndfile x11 xi
includes:=$(shell pkg-config --cflags $(pkgmodules))
libs:=$(shell pkg-config --libs $(pkgmodules))
objs:=main.o x11.o audio.o key.o

all: coveraudiod

coveraudiod: $(objs)
	$(CC) -o $@ $+ $(libs)

$(objs): %.o: %.c
	$(CC) -std=c99 $(includes) $(CFLAGS) -o $@ -c $<

clean:
	rm -f *.o coveraudiod

install: coveraudiod
	install coveraudiod $(DESTDIR)/usr/bin
	install -d $(DESTDIR)/usr/share/coveraudiod
	install *.wav $(DESTDIR)/usr/share/coveraudiod/

.PHONY: all clean install