From 1a1993d8458e9133db89997046a3651d411b5988 Mon Sep 17 00:00:00 2001 From: Gwenhael Le Moine Date: Wed, 23 Oct 2024 16:20:09 +0200 Subject: [PATCH] refactor++ --- Makefile | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/Makefile b/Makefile index ee55cca..0946c23 100644 --- a/Makefile +++ b/Makefile @@ -209,12 +209,6 @@ else /sbin/mkdosfs -v -C -S 512 -f 2 -F 16 -r 512 -R 2 -n "$(TARGET)" $@ 65536 endif -dist/$(TARGET).desktop: dist/$(TARGET).desktop.in - perl -p -e "s!TARGET!$(TARGET)!" < dist/$(TARGET).desktop.in >$@ - -dist/$(TARGET).man: dist/$(TARGET).man.in - perl -p -e "s!TARGET_ALLCAPS!$(TARGET_ALLCAPS)!;" -e "s!TARGET!$(TARGET)!" < dist/$(TARGET).man.in >$@ - # Installation INSTALL_PREFIX = /usr/local INSTALL_BINARY_DIR = "$(INSTALL_PREFIX)"/bin @@ -223,6 +217,12 @@ INSTALL_DOC_DIR = "$(INSTALL_PREFIX)"/doc/$(TARGET) INSTALL_MENU_DIR = "$(INSTALL_PREFIX)"/share/applications INSTALL_MAN_DIR = "$(INSTALL_PREFIX)/share/man/man1" +dist/$(TARGET).desktop: dist/$(TARGET).desktop.in + perl -p -e "s!TARGET!$(TARGET)!" < dist/$(TARGET).desktop.in >$@ + +dist/$(TARGET).man: dist/$(TARGET).man.in + perl -p -e "s!TARGET_ALLCAPS!$(TARGET_ALLCAPS)!;" -e "s!TARGET!$(TARGET)!" < dist/$(TARGET).man.in >$@ + install: all dist/$(TARGET).desktop dist/$(TARGET).man install -D -m 755 dist/$(TARGET) "$(DESTDIR)$(INSTALL_BINARY_DIR)/$(TARGET)" mkdir -p "$(DESTDIR)$(INSTALL_DATA_DIR)/"