Mercurial > hgbook
comparison en/Makefile @ 766:3b33dd6aba87
Merge with http://hg.serpentine.com/mercurial/book
author | Dongsheng Song <songdongsheng@live.cn> |
---|---|
date | Thu, 02 Apr 2009 09:24:36 +0800 |
parents | 1c13ed2130a7 fbb4340be17a |
children | 019040fbf5f5 88828b784971 |
comparison
equal
deleted
inserted
replaced
765:d8c85d831fb4 | 766:3b33dd6aba87 |
---|---|
108 hg-id = $(shell hg parents --template '{node|short}, dated {date|isodate},\n') | 108 hg-id = $(shell hg parents --template '{node|short}, dated {date|isodate},\n') |
109 | 109 |
110 hg-version = $(shell hg version -q | \ | 110 hg-version = $(shell hg version -q | \ |
111 sed 's,.*(version \(unknown\|[a-f0-9+]*\)),\1,') | 111 sed 's,.*(version \(unknown\|[a-f0-9+]*\)),\1,') |
112 | 112 |
113 all: web | 113 all: web complete.xml |
114 | 114 |
115 ../stylesheets/system-xsl: $(system-xsl-dir) | 115 ../stylesheets/system-xsl: $(system-xsl-dir) |
116 ln -s $< $@ | 116 ln -s $< $@ |
117 | 117 |
118 web: ../stylesheets/system-xsl websup html | 118 web: ../stylesheets/system-xsl websup html |
119 | 119 |
120 html: $(obj-web-read)/index.html | 120 html: $(obj-web-read)/index.html |
121 | 121 |
122 ../web/index-read.html.in: ../web/genindex.py $(xml-src-files) | 122 ../web/index-read.html.in: ../web/genindex.py $(xml-src-files) |
123 $< | 123 cd ../web && ./genindex.py |
124 | 124 |
125 $(obj-web-read)/index.html: ../stylesheets/system-xsl .validated-00book.xml ../web/index-read.html.in | 125 $(obj-web-read)/index.html: ../stylesheets/system-xsl .validated-00book.xml ../web/index-read.html.in |
126 xsltproc $(xsltproc-opts) -o $(obj-web-read)/x ../stylesheets/chunk-stylesheet.xsl 00book.xml | 126 xsltproc $(xsltproc-opts) -o $(obj-web-read)/x ../stylesheets/chunk-stylesheet.xsl 00book.xml |
127 python ../web/texpand.py ../web/index-read.html.in html/read/index.html | 127 python ../web/texpand.py ../web/index-read.html.in html/read/index.html |
128 for i in $(obj-web-read)/*.html; do \ | 128 for i in $(obj-web-read)/*.html; do \ |
132 websup: $(extras-web) $(image-web) | 132 websup: $(extras-web) $(image-web) |
133 mkdir -p $(obj-websup)/figs $(obj-web-read)/figs | 133 mkdir -p $(obj-websup)/figs $(obj-web-read)/figs |
134 cp ../stylesheets/system-xsl/images/*.png $(obj-websup)/figs | 134 cp ../stylesheets/system-xsl/images/*.png $(obj-websup)/figs |
135 cp -f ../web/icons/*.png $(obj-websup)/figs | 135 cp -f ../web/icons/*.png $(obj-websup)/figs |
136 | 136 |
137 complete.xml: .validated-00book.xml | |
138 $(xsltproc) $(xsltproc-opts) -o $@ ../stylesheets/dtd-profile.xsl 00book.xml | |
139 | |
137 all-ids.dat: ../stylesheets/all-ids.xsl $(xml-src-files) | 140 all-ids.dat: ../stylesheets/all-ids.xsl $(xml-src-files) |
138 $(xsltproc) $(xsltproc-opts) -o $@ ../stylesheets/all-ids.xsl 00book.xml | 141 $(xsltproc) $(xsltproc-opts) -o $@ ../stylesheets/all-ids.xsl 00book.xml |
139 | 142 |
140 web: websup | 143 web: websup |
141 | 144 |
142 valid: .validated-00book.xml | 145 valid: .validated-00book.xml |
143 | 146 |
144 .validated-00book.xml: $(xml-src-files) | 147 .validated-00book.xml: $(xml-src-files) examples/.run |
145 $(xmllint) --path '$(dtd-dir):$(xml-path)' $(xmllint-opts) $< | 148 $(xmllint) --path '$(dtd-dir):$(xml-path)' $(xmllint-opts) $< |
146 touch $@ | 149 touch $@ |
147 | 150 |
148 # Produce 90dpi PNGs for the web. | 151 # Produce 90dpi PNGs for the web. |
149 | 152 |
170 dot -Tsvg -o $@ $< | 173 dot -Tsvg -o $@ $< |
171 | 174 |
172 examples: $(example-prereqs) examples/.run | 175 examples: $(example-prereqs) examples/.run |
173 | 176 |
174 examples/.run: $(example-sources) | 177 examples/.run: $(example-sources) |
175 cd examples && ./run-example | 178 cd examples && ./run-example -a |
176 | 179 |
177 examples/%.run: examples/% examples/run-example | 180 examples/%.run: examples/% examples/run-example |
178 | 181 |
179 clean: | 182 clean: |
180 -rm -rf dist html $(image-dot:%.dot=%.pdf) $(image-dot:%.dot=%.png) \ | 183 -rm -rf dist html $(image-dot:%.dot=%.pdf) $(image-dot:%.dot=%.png) \ |