diff options
Diffstat (limited to 'Makefile')
-rw-r--r-- | Makefile | 10 |
1 files changed, 10 insertions, 0 deletions
@@ -1,8 +1,13 @@ CFLAGS += -Wall BIN = fifo-cronolog +HELPER = fifo-cronolog-setup SRC = $(BIN).c OBJ = $(patsubst %.c,%.o,$(SRC)) +BINDIR = /usr/sbin/ +SYSTEMD_TARGET = /usr/lib/systemd/system/ +SYSTEMD_UNIT = systemd/fifo-cronolog@.service + all: $(BIN) $(BIN): $(OBJ) @@ -14,4 +19,9 @@ $(BIN): $(OBJ) clean: $(RM) $(BIN) $(OBJ) +install: + mkdir -p $(DESTDIR)$(BINDIR) $(DESTDIR)$(SYSTEMD_TARGET) + install -m0755 -D $(BIN) $(HELPER) $(DESTDIR)$(BINDIR) + install -m0644 -D $(SYSTEMD_UNIT) $(DESTDIR)$(SYSTEMD_TARGET) + # vim: set ts=4 sw=4 tw=80: |