chiark / gitweb /
strategy: move traversal proofs inline
[topbloke-formulae.git] / Makefile
1
2 SRCS := $(wildcard *.tex)
3
4 default: final.pdf final.ps
5
6 once:           revid.inc
7                 pdflatex -halt-on-error article.tex </dev/null
8
9 GITDIR:=$(addsuffix /, $(shell git rev-parse --git-dir))
10 HEADREF:=$(shell git symbolic-ref HEAD 2>/dev/null)
11 HEADDEPS:=$(addprefix $(GITDIR), HEAD $(HEADREF))
12
13 revid.inc:      .git-revid $(SRCS) Makefile $(HEADDEPS)
14                 ./$< >$@.new
15                 cmp $@.new $@ || mv -f $@.new $@
16
17 final.pdf: $(SRCS) revid.inc
18                 $(MAKE) once
19                 $(MAKE) once
20                 $(MAKE) once
21                 cp article.pdf final.pdf
22
23 %.ps: %.pdf
24                 pdftops $*.pdf $*.ps
25
26 clean:
27         rm -f *.aux *.log *.dvi *.out *.pdf *.ps *~