From: simon Date: Sun, 21 Nov 2004 09:34:12 +0000 (+0000) Subject: Add `make install' target. X-Git-Url: https://git.distorted.org.uk/~mdw/sgt/tweak/commitdiff_plain/2a70072129b9e56f6de9f29eb5b035947337d388 Add `make install' target. git-svn-id: svn://svn.tartarus.org/sgt/tweak@4857 cda61777-01e9-0310-a592-d414129be87e --- diff --git a/Makefile b/Makefile index 2d77c4d..3f35cd5 100644 --- a/Makefile +++ b/Makefile @@ -4,6 +4,10 @@ LINK := gcc LFLAGS := LIBS := +PREFIX=/usr/local +BINDIR=$(PREFIX)/bin +MANDIR=$(PREFIX)/man/man1 + TWEAK := main.o keytab.o actions.o search.o rcfile.o buffer.o btree.o ifeq ($(SLANG),yes) @@ -40,6 +44,12 @@ release: tweak.1 btree.html (cd reltmp; tar chzvf ../tweak-$(VERSION).tar.gz tweak-$(VERSION)) rm -rf reltmp +install: tweak tweak.1 + mkdir -p $(BINDIR) + install tweak $(BINDIR)/tweak + mkdir -p $(MANDIR) + install -m 0644 tweak.1 $(MANDIR)/tweak.1 + clean: rm -f *.o tweak tweak.1 btree.html