--- a/Makefile Tue May 03 17:10:43 2016 +0200
+++ b/Makefile Wed May 04 00:11:15 2016 +0200
@@ -1,18 +1,17 @@
# Makefile for backup2Archiv2
# Author: Heike Yvonne Pesch
+#
+prefix = /usr/local
-INSTALL_PATH=/usr/local/sbin
+INSTALL_PATH= ${DESTDIR}${prefix}/sbin
INSTALL_LIST= backup2Archiv2
-list:
- @echo "USAGE: make [install|clean]"
+.PHONY: all clean distclean install
+
+all distclean clean:
install:
- @test -d $(INSTALL_PATH) || mkdir $(INSTALL_PATH)
- @chmod 2755 $(INSTALL_PATH)
- @chgrp staff $(INSTALL_PATH)
- @umask 003; cp --target-directory=$(INSTALL_PATH) $(INSTALL_LIST)
- @chmod 555 $(INSTALL_PATH)/*
-
-clean:
- @cd $(INSTALL_PATH); rm -f $(INSTALL_LIST)
+ install -m 0755 ${INSTALL_LIST} $(INSTALL_PATH)/
+
+help:
+ @echo "${MAKE} [all|install|clean|distclean]"