aboutsummaryrefslogtreecommitdiffstats
path: root/Makefile
blob: 7ac8895778c6e38f7fbc313070d1448d759814e1 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
latexfile = mmbtools
includes = introduction.tex \
		   interfaces.tex \
		   scenarios.tex \
		   appendix.tex

all: $(latexfile).pdf

$(latexfile).pdf : $(latexfile).tex vc.tex $(includes)
	while (pdflatex $(latexfile) ; \
	grep -q "Rerun to get cross" $(latexfile).log ) do true ; \
	done

vc.tex: .git/logs/HEAD
	echo "%%% This file is generated by Makefile." > vc.tex
	echo "%%% Do not edit this file!\n%%%" >> vc.tex
	git log -1 --format="format:\
		\\gdef\\GITAbrHash{%h}\
		\\gdef\\GITAuthorDate{%ad}\
		\\gdef\\GITAuthorName{%an}" >> vc.tex