commit 05796b396e726d7fd3c385e14ac360c29ba944e1 parent c4131503bf120cdc6ce2addeefd1e9a32f9d02ff Author: Santtu Lakkala <inz@inz.fi> Date: Sat, 26 Feb 2022 14:17:13 +0200 Makefile cleanup Diffstat:
M | Makefile | | | 20 | ++++++++++---------- |
1 file changed, 10 insertions(+), 10 deletions(-)
diff --git a/Makefile b/Makefile @@ -1,18 +1,18 @@ .POSIX: -TARGET = tmisu -SRC := src/tmisu.c src/output.c -HDRS := src/tmisu.h src/output.h +TARGET = tmisu +SRC = src/tmisu.c src/output.c +HDRS = src/tmisu.h src/output.h -PREFIX ?= /usr/local +PREFIX ?= /usr/local -CFLAGS += -W -Wall -std=c99 -IFLAGS = $$(pkg-config --cflags dbus-1) -LFLAGS = $$(pkg-config --libs dbus-1) -OBJ := ${SRC:.c=.o} +CFLAGS = -W -Wall -std=c99 +IFLAGS = $$(pkg-config --cflags dbus-1) +LFLAGS = $$(pkg-config --libs dbus-1) +OBJ = ${SRC:.c=.o} all: ${TARGET} -%.o: %.c ${HDRS} +.c.o: ${CC} -c $< ${CFLAGS} ${IFLAGS} -o $@ ${TARGET}: ${OBJ} @@ -20,7 +20,7 @@ ${TARGET}: ${OBJ} install: ${TARGET} mkdir -p ${DESTDIR}${PREFIX}/bin - install ${TARGET} ${DESTDIR}${PREFIX}/bin/${TARGET} + cp -f ${TARGET} ${DESTDIR}${PREFIX}/bin clean: ${RM} -f ${OBJ} ${TARGET}