blob: 98c4e99fce5d4066934687434da3e16c8090fc4a (
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
40
41
42
43
44
45
46
|
-include ../../Makefile.settings
EXTRAPARANEWLINE = 1
# EXTRAPARANEWLINE = 0
all: user-guide.txt user-guide.html help.txt # user-guide.pdf user-guide.ps user-guide.rtf
%.tex: %.db.xml
xsltproc --stringparam l10n.gentext.default.language "en" --stringparam latex.documentclass.common "" --stringparam latex.babel.language "" --output $@ http://db2latex.sourceforge.net/xsl/docbook.xsl $<
%.txt: %.db.xml
xmlto --skip-validation txt $<
mv $*.db.txt $@
%.html: %.db.xml
xsltproc --output $@ http://docbook.sourceforge.net/release/xsl/current/html/docbook.xsl $<
%.pdf: %.db.xml
xmlto --skip-validation pdf $<
mv $*.db.pdf $@
%.ps: %.db.xml
xmlto --skip-validation ps $<
mv $*.db.ps $@
help.xml: commands.xml
%.db.xml: %.xml docbook.xsl
xsltproc --xinclude --output $@ docbook.xsl $<
help.txt: help.xml help.xsl
xsltproc --stringparam extraparanewline "$(EXTRAPARANEWLINE)" --xinclude help.xsl $< | perl -0077 -pe 's/\n\n%/\n%/s; s/_b_/\002/g;' > $@
clean:
rm -f *.html *.pdf *.ps *.rtf *.txt *.db.xml
install:
mkdir -p $(DESTDIR)$(DATADIR)
chmod 0755 $(DESTDIR)$(DATADIR)
rm -f $(DESTDIR)$(DATADIR)/help.txt # Prevent help function from breaking in running sessions
install -m 0644 help.txt $(DESTDIR)$(DATADIR)/help.txt
uninstall:
rm -f $(DESTDIR)$(DATADIR)/help.txt
-rmdir $(DESTDIR)$(DATADIR)
.PHONY: clean install uninstall
|