add makefile and manpage

This commit is contained in:
Ben Harris
2018-09-05 21:20:02 -04:00
parent cdef21ce0d
commit 4c3fe64acd
2 changed files with 55 additions and 0 deletions

22
Makefile Normal file
View File

@@ -0,0 +1,22 @@
PREFIX ?= /usr/local
BINDIR ?= $(PREFIX)/bin
MANDIR ?= $(PREFIX)/share/man
install:
@echo Installing the executable to $(BINDIR)
@mkdir -p $(BINDIR)
@cp -f tilde $(BINDIR)/tilde
@chmod 755 $(BINDIR)/tilde
@echo Installing the manual page to $(MANDIR)/man1
@mkdir -p $(MANDIR)/man1
@cp -f tilde.1 $(MANDIR)/man1/tilde.1
@chmod 644 $(MANDIR)/man1/tilde.1
uninstall:
@echo Removing the executable from $(BINDIR)
@rm -f $(BINDIR)/tilde
@echo Removing the manual page from $(MANDIR)/man1
@rm -f $(BINDIR)/man1/tilde.1
.PHONY: install uninstall