commit: 09b3b06ecff704b6b001d6398f506dce9456301f Author: Robin H. Johnson <robbat2 <AT> gentoo <DOT> org> AuthorDate: Tue Mar 12 18:05:24 2024 +0000 Commit: Robin H. Johnson <robbat2 <AT> gentoo <DOT> org> CommitDate: Tue Mar 12 18:05:24 2024 +0000 URL: https://gitweb.gentoo.org/proj/fifo-cronolog.git/commit/?id=09b3b06e
build: cleanup Makefile Signed-off-by: Robin H. Johnson <robbat2 <AT> gentoo.org> Makefile | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/Makefile b/Makefile index cca4e8b..3baecf8 100644 --- a/Makefile +++ b/Makefile @@ -1,14 +1,17 @@ CFLAGS += -Wall +BIN = fifo-cronolog +SRC = $(BIN).c +OBJ = $(patsubst %.c,%.o,$(SRC)) -all: fifo-cronolog +all: $(BIN) -fifo-cronolog: fifo-cronolog.o +$(BIN): $(OBJ) $(CC) $(LDFLAGS) -o $@ $< -fifo-cronolog.o: fifo-cronolog.c +.c.o: $(CC) $(CFLAGS) -c -o $@ $< clean: - $(RM) fifo-cronolog{,.o} + $(RM) $(BIN) $(OBJ) # vim: set ts=4 sw=4 tw=80: