20 lines
476 B
Makefile
20 lines
476 B
Makefile
CC ?= clang
|
|
CFLAGS ?= -O2 -I/usr/include/dbus-1.0 -I/usr/lib/dbus-1.0/include/ -Wall -Wextra -g
|
|
PREFIX ?= /usr/local/bin
|
|
LDFLAGS ?= -ldbus-1 -lmpdclient
|
|
|
|
.PHONY: default
|
|
default: universalmusiccontroller
|
|
|
|
universalmusiccontroller: main.c dbus_client.o mpd_client.o metadata.o
|
|
$(CC) $(CFLAGS) -o $@ $^ ${LDFLAGS}
|
|
|
|
%.o: %.c
|
|
$(CC) $(CFLAGS) -c $^ -o $@
|
|
|
|
install: universalmusiccontroller
|
|
install universalmusiccontroller ${PREFIX}
|
|
|
|
clean:
|
|
rm -Rf *.o universalmusiccontroller
|