hc
2024-11-01 2f529f9b558ca1c1bd74be7437a84e4711743404
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
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
HTML_DOCS =                     \
   html/MIGRATION                \
   html/README.APPLICATIONS        \
   html/README.INSTALL            \
   html/TROUBLESHOOTING.COBALT        \
   html/TROUBLESHOOTING.MERCURY        \
   html/asciidoc-icons            \
   html/asciidoc-icons/callouts        \
   html/man1/autotune            \
   html/man1/chkkconf            \
   html/man1/clocktest            \
   html/man1/corectl            \
   html/man1/dohell            \
   html/man1/latency            \
   html/man1/rtcanconfig            \
   html/man1/rtcanrecv            \
   html/man1/rtcansend            \
   html/man1/slackspot            \
   html/man1/switchtest            \
   html/man1/xeno                \
   html/man1/xeno-config            \
   html/man1/xeno-test
 
PDF_DOCS =                 \
   MIGRATION.pdf            \
   README.APPLICATIONS.pdf     \
   README.INSTALL.pdf         \
   TROUBLESHOOTING.COBALT.pdf    \
   TROUBLESHOOTING.MERCURY.pdf
 
TXT_DOCS =                \
   MIGRATION.txt            \
   README.APPLICATIONS.txt     \
   README.INSTALL.txt        \
   TROUBLESHOOTING.COBALT.txt    \
   TROUBLESHOOTING.MERCURY.txt
 
MAN1_DOCS =             \
   man1/autotune.1        \
   man1/chkkconf.1     \
   man1/clocktest.1     \
   man1/corectl.1         \
   man1/cyclictest.1     \
   man1/dohell.1        \
   man1/latency.1         \
   man1/rtcanconfig.1     \
   man1/rtcanrecv.1     \
   man1/rtcansend.1     \
   man1/slackspot.1    \
   man1/switchtest.1     \
   man1/xeno-config.1     \
   man1/xeno-test.1     \
   man1/xeno.1
 
EXTRA_DIST :=                \
   MIGRATION.adoc             \
   README.APPLICATIONS.adoc    \
   README.INSTALL.adoc         \
   TROUBLESHOOTING.COBALT.adoc    \
   TROUBLESHOOTING.MERCURY.adoc     \
   plaintext.conf             \
   plaintext.xsl            \
   plaintext_postproc.awk        \
   $(MAN1_DOCS:%.1=%.adoc)
 
if XENO_BUILD_DOC
 
HTML_DOCSDIR = ./
PDF_DOCSDIR = ./
MAN_DOCSDIR = ./
 
ASCIIDOC_HTML_OPTS=-a icons -a iconsdir=../asciidoc-icons \
   -a toc -a toclevels=3 -a max-width=55em -a xenover=$(PACKAGE_VERSION)
 
ASCIIDOC_PDF_OPTS=-a icons -a toc -a toclevels=3 -a xenover=$(PACKAGE_VERSION)
 
ASCIIDOC_MAN_OPTS=-a xenover=$(PACKAGE_VERSION)
 
ASCIIDOC_TXT_OPTS=-a xenover=$(PACKAGE_VERSION) -a encoding=ascii
 
tmpdir=adoc_plaintext
 
all-local: $(HTML_DOCS) $(PDF_DOCS) $(TXT_DOCS) $(MAN1_DOCS)
 
html/%: %.adoc Makefile
   @$(mkdir_p) $@
   $(ASCIIDOC) -n -b xhtml11 $(ASCIIDOC_HTML_OPTS) -o $@/index.html $<
 
%.1: %.adoc Makefile
   @$(mkdir_p) man1
   $(A2X) -f manpage -D man1 $(ASCIIDOC_MAN_OPTS) $<
 
%.pdf: %.adoc Makefile
   $(A2X) -f pdf -D . $(ASCIIDOC_PDF_OPTS) $<
 
$(tmpdir)/%.txt: %.adoc Makefile plaintext.conf plaintext.xsl
   @$(mkdir_p) $(tmpdir)
   $(ASCIIDOC) --backend docbook -f $(srcdir)/plaintext.conf \
       --doctype article $(ASCIIDOC_TXT_OPTS) \
       --out-file $(tmpdir)/$*.xml $<
   xsltproc --stringparam toc.section.depth 3 --nonet \
       --output $(tmpdir)/$*.html $(srcdir)/plaintext.xsl \
       $(tmpdir)/$*.xml
   w3m -cols 80 -dump -T text/html -no-graph $(tmpdir)/$*.html > $@
 
%.txt: $(tmpdir)/%.txt Makefile plaintext_postproc.awk
   awk -f $(srcdir)/plaintext_postproc.awk $(tmpdir)/$*.txt > $@
 
html/asciidoc-icons:
   $(RM) -R asciidoc-icons
   @if test -d /usr/share/doc/asciidoc/images/; then \
       cp -a /usr/share/doc/asciidoc/images/icons/ html/asciidoc-icons; \
   elif test -d /usr/share/asciidoc/images/icons/; then \
       cp -a /usr/share/asciidoc/images/icons/ html/asciidoc-icons; \
   else \
       cp -a /etc/asciidoc/images/icons/ html/asciidoc-icons; \
   fi
 
html/asciidoc-icons/callouts: html/asciidoc-icons
 
.PHONY: html/asciidoc-icons
 
include $(top_srcdir)/doc/install.rules
 
install-data-local: install-docs-local
uninstall-local: uninstall-docs
 
else
install-data-local:
uninstall-local:
endif
 
distclean-local: clean-local
 
clean-local:
   $(RM) -R $(HTML_DOCS) $(PDF_DOCS) $(TXT_DOCS) $(tmpdir)