diff options
author | Mattias Andrée <maandree@operamail.com> | 2013-01-23 23:19:35 +0100 |
---|---|---|
committer | Mattias Andrée <maandree@operamail.com> | 2013-01-23 23:19:35 +0100 |
commit | 7c207a99982023b34c9884f66c2b500590cef237 (patch) | |
tree | ccac08a041c729dc0aca643e356fd5136397eb1e | |
parent | dist (diff) | |
download | sysrss-7c207a99982023b34c9884f66c2b500590cef237.tar.gz sysrss-7c207a99982023b34c9884f66c2b500590cef237.tar.bz2 sysrss-7c207a99982023b34c9884f66c2b500590cef237.tar.xz |
update make file with support for the upcoming info manual
Signed-off-by: Mattias Andrée <maandree@operamail.com>
-rw-r--r-- | Makefile | 73 |
1 files changed, 67 insertions, 6 deletions
@@ -1,13 +1,74 @@ +# Copyright © 2012, 2013 Mattias Andrée (maandree@member.fsf.org) +# +# Copying and distribution of this file, with or without modification, +# are permitted in any medium without royalty provided the copyright +# notice and this notice are preserved. This file is offered as-is, +# without any warranty. +# +# [GNU All Permissive License] + PREFIX=/usr +BIN=/bin +DATA=/share + +PROGRAM=sysrss +BOOK=$(PROGRAM) +BOOKDIR=./ + + +all: info + + +info: $(BOOK).info.gz +%.info: $(BOOKDIR)%.texinfo + $(MAKEINFO) "$<" +%.info.gz: %.info + gzip -9c < "$<" > "$@" + + +pdf: $(BOOK).pdf +%.pdf: $(BOOKDIR)%.texinfo + texi2pdf "$<" + +pdf.gz: $(BOOK).pdf.gz +%.pdf.gz: %.pdf + gzip -9c < "$<" > "$@" + +pdf.xz: $(BOOK).pdf.xz +%.pdf.xz: %.pdf + xz -e9 < "$<" > "$@" + + +dvi: $(BOOK).dvi +%.dvi: $(BOOKDIR)%.texinfo + $(TEXI2DVI) "$<" + +dvi.gz: $(BOOK).dvi.gz +%.dvi.gz: %.dvi + gzip -9c < "$<" > "$@" + +dvi.xz: $(BOOK).dvi.xz +%.dvi.xz: %.dvi + xz -e9 < "$<" > "$@" + -all: - @: do nothing install: - mkdir -p "$(DESTDIR)$(PREFIX)/bin" - install -m 755 sysrss.py "$(DESTDIR)$(PREFIX)/bin/sysrss" + mkdir -p "$(DESTDIR)$(PREFIX)$(BIN)" + install -m 755 "$(PROGRAM).py" "$(DESTDIR)$(PREFIX)$(BIN)/$(PROGRAM)" + mkdir -p "$(DESTDIR)$(PREFIX)$(DATA)/licenses/$(PROGRAM)" + mkdir -p "$(DESTDIR)$(PREFIX)$(DATA)/info/" + install -m 644 COPYING "$(DESTDIR)$(PREFIX)$(DATA)/licenses/$(PROGRAM)" + install -m 644 LICENSE "$(DESTDIR)$(PREFIX)$(DATA)/licenses/$(PROGRAM)" + install -m 644 "$(BOOK).info.gz" "$(DESTDIR)$(PREFIX)$(DATA)/info" + +uninstall: + unlink "$(DESTDIR)$(PREFIX)$(BIN)/$(PROGRAM)" + rm -r "$(DESTDIR)$(PREFIX)$(DATA)/licenses/$(PROGRAM)" + unlink "$(DESTDIR)$(PREFIX)$(DATA)/info/$(BOOK).info.gz" clean: - @echo nothing to clean + rm -r *.{t2d,aux,cp,cps,fn,ky,log,pg,pgs,toc,tp,vr,vrs,op,ops,bak,info,pdf,ps,dvi,gz} 2>/dev/null || exit 0 + +.PHONY: clean uninstall install -.PHONY: clean |