]> granicus.if.org Git - linux-pam/blob - doc/mwg/Makefile.am
Relevant BUGIDs:
[linux-pam] / doc / mwg / Makefile.am
1 #
2 # Copyright (c) 2006 Thorsten Kukuk <kukuk@thkukuk.de>
3 #
4
5 CLEANFILES = Linux-PAM_MWG.fo *~
6
7 EXTRA_DIST = $(XMLS)
8
9 XMLS = Linux-PAM_MWG.xml $(shell ls $(srcdir)/pam_*.xml)
10
11 if ENABLE_REGENERATE_MAN
12 MAINTAINERCLEANFILES = Linux-PAM_MWG.txt Linux-PAM_MWG.pdf html/*.html
13
14 all: Linux-PAM_MWG.txt html/Linux-PAM_MWG.html Linux-PAM_MWG.pdf
15
16 Linux-PAM_MWG.pdf: $(XMLS)
17 if ENABLE_GENERATE_PDF
18         $(XMLLINT) --nonet --xinclude --postvalid --noent --noout $<
19         $(XSLTPROC) --stringparam generate.toc "book toc" \
20           --stringparam section.autolabel 1 \
21           --stringparam section.label.includes.component.label 1 \
22           --stringparam toc.max.depth 3 --xinclude --nonet \
23         http://docbook.sourceforge.net/release/xsl/current/fo/docbook.xsl $< > Linux-PAM_MWG.fo
24         $(FO2PDF) Linux-PAM_MWG.fo $(srcdir)/$@
25 else
26         echo "No fo2pdf processor installed, skip PDF generation"
27 endif
28
29 Linux-PAM_MWG.txt: $(XMLS)
30         $(XMLLINT) --nonet --xinclude --postvalid --noent --noout $<
31         $(XSLTPROC) --stringparam generate.toc "book toc" \
32           --stringparam section.autolabel 1 \
33           --stringparam section.label.includes.component.label 1 \
34           --stringparam toc.max.depth 3 --xinclude --nonet \
35           http://docbook.sourceforge.net/release/xsl/current/html/docbook.xsl $< | $(BROWSER) > $(srcdir)/$@
36
37 html/Linux-PAM_MWG.html: $(XMLS)
38         @test -d $(srcdir)/html || mkdir -p $(srcdir)/html
39         $(XMLLINT) --nonet --xinclude --postvalid --noent --noout $<
40         $(XSLTPROC) --stringparam base.dir html/ \
41           --stringparam root.filename Linux-PAM_MWG \
42           --stringparam use.id.as.filename 1 \
43           --stringparam chunk.first.sections 1 \
44           --stringparam section.autolabel 1 \
45           --stringparam section.label.includes.component.label 1 \
46           --stringparam toc.max.depth 3 --xinclude --nonet \
47           http://docbook.sourceforge.net/release/xsl/current/html/chunk.xsl $<
48 endif
49
50 releasedocs: all
51         test -f html/Linux-PAM_MWG.html && \
52             cp -ap html/Linux-PAM_MWG.html html/mwg-*.html \
53                 $(top_builddir)/Linux-PAM-$(VERSION)-docs/html/ || \
54             cp -ap $(srcdir)/html/Linux-PAM_MWG.html \
55                 $(srcdir)/html/mwg-*.html \
56                 $(top_builddir)/Linux-PAM-$(VERSION)-docs/html/
57         test -f Linux-PAM_MWG.txt && \
58             cp -p Linux-PAM_MWG.txt \
59                 $(top_builddir)/Linux-PAM-$(VERSION)-docs/txt/ || \
60             cp -p $(srcdir)/Linux-PAM_MWG.txt \
61                 $(top_builddir)/Linux-PAM-$(VERSION)-docs/txt/
62         test -f Linux-PAM_MWG.pdf && \
63             cp -p Linux-PAM_MWG.pdf \
64                 $(top_builddir)/Linux-PAM-$(VERSION)-docs/pdf/ || \
65             cp -p $(srcdir)/Linux-PAM_MWG.pdf \
66                 $(top_builddir)/Linux-PAM-$(VERSION)-docs/pdf/