Mercurial > hgbook
annotate en/Makefile @ 149:16f02802f448
Start to produce saner HTML and CSS.
Drop the "beta" targets for now (forever?).
author | Bryan O'Sullivan <bos@serpentine.com> |
---|---|
date | Thu, 08 Mar 2007 22:51:50 -0800 |
parents | 65f6f9d18fa1 |
children | cf24633b8de7 |
rev | line source |
---|---|
18
e6f4088ebe52
Generate a PDF file with a feedback link on each paragraph.
Bryan O'Sullivan <bos@serpentine.com>
parents:
16
diff
changeset
|
1 # This makefile requires GNU make. |
e6f4088ebe52
Generate a PDF file with a feedback link on each paragraph.
Bryan O'Sullivan <bos@serpentine.com>
parents:
16
diff
changeset
|
2 |
69
e9dd634ab99e
hg_id is a one-liner. Pipe to head is superfluous
Guy Brand <gb@isis.u-strasbg.fr>
parents:
59
diff
changeset
|
3 hg_id := $(shell hg parents --template '{node|short}\n') |
18
e6f4088ebe52
Generate a PDF file with a feedback link on each paragraph.
Bryan O'Sullivan <bos@serpentine.com>
parents:
16
diff
changeset
|
4 |
2 | 5 sources := \ |
6 00book.tex \ | |
7 99book.bib \ | |
8 99defs.tex \ | |
34
c0979ed1eabd
Get started on hook chapter.
Bryan O'Sullivan <bos@serpentine.com>
parents:
32
diff
changeset
|
9 build_id.tex \ |
132
e1e2f3e0256a
Start command reference, with the diff command.
Bryan O'Sullivan <bos@serpentine.com>
parents:
131
diff
changeset
|
10 cmdref.tex \ |
59 | 11 concepts.tex \ |
42
cbfa08bcf181
Start the "Mercurial in daily use" chapter.
Bryan O'Sullivan <bos@serpentine.com>
parents:
34
diff
changeset
|
12 daily.tex \ |
133
1e013fbe35f7
Lots of filename related content. A little more command reference
Bryan O'Sullivan <bos@serpentine.com>
parents:
132
diff
changeset
|
13 filenames.tex \ |
34
c0979ed1eabd
Get started on hook chapter.
Bryan O'Sullivan <bos@serpentine.com>
parents:
32
diff
changeset
|
14 hook.tex \ |
16
81454425eee9
Progress on a few fronts, mainly indexing and MQ chapter content
Bryan O'Sullivan <bos@serpentine.com>
parents:
11
diff
changeset
|
15 intro.tex \ |
81454425eee9
Progress on a few fronts, mainly indexing and MQ chapter content
Bryan O'Sullivan <bos@serpentine.com>
parents:
11
diff
changeset
|
16 mq.tex \ |
104
32bf9a5f22c0
Refactor MQ chapter into three.
Bryan O'Sullivan <bos@serpentine.com>
parents:
103
diff
changeset
|
17 mq-collab.tex \ |
32bf9a5f22c0
Refactor MQ chapter into three.
Bryan O'Sullivan <bos@serpentine.com>
parents:
103
diff
changeset
|
18 mq-ref.tex \ |
76
df88df78288d
Add template chapter to build.
Bryan O'Sullivan <bos@serpentine.com>
parents:
69
diff
changeset
|
19 preface.tex \ |
85
b7c69a68b0cc
A little progress on "lightning tour".
Bryan O'Sullivan <bos@serpentine.com>
parents:
84
diff
changeset
|
20 srcinstall.tex \ |
84 | 21 template.tex \ |
95
47ea206351d5
Split tour into two sections.
Bryan O'Sullivan <bos@serpentine.com>
parents:
87
diff
changeset
|
22 tour-basic.tex \ |
121
9094c9fda8ec
Start chapter on error recovery.
Bryan O'Sullivan <bos@serpentine.com>
parents:
118
diff
changeset
|
23 tour-merge.tex \ |
9094c9fda8ec
Start chapter on error recovery.
Bryan O'Sullivan <bos@serpentine.com>
parents:
118
diff
changeset
|
24 undo.tex |
0
76fba5835a1b
Beginnings of a build process and file layout.
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff
changeset
|
25 |
11 | 26 image-sources := \ |
108
e0b961975c5e
First bit of concepts chapter.
Bryan O'Sullivan <bos@serpentine.com>
parents:
104
diff
changeset
|
27 filelog.svg \ |
103 | 28 kdiff3.png \ |
109
1b67dc96f27a
Snapshot of concepts chapter.
Bryan O'Sullivan <bos@serpentine.com>
parents:
108
diff
changeset
|
29 metadata.svg \ |
96
7d7ddc3a57af
Split tour into two chapters.
Bryan O'Sullivan <bos@serpentine.com>
parents:
95
diff
changeset
|
30 mq-stack.svg \ |
149
16f02802f448
Start to produce saner HTML and CSS.
Bryan O'Sullivan <bos@serpentine.com>
parents:
146
diff
changeset
|
31 note.png \ |
112 | 32 revlog.svg \ |
110 | 33 snapshot.svg \ |
99 | 34 tour-history.svg \ |
103 | 35 tour-merge-conflict.svg \ |
36 tour-merge-merge.svg \ | |
100
272146fab009
Add yet another illustration of the merge process.
Bryan O'Sullivan <bos@serpentine.com>
parents:
99
diff
changeset
|
37 tour-merge-pull.svg \ |
113
a0f57b3e677e
More concepts, this time working directory stuff.
Bryan O'Sullivan <bos@serpentine.com>
parents:
112
diff
changeset
|
38 tour-merge-sep-repos.svg \ |
124
c9aad709bd3a
Document the backout command.
Bryan O'Sullivan <bos@serpentine.com>
parents:
122
diff
changeset
|
39 undo-manual.dot \ |
c9aad709bd3a
Document the backout command.
Bryan O'Sullivan <bos@serpentine.com>
parents:
122
diff
changeset
|
40 undo-manual-merge.dot \ |
c9aad709bd3a
Document the backout command.
Bryan O'Sullivan <bos@serpentine.com>
parents:
122
diff
changeset
|
41 undo-non-tip.dot \ |
c9aad709bd3a
Document the backout command.
Bryan O'Sullivan <bos@serpentine.com>
parents:
122
diff
changeset
|
42 undo-simple.dot \ |
113
a0f57b3e677e
More concepts, this time working directory stuff.
Bryan O'Sullivan <bos@serpentine.com>
parents:
112
diff
changeset
|
43 wdir.svg \ |
115
b74102b56df5
Wow! Lots more work detailing the working directory, merging, etc.
Bryan O'Sullivan <bos@serpentine.com>
parents:
113
diff
changeset
|
44 wdir-after-commit.svg \ |
b74102b56df5
Wow! Lots more work detailing the working directory, merging, etc.
Bryan O'Sullivan <bos@serpentine.com>
parents:
113
diff
changeset
|
45 wdir-branch.svg \ |
b74102b56df5
Wow! Lots more work detailing the working directory, merging, etc.
Bryan O'Sullivan <bos@serpentine.com>
parents:
113
diff
changeset
|
46 wdir-merge.svg \ |
b74102b56df5
Wow! Lots more work detailing the working directory, merging, etc.
Bryan O'Sullivan <bos@serpentine.com>
parents:
113
diff
changeset
|
47 wdir-pre-branch.svg |
103 | 48 |
124
c9aad709bd3a
Document the backout command.
Bryan O'Sullivan <bos@serpentine.com>
parents:
122
diff
changeset
|
49 image-dot := $(filter %.dot,$(image-sources)) |
103 | 50 image-svg := $(filter %.svg,$(image-sources)) |
124
c9aad709bd3a
Document the backout command.
Bryan O'Sullivan <bos@serpentine.com>
parents:
122
diff
changeset
|
51 image-png := $(filter %.png,$(image-sources)) |
11 | 52 |
4
33a2e7b9978d
Make it possible to include example input and output from real programs.
Bryan O'Sullivan <bos@serpentine.com>
parents:
2
diff
changeset
|
53 example-sources := \ |
124
c9aad709bd3a
Document the backout command.
Bryan O'Sullivan <bos@serpentine.com>
parents:
122
diff
changeset
|
54 backout \ |
131
153efeaa8f57
Fix stupid build bugs.
Bryan O'Sullivan <bos@serpentine.com>
parents:
124
diff
changeset
|
55 bisect \ |
133
1e013fbe35f7
Lots of filename related content. A little more command reference
Bryan O'Sullivan <bos@serpentine.com>
parents:
132
diff
changeset
|
56 cmdref \ |
117
6b0f4498569e
Beef up daily routine material. Focus on merge-across-copy.
Bryan O'Sullivan <bos@serpentine.com>
parents:
115
diff
changeset
|
57 daily.copy \ |
86 | 58 daily.files \ |
118
1ee53cb37a99
More progress on daily work.
Bryan O'Sullivan <bos@serpentine.com>
parents:
117
diff
changeset
|
59 daily.rename \ |
122
3af28630fe8c
How to goodbye depression by reverting one thousand times daily.
Bryan O'Sullivan <bos@serpentine.com>
parents:
121
diff
changeset
|
60 daily.revert \ |
133
1e013fbe35f7
Lots of filename related content. A little more command reference
Bryan O'Sullivan <bos@serpentine.com>
parents:
132
diff
changeset
|
61 filenames \ |
86 | 62 hook.msglen \ |
63 hook.simple \ | |
64 hook.ws \ | |
104
32bf9a5f22c0
Refactor MQ chapter into three.
Bryan O'Sullivan <bos@serpentine.com>
parents:
103
diff
changeset
|
65 mq.guards \ |
86 | 66 mq.qinit-help \ |
67 mq.dodiff \ | |
68 mq.id \ | |
69 mq.tarball \ | |
70 mq.tools \ | |
71 mq.tutorial \ | |
121
9094c9fda8ec
Start chapter on error recovery.
Bryan O'Sullivan <bos@serpentine.com>
parents:
118
diff
changeset
|
72 rollback \ |
86 | 73 template.simple \ |
87 | 74 template.svnstyle \ |
103 | 75 tour \ |
76 tour-merge-conflict | |
4
33a2e7b9978d
Make it possible to include example input and output from real programs.
Bryan O'Sullivan <bos@serpentine.com>
parents:
2
diff
changeset
|
77 |
0
76fba5835a1b
Beginnings of a build process and file layout.
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff
changeset
|
78 latex-options = \ |
76fba5835a1b
Beginnings of a build process and file layout.
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff
changeset
|
79 -interaction batchmode \ |
76fba5835a1b
Beginnings of a build process and file layout.
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff
changeset
|
80 -output-directory $(dir $(1)) \ |
76fba5835a1b
Beginnings of a build process and file layout.
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff
changeset
|
81 -jobname $(basename $(notdir $(1))) |
76fba5835a1b
Beginnings of a build process and file layout.
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff
changeset
|
82 |
76fba5835a1b
Beginnings of a build process and file layout.
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff
changeset
|
83 all: pdf html |
76fba5835a1b
Beginnings of a build process and file layout.
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff
changeset
|
84 |
76fba5835a1b
Beginnings of a build process and file layout.
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff
changeset
|
85 pdf: pdf/hgbook.pdf |
76fba5835a1b
Beginnings of a build process and file layout.
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff
changeset
|
86 |
18
e6f4088ebe52
Generate a PDF file with a feedback link on each paragraph.
Bryan O'Sullivan <bos@serpentine.com>
parents:
16
diff
changeset
|
87 define pdf |
0
76fba5835a1b
Beginnings of a build process and file layout.
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff
changeset
|
88 mkdir -p $(dir $@) |
21
ce3339dbeb6f
Get beta feedback stuff into better shape.
Bryan O'Sullivan <bos@serpentine.com>
parents:
18
diff
changeset
|
89 TEXINPUTS=$(dir $<): pdflatex $(call latex-options,$@) $< || (rm -f $@; exit 1) |
2 | 90 cp 99book.bib $(dir $@) |
91 cd $(dir $@) && bibtex $(basename $(notdir $@)) | |
16
81454425eee9
Progress on a few fronts, mainly indexing and MQ chapter content
Bryan O'Sullivan <bos@serpentine.com>
parents:
11
diff
changeset
|
92 cd $(dir $@) && makeindex $(basename $(notdir $@)) |
21
ce3339dbeb6f
Get beta feedback stuff into better shape.
Bryan O'Sullivan <bos@serpentine.com>
parents:
18
diff
changeset
|
93 TEXINPUTS=$(dir $<): pdflatex $(call latex-options,$@) $< || (rm -f $@; exit 1) |
ce3339dbeb6f
Get beta feedback stuff into better shape.
Bryan O'Sullivan <bos@serpentine.com>
parents:
18
diff
changeset
|
94 TEXINPUTS=$(dir $<): pdflatex $(call latex-options,$@) $< || (rm -f $@; exit 1) |
26 | 95 if grep 'Reference.*undefined' $(@:.pdf=.log); then exit 1; fi |
18
e6f4088ebe52
Generate a PDF file with a feedback link on each paragraph.
Bryan O'Sullivan <bos@serpentine.com>
parents:
16
diff
changeset
|
96 endef |
e6f4088ebe52
Generate a PDF file with a feedback link on each paragraph.
Bryan O'Sullivan <bos@serpentine.com>
parents:
16
diff
changeset
|
97 |
124
c9aad709bd3a
Document the backout command.
Bryan O'Sullivan <bos@serpentine.com>
parents:
122
diff
changeset
|
98 image-pdf := $(image-dot:%.dot=%.pdf) $(image-svg:%.svg=%.pdf) $(image-png) |
c9aad709bd3a
Document the backout command.
Bryan O'Sullivan <bos@serpentine.com>
parents:
122
diff
changeset
|
99 |
c9aad709bd3a
Document the backout command.
Bryan O'Sullivan <bos@serpentine.com>
parents:
122
diff
changeset
|
100 pdf/hgbook.pdf: $(sources) $(image-pdf) examples |
18
e6f4088ebe52
Generate a PDF file with a feedback link on each paragraph.
Bryan O'Sullivan <bos@serpentine.com>
parents:
16
diff
changeset
|
101 $(call pdf) |
0
76fba5835a1b
Beginnings of a build process and file layout.
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff
changeset
|
102 |
149
16f02802f448
Start to produce saner HTML and CSS.
Bryan O'Sullivan <bos@serpentine.com>
parents:
146
diff
changeset
|
103 html: onepage split |
16f02802f448
Start to produce saner HTML and CSS.
Bryan O'Sullivan <bos@serpentine.com>
parents:
146
diff
changeset
|
104 |
16f02802f448
Start to produce saner HTML and CSS.
Bryan O'Sullivan <bos@serpentine.com>
parents:
146
diff
changeset
|
105 onepage: html/onepage/hgbook.html |
16f02802f448
Start to produce saner HTML and CSS.
Bryan O'Sullivan <bos@serpentine.com>
parents:
146
diff
changeset
|
106 |
16f02802f448
Start to produce saner HTML and CSS.
Bryan O'Sullivan <bos@serpentine.com>
parents:
146
diff
changeset
|
107 split: html/split/hgbook.html |
0
76fba5835a1b
Beginnings of a build process and file layout.
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff
changeset
|
108 |
18
e6f4088ebe52
Generate a PDF file with a feedback link on each paragraph.
Bryan O'Sullivan <bos@serpentine.com>
parents:
16
diff
changeset
|
109 # This is a horrible hack to work around the fact that the htlatex |
e6f4088ebe52
Generate a PDF file with a feedback link on each paragraph.
Bryan O'Sullivan <bos@serpentine.com>
parents:
16
diff
changeset
|
110 # command in tex4ht is itself a horrible hack. I really don't want to |
e6f4088ebe52
Generate a PDF file with a feedback link on each paragraph.
Bryan O'Sullivan <bos@serpentine.com>
parents:
16
diff
changeset
|
111 # include verbatim the big wad of TeX that is repeated in that script, |
e6f4088ebe52
Generate a PDF file with a feedback link on each paragraph.
Bryan O'Sullivan <bos@serpentine.com>
parents:
16
diff
changeset
|
112 # so instead I mangle the script itself. |
e6f4088ebe52
Generate a PDF file with a feedback link on each paragraph.
Bryan O'Sullivan <bos@serpentine.com>
parents:
16
diff
changeset
|
113 |
0
76fba5835a1b
Beginnings of a build process and file layout.
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff
changeset
|
114 define htlatex |
76fba5835a1b
Beginnings of a build process and file layout.
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff
changeset
|
115 mkdir -p $(dir $(1)) |
7
339e75288632
More progress on MQ chapter and general support.
Bryan O'Sullivan <bos@serpentine.com>
parents:
4
diff
changeset
|
116 head -2 $(shell which htlatex) > $(dir $(1))/htlatex.book |
339e75288632
More progress on MQ chapter and general support.
Bryan O'Sullivan <bos@serpentine.com>
parents:
4
diff
changeset
|
117 cp 99book.bib $(dir $@) |
339e75288632
More progress on MQ chapter and general support.
Bryan O'Sullivan <bos@serpentine.com>
parents:
4
diff
changeset
|
118 echo '(cd $(dir $@) && bibtex $(basename $(notdir $@)))' >> $(dir $(1))/htlatex.book |
16
81454425eee9
Progress on a few fronts, mainly indexing and MQ chapter content
Bryan O'Sullivan <bos@serpentine.com>
parents:
11
diff
changeset
|
119 echo '(cd $(dir $@) && makeindex $(basename $(notdir $@)))' >> $(dir $(1))/htlatex.book |
7
339e75288632
More progress on MQ chapter and general support.
Bryan O'Sullivan <bos@serpentine.com>
parents:
4
diff
changeset
|
120 head -3 $(shell which htlatex) >> $(dir $(1))/htlatex.book |
339e75288632
More progress on MQ chapter and general support.
Bryan O'Sullivan <bos@serpentine.com>
parents:
4
diff
changeset
|
121 echo 'echo status $$$$' >> $(dir $(1))/htlatex.book |
0
76fba5835a1b
Beginnings of a build process and file layout.
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff
changeset
|
122 chmod 755 $(dir $(1))/htlatex.book |
149
16f02802f448
Start to produce saner HTML and CSS.
Bryan O'Sullivan <bos@serpentine.com>
parents:
146
diff
changeset
|
123 TEXINPUTS=$(dir $(2)): $(dir $(1))/htlatex.book $(2) "bookhtml,html4-uni,$(3)" " -cunihtf -utf8" "" "$(call latex-options,$(1))" || (rm -f $(1); exit 1) |
0
76fba5835a1b
Beginnings of a build process and file layout.
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff
changeset
|
124 cd $(dir $(1)) && tex4ht -f/$(basename $(notdir $(1))) -cvalidate -cunihtf |
76fba5835a1b
Beginnings of a build process and file layout.
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff
changeset
|
125 cd $(dir $(1)) && t4ht -f/$(basename $(notdir $(1))) |
149
16f02802f448
Start to produce saner HTML and CSS.
Bryan O'Sullivan <bos@serpentine.com>
parents:
146
diff
changeset
|
126 ./fixhtml.py $(dir $(1))/*.html |
0
76fba5835a1b
Beginnings of a build process and file layout.
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff
changeset
|
127 endef |
76fba5835a1b
Beginnings of a build process and file layout.
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff
changeset
|
128 |
124
c9aad709bd3a
Document the backout command.
Bryan O'Sullivan <bos@serpentine.com>
parents:
122
diff
changeset
|
129 image-html := $(image-dot:%.dot=%.png) $(image-svg:%.svg=%.png) $(image-png) |
c9aad709bd3a
Document the backout command.
Bryan O'Sullivan <bos@serpentine.com>
parents:
122
diff
changeset
|
130 |
149
16f02802f448
Start to produce saner HTML and CSS.
Bryan O'Sullivan <bos@serpentine.com>
parents:
146
diff
changeset
|
131 html/onepage/hgbook.html: $(sources) $(image-html) examples hgbook.css bookhtml.cfg |
0
76fba5835a1b
Beginnings of a build process and file layout.
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff
changeset
|
132 $(call htlatex,$@,$<) |
11 | 133 cp $(image-sources:%.svg=%.png) $(dir $@) |
149
16f02802f448
Start to produce saner HTML and CSS.
Bryan O'Sullivan <bos@serpentine.com>
parents:
146
diff
changeset
|
134 cp hgbook.css $(dir $@) |
11 | 135 |
149
16f02802f448
Start to produce saner HTML and CSS.
Bryan O'Sullivan <bos@serpentine.com>
parents:
146
diff
changeset
|
136 html/split/hgbook.html: $(sources) $(image-html) examples hgbook.css bookhtml.cfg |
11 | 137 $(call htlatex,$@,$<,2) |
138 cp $(image-sources:%.svg=%.png) $(dir $@) | |
149
16f02802f448
Start to produce saner HTML and CSS.
Bryan O'Sullivan <bos@serpentine.com>
parents:
146
diff
changeset
|
139 cp hgbook.css $(dir $@) |
18
e6f4088ebe52
Generate a PDF file with a feedback link on each paragraph.
Bryan O'Sullivan <bos@serpentine.com>
parents:
16
diff
changeset
|
140 |
e6f4088ebe52
Generate a PDF file with a feedback link on each paragraph.
Bryan O'Sullivan <bos@serpentine.com>
parents:
16
diff
changeset
|
141 # Produce 90dpi PNGs for the web. |
e6f4088ebe52
Generate a PDF file with a feedback link on each paragraph.
Bryan O'Sullivan <bos@serpentine.com>
parents:
16
diff
changeset
|
142 |
11 | 143 %.png: %.svg |
144 inkscape -D -e $@ $< | |
0
76fba5835a1b
Beginnings of a build process and file layout.
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff
changeset
|
145 |
124
c9aad709bd3a
Document the backout command.
Bryan O'Sullivan <bos@serpentine.com>
parents:
122
diff
changeset
|
146 %.svg: %.dot |
c9aad709bd3a
Document the backout command.
Bryan O'Sullivan <bos@serpentine.com>
parents:
122
diff
changeset
|
147 dot -Tsvg -o $@ $< |
c9aad709bd3a
Document the backout command.
Bryan O'Sullivan <bos@serpentine.com>
parents:
122
diff
changeset
|
148 |
30
cc1e6f1d7161
Use PDF instead of PNG for images in the PDF book
Josef "Jeff" Sipek <jeffpc@josefsipek.net>
parents:
26
diff
changeset
|
149 # Produce eps & pdf for the pdf |
18
e6f4088ebe52
Generate a PDF file with a feedback link on each paragraph.
Bryan O'Sullivan <bos@serpentine.com>
parents:
16
diff
changeset
|
150 |
30
cc1e6f1d7161
Use PDF instead of PNG for images in the PDF book
Josef "Jeff" Sipek <jeffpc@josefsipek.net>
parents:
26
diff
changeset
|
151 %.pdf: %.eps |
cc1e6f1d7161
Use PDF instead of PNG for images in the PDF book
Josef "Jeff" Sipek <jeffpc@josefsipek.net>
parents:
26
diff
changeset
|
152 epstopdf $< |
cc1e6f1d7161
Use PDF instead of PNG for images in the PDF book
Josef "Jeff" Sipek <jeffpc@josefsipek.net>
parents:
26
diff
changeset
|
153 |
cc1e6f1d7161
Use PDF instead of PNG for images in the PDF book
Josef "Jeff" Sipek <jeffpc@josefsipek.net>
parents:
26
diff
changeset
|
154 %.eps: %.svg |
32
b7d46e86a5f1
Stop inkscape from printing an annoying message.
Bryan O'Sullivan <bos@serpentine.com>
parents:
31
diff
changeset
|
155 inkscape -E $@ $< |
11 | 156 |
124
c9aad709bd3a
Document the backout command.
Bryan O'Sullivan <bos@serpentine.com>
parents:
122
diff
changeset
|
157 %.eps: %.dot |
c9aad709bd3a
Document the backout command.
Bryan O'Sullivan <bos@serpentine.com>
parents:
122
diff
changeset
|
158 dot -Tps -o $@ $< |
c9aad709bd3a
Document the backout command.
Bryan O'Sullivan <bos@serpentine.com>
parents:
122
diff
changeset
|
159 |
4
33a2e7b9978d
Make it possible to include example input and output from real programs.
Bryan O'Sullivan <bos@serpentine.com>
parents:
2
diff
changeset
|
160 examples: examples/.run |
33a2e7b9978d
Make it possible to include example input and output from real programs.
Bryan O'Sullivan <bos@serpentine.com>
parents:
2
diff
changeset
|
161 |
86 | 162 examples/.run: $(example-sources:%=examples/%.run) |
45
6b7b0339e7d6
Don't rerun examples unnecessarily.
Bryan O'Sullivan <bos@serpentine.com>
parents:
44
diff
changeset
|
163 touch examples/.run |
6b7b0339e7d6
Don't rerun examples unnecessarily.
Bryan O'Sullivan <bos@serpentine.com>
parents:
44
diff
changeset
|
164 |
6b7b0339e7d6
Don't rerun examples unnecessarily.
Bryan O'Sullivan <bos@serpentine.com>
parents:
44
diff
changeset
|
165 examples/%.run: examples/% examples/run-example |
6b7b0339e7d6
Don't rerun examples unnecessarily.
Bryan O'Sullivan <bos@serpentine.com>
parents:
44
diff
changeset
|
166 cd examples && ./run-example $(notdir $<) |
4
33a2e7b9978d
Make it possible to include example input and output from real programs.
Bryan O'Sullivan <bos@serpentine.com>
parents:
2
diff
changeset
|
167 |
18
e6f4088ebe52
Generate a PDF file with a feedback link on each paragraph.
Bryan O'Sullivan <bos@serpentine.com>
parents:
16
diff
changeset
|
168 build_id.tex: $(wildcard ../.hg/00changelog.[id]) |
29
6e988159394b
Add revision ID to output.
Bryan O'Sullivan <bos@serpentine.com>
parents:
26
diff
changeset
|
169 echo -n $(hg_id) > build_id.tex |
16
81454425eee9
Progress on a few fronts, mainly indexing and MQ chapter content
Bryan O'Sullivan <bos@serpentine.com>
parents:
11
diff
changeset
|
170 |
0
76fba5835a1b
Beginnings of a build process and file layout.
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff
changeset
|
171 clean: |
149
16f02802f448
Start to produce saner HTML and CSS.
Bryan O'Sullivan <bos@serpentine.com>
parents:
146
diff
changeset
|
172 rm -rf html pdf \ |
124
c9aad709bd3a
Document the backout command.
Bryan O'Sullivan <bos@serpentine.com>
parents:
122
diff
changeset
|
173 $(image-dot:%.dot=%.pdf) \ |
c9aad709bd3a
Document the backout command.
Bryan O'Sullivan <bos@serpentine.com>
parents:
122
diff
changeset
|
174 $(image-dot:%.dot=%.png) \ |
103 | 175 $(image-svg:%.svg=%.pdf) \ |
176 $(image-svg:%.svg=%.png) \ | |
146
65f6f9d18fa1
Oops! I forgot that I need the undoctored output files in the book!
Bryan O'Sullivan <bos@serpentine.com>
parents:
133
diff
changeset
|
177 examples/*.{lxo,run} examples/.run build_id.tex |