chiark / gitweb /
wip
[talk-2019-ghm-rust.git] / Makefile
1
2 SLIDES+= intro
3 SLIDES+= mm0
4 SLIDES+= mm
5 SLIDES+= borrow-mut
6 SLIDES+= dangling
7 SLIDES+= borrow-nonmut
8
9 SLIDES+= bck-lifetimes
10 SLIDES+= macros
11
12 SLIDEFILES=$(addsuffix .ps, $(SLIDES))
13
14 o= >$@.new && mv -f $@.new $@
15
16 all:    slides.pdf talk.ps
17
18 %.ps:   %.fig
19         iconv <$< >$@.1 -f UTF-8 -t ISO-8859-1
20         # wtf!
21         LC_CTYPE=en_GB fig2dev -L ps -l dummy -z A4  <$@.1 $o
22
23 mm0.ps: mm.fig
24         iconv <$< >$@.1 -f UTF-8 -t ISO-8859-1
25         LC_CTYPE=en_GB fig2dev -L ps -l dummy -z A4 -D-60 <$@.1 $o
26
27 bck-lifetimes.ps: bck-err.txt.eps
28 macros.ps: serde-example.txt.eps macro-rules-example.txt.eps
29 borrow-mut.ps: borrow-mut-example.txt.eps
30 dangling.ps: dangling.txt.eps dangling-err.txt.eps
31 borrow-nonmut.ps: borrow-nonmut.txt.eps borrow-nonmut-error.txt.eps
32
33 %.eps:   %.fig
34         iconv <$< >$@.1 -f UTF-8 -t ISO-8859-1
35         # wtf!
36         LC_CTYPE=en_GB fig2dev -L eps <$@.1 $o
37
38 %.txt.eps: %.txt ./txt2ps
39         ./txt2ps <$< |ps2eps -s a3 $o
40
41 %.ps:   %.lout
42         lout $< $o
43
44 slides.ps: $(SLIDEFILES) Makefile
45         cat $(SLIDEFILES) $o
46
47 %.pdf:     %.ps Makefile
48         ps2pdf $< $@
49
50 talk.ps: %.ps: %.txt Makefile
51         a2ps -1 -o $@.1.tmp -B $<
52         pstops <$@.1.tmp >$@ '0@0.94(7mm,7.5mm)'
53
54 usb=/media/usb1
55
56 for-printing: talk.pdf
57         mount $(usb)
58         cp $^ $(usb)/.
59         umount $(usb)