summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPaul C. Buetow <paul@buetow.org>2014-04-15 21:12:18 +0200
committerPaul C. Buetow <paul@buetow.org>2014-04-15 21:12:18 +0200
commit723ec4880e7bcc1ae47bdb1ed65767ae14aa927c (patch)
tree61f9e3373ab349ff6049ee9a77471daf0cc58188
parent03467546a737c1605e3c51f2f0654cef5c1b4fb3 (diff)
install and uninstall now also handles manpage
-rw-r--r--Makefile6
1 files changed, 4 insertions, 2 deletions
diff --git a/Makefile b/Makefile
index db17930..c8a9cf7 100644
--- a/Makefile
+++ b/Makefile
@@ -12,9 +12,11 @@ install:
cp ./bin/$(NAME) $(DESTDIR)/usr/bin/$(NAME)
cp ./bin/$(NAME) $(DESTDIR)/usr/bin/f
cp $(NAME).conf.sample $(DESTDIR)/usr/share/$(NAME)
+ test -z '$(DESTDIR)' && gzip -c ./docs/$(NAME).1 > /usr/share/man/man1/$(NAME).1.gz
deinstall:
- test ! -z "$(DESTDIR)" && test -f $(DESTDIR)/usr/bin/$(NAME) && rm $(DESTDIR)/usr/bin/$(NAME) || exit 0
- test ! -z "$(DESTDIR)" && test -f $(DESTDIR)/usr/share/$(NAME) && rm -r $(DESTDIR)/usr/share/$(NAME) || exit 0
+ test ! -z '$(DESTDIR)' && test -f $(DESTDIR)/usr/bin/$(NAME) && rm $(DESTDIR)/usr/bin/$(NAME) || exit 0
+ test ! -z '$(DESTDIR)' && test -f $(DESTDIR)/usr/share/$(NAME) && rm -r $(DESTDIR)/usr/share/$(NAME) || exit 0
+ test -z '$(DESTDIR)' && rm /usr/share/man/man1/$(NAME).1.gz
clean:
rm bin/*
# Parses the version out of the Debian changelog