blob: 9eee46f8bf3b4f20b33a3ef8fe4690c7d0f30de3 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
|
db2html = db2html.xsl
tests = $(filter-out template.xml,$(wildcard *.xml))
htmls = $(patsubst %.xml,html/%,$(tests))
htmlargs = \
--stringparam db.chunk.max_depth 0 \
--stringparam theme.icons.base_url \
../../../../icons/hicolor/48x48/status/ \
--stringparam theme.icons.watermark.code \
../../../../icons/hicolor/watermarks/watermark-code.png \
--param db.chunk.chunk_top 'false()' \
$(db2html)
test: $(htmls) html/index.html
$(htmls) : html/% : %.xml
@mkdir -p $@
xsltproc \
-o $@/$(patsubst html/%,%.html,$@) \
--param annotate 'false()' \
--stringparam db.chunk.basename $(patsubst html/%,%,$@) \
$(call htmlargs,$@) $<
xsltproc \
-o $@/$(patsubst html/%,%-a.html,$@) \
--param annotate 'true()' \
--stringparam db.chunk.basename $(patsubst html/%,%-a,$@) \
$(call htmlargs,$@) $<
html/index.html:
(echo '<html><body><ul>' && \
for html in $(htmls); do \
base=`basename $$html`; \
echo "<li><a href='$$base/$${base}.html'>$$base</a>"; \
echo "(<a href='$$base/$${base}-a.html'>annotated</a>)</li>"; \
done && echo '</ul></body></html>') > $@
clean:
rm -rf html/*
|