about summary refs log tree commit diff
diff options
context:
space:
mode:
authorBenjamin A. Beasley <code@musicinmybrain.net>2021-10-20 19:10:29 -0400
committerLeah Neukirchen <leah@vuxu.org>2021-10-21 16:17:04 +0200
commitd95eaa1dfde19dcac6f8b0aefbab2f1a9e71cb0d (patch)
tree65e8725345302a6014b51a11eaac4b0592971c16
parent26bb9f4bd68795b2febe8c90c78f88b510110b92 (diff)
downloadnq-d95eaa1dfde19dcac6f8b0aefbab2f1a9e71cb0d.tar.gz
nq-d95eaa1dfde19dcac6f8b0aefbab2f1a9e71cb0d.tar.xz
nq-d95eaa1dfde19dcac6f8b0aefbab2f1a9e71cb0d.zip
Makefile: add and use an INSTALL variable
This is useful to distribution packagers who may wish to set

  INSTALL='install -p'

in order to preserve timestamps from the source tarball.

Closes: #40 [via git-merge-pr]
-rw-r--r--Makefile6
1 files changed, 4 insertions, 2 deletions
diff --git a/Makefile b/Makefile
index eee398b..c24de67 100644
--- a/Makefile
+++ b/Makefile
@@ -7,6 +7,8 @@ PREFIX=/usr/local
 BINDIR=$(PREFIX)/bin
 MANDIR=$(PREFIX)/share/man
 
+INSTALL=install
+
 all: $(ALL)
 
 clean: FRC
@@ -17,7 +19,7 @@ check: FRC all
 
 install: FRC all
 	mkdir -p $(DESTDIR)$(BINDIR) $(DESTDIR)$(MANDIR)/man1
-	install -m0755 $(ALL) $(DESTDIR)$(BINDIR)
-	install -m0644 $(ALL:=.1) $(DESTDIR)$(MANDIR)/man1
+	$(INSTALL) -m0755 $(ALL) $(DESTDIR)$(BINDIR)
+	$(INSTALL) -m0644 $(ALL:=.1) $(DESTDIR)$(MANDIR)/man1
 
 FRC: