]> git.wh0rd.org - fontconfig.git/blame_incremental - doc/Makefile.am
Document FcPatternFormat() format
[fontconfig.git] / doc / Makefile.am
... / ...
CommitLineData
1#
2# fontconfig/doc/Makefile.am
3#
4# Copyright © 2003 Keith Packard
5#
6# Permission to use, copy, modify, distribute, and sell this software and its
7# documentation for any purpose is hereby granted without fee, provided that
8# the above copyright notice appear in all copies and that both that
9# copyright notice and this permission notice appear in supporting
10# documentation, and that the name of Keith Packard not be used in
11# advertising or publicity pertaining to distribution of the software without
12# specific, written prior permission. Keith Packard makes no
13# representations about the suitability of this software for any purpose. It
14# is provided "as is" without express or implied warranty.
15#
16# THE AUTHOR(S) DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE,
17# INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO
18# EVENT SHALL THE AUTHOR(S) BE LIABLE FOR ANY SPECIAL, INDIRECT OR
19# CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE,
20# DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
21# TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
22# PERFORMANCE OF THIS SOFTWARE.
23
24CC = @CC_FOR_BUILD@
25EXEEXT = @EXEEXT_FOR_BUILD@
26LINK = $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@
27
28DOC_SRC = $(srcdir)
29DOC_MODULE = fontconfig
30DOC2HTML = docbook2html
31DOC2TXT = docbook2txt
32DOC2MAN = docbook2man
33DOC2PDF = docbook2pdf
34
35TXT = fontconfig-user.txt fontconfig-devel.txt
36PDF = fontconfig-user.pdf fontconfig-devel.pdf
37HTML_FILES = fontconfig-user.html
38HTML_DIR = fontconfig-devel
39SGML = fontconfig-user.sgml fontconfig-devel.sgml
40FNCS_TMPL = ${DOC_SRC}/func.sgml
41
42DOC_FUNCS_FNCS=\
43 fcatomic.fncs \
44 fcblanks.fncs \
45 fccache.fncs \
46 fccharset.fncs \
47 fcconfig.fncs \
48 fcconstant.fncs \
49 fcdircache.fncs \
50 fcfile.fncs \
51 fcfontset.fncs \
52 fcformat.fncs \
53 fcfreetype.fncs \
54 fcinit.fncs \
55 fclangset.fncs \
56 fcmatrix.fncs \
57 fcobjectset.fncs \
58 fcobjecttype.fncs \
59 fcpattern.fncs \
60 fcstring.fncs \
61 fcstrset.fncs \
62 fcvalue.fncs
63
64DOC_FUNCS_SGML=\
65 fcatomic.sgml \
66 fcblanks.sgml \
67 fccache.sgml \
68 fccharset.sgml \
69 fcconfig.sgml \
70 fcconstant.sgml \
71 fcdircache.sgml \
72 fcfile.sgml \
73 fcfontset.sgml \
74 fcformat.sgml \
75 fcfreetype.sgml \
76 fcinit.sgml \
77 fclangset.sgml \
78 fcmatrix.sgml \
79 fcobjectset.sgml \
80 fcobjecttype.sgml \
81 fcpattern.sgml \
82 fcstring.sgml \
83 fcstrset.sgml \
84 fcvalue.sgml
85
86man5_MANS=fonts-conf.5
87man3_MANS=$(DOCMAN3)
88
89noinst_PROGRAMS=edit-sgml
90edit_sgml_SOURCES=edit-sgml.c
91
92docdir=@DOCDIR@
93
94DOC_FILES=$(TXT) $(PDF) $(HTML_FILES)
95LOCAL_DOCS=$(man3_MANS) $(man5_MANS) $(DOC_FILES) $(HTML_DIR)/*
96
97check_SCRIPTS=check-missing-doc
98TESTS_ENVIRONMENT=top_srcdir=${top_srcdir} sh
99TESTS=check-missing-doc
100
101EXTRA_DIST=$(LOCAL_DOCS) $(SGML) $(DOC_FUNCS_FNCS) $(check_SCRIPTS) func.sgml confdir.sgml.in
102
103SUFFIXES=.fncs .sgml .txt .html
104
105if USEDOCBOOK
106
107.fncs.sgml:
108 $(RM) $@
109 ./edit-sgml$(EXEEXT) $(FNCS_TMPL) < '$<' > $*.sgml
110
111.sgml.txt:
112 $(RM) $@
113 $(DOC2TXT) $<
114
115.sgml.pdf:
116 $(RM) $@
117 $(DOC2PDF) $<
118
119$(man3_MANS): func.refs
120
121func.refs: local-fontconfig-devel.sgml $(DOC_FUNCS_SGML) version.sgml confdir.sgml
122 $(RM) func.refs
123 $(DOC2MAN) -o devel-man local-fontconfig-devel.sgml && \
124 mv devel-man/manpage.refs func.refs && \
125 mv devel-man/*.3 . && \
126 $(RM) devel-man/manpage.* && \
127 rmdir devel-man
128
129local-fontconfig-devel.sgml: fontconfig-devel.sgml
130 $(LN_S) $< $@
131
132$(DOC_FUNCS_SGML): edit-sgml$(EXEEXT) $(FNCS_TMPL)
133
134fonts-conf.5: local-fontconfig-user.sgml version.sgml confdir.sgml
135 $(RM) $@
136 $(DOC2MAN) local-fontconfig-user.sgml && \
137 $(RM) manpage.*
138
139local-fontconfig-user.sgml: fontconfig-user.sgml
140 $(LN_S) $< $@
141
142all-local: $(LOCAL_DOCS)
143
144clean-local:
145 $(RM) $(man3_MANS) $(man5_MANS) $(DOC_FILES) $(DOC_FUNCS_SGML) func.refs
146 $(RM) -r $(HTML_DIR)
147
148$(HTML_DIR): local-fontconfig-devel.sgml $(DOC_FUNCS_SGML) version.sgml confdir.sgml
149 $(RM) -r $(HTML_DIR)
150 $(DOC2HTML) -V '%use-id-as-filename%' -o $(HTML_DIR) local-fontconfig-devel.sgml
151
152fontconfig-devel.txt: local-fontconfig-devel.sgml $(DOC_FUNCS_SGML) version.sgml confdir.sgml
153 $(RM) $@
154 $(DOC2TXT) local-fontconfig-devel.sgml
155 mv local-fontconfig-devel.txt $@
156
157fontconfig-devel.pdf: local-fontconfig-devel.sgml $(DOC_FUNCS_SGML) version.sgml confdir.sgml
158 $(RM) $@
159 $(top_srcdir)/missing --run $(DOC2PDF) $< && mv local-$@ $@ \
160 || echo Failed to generate $@ >&2; \
161 (test -f $@ || echo $(DOC2PDF) is required to generate this file >> $@)
162
163fontconfig-user.html: local-fontconfig-user.sgml version.sgml confdir.sgml
164 $(RM) $@ local-$@ $@.tmp
165 $(DOC2HTML) -u local-fontconfig-user.sgml > $@.tmp
166 -test -f local-$@ && mv local-$@ $@
167 -test -f $@ || mv $@.tmp $@
168 -test -f $@.tmp && $(RM) $@.tmp
169
170fontconfig-user.txt: local-fontconfig-user.sgml version.sgml confdir.sgml
171 $(RM) $@
172 $(DOC2TXT) local-fontconfig-user.sgml
173 mv local-fontconfig-user.txt $@
174
175fontconfig-user.pdf: local-fontconfig-user.sgml version.sgml confdir.sgml
176 $(RM) $@
177 $(top_srcdir)/missing --run $(DOC2PDF) $< && mv local-$@ $@ \
178 || echo Failed to generate $@ >&2; \
179 (test -f $@ || echo $(DOC2PDF) is required to generate this file >> $@)
180
181STRIPNL=awk '{ if (NR > 1) printf ("\n"); printf ("%s", $$0); }'
182confdir.sgml: ${DOC_SRC}/confdir.sgml.in
183 sed "s,@CONFDIR\@,${CONFDIR}," < ${DOC_SRC}/confdir.sgml.in | $(STRIPNL) > confdir.sgml
184
185CLEANFILES=confdir.sgml local-fontconfig-user.sgml local-fontconfig-devel.sgml
186
187htmldoc_DATA = $(HTML_DIR)/*
188
189$(HTML_DIR)/*: $(HTML_DIR)
190
191else
192
193htmldoc_DATA = $(srcdir)/$(HTML_DIR)/*
194
195all-local:
196clean-local:
197endif
198
199htmldocdir=$(docdir)/$(HTML_DIR)
200
201doc_DATA = $(DOC_FILES)
202