fixed bug 119699 (missing error on shadowed variable) removed dependency
[platform/upstream/libxslt.git] / doc / Makefile.am
1 ## Process this file with automake to produce Makefile.in
2 EXTRA_DIST =                    \
3         libxslt-api.xml         \
4         libexslt-api.xml        \
5         libxslt-decl.txt        \
6         xsltproc.xml            \
7         apibuild.py             \
8         libxslt.xsa             \
9         news.xsl
10
11 # The name of the module.
12 DOC_MODULE=libxslt-$(VERSION)
13
14 # The top-level SGML file.
15 DOC_MAIN_XML_FILE=libxslt.xml
16
17 # The directory containing the source code (if it contains documentation).
18 DOC_SOURCE_DIR=..
19
20 HTML_DIR=$(datadir)/doc
21
22 # A file in win32 depends upon two of the doc files
23 WIN32_DIR=$(top_srcdir)/win32
24
25 TARGET_DIR=$(HTML_DIR)/$(DOC_MODULE)/html
26 PAGES= API.html bugs.html contribs.html docs.html downloads.html \
27        help.html index.html intro.html news.html xsltproc2.html FAQ.html
28 APIPAGES=APIconstructors.html APIfiles.html APIfunctions.html \
29     APIsymbols.html APIchunk0.html
30
31 man_MANS = xsltproc.1
32
33 all : $(PAGES) $(top_srcdir)/NEWS libxslt.xsa $(man_MANS)
34
35 tests:
36
37 web: $(PAGES) $(APIPAGES)
38
39 $(PAGES): $(srcdir)/xslt.html $(srcdir)/site.xsl
40         -@(if [ -x $(bindir)/xsltproc ] ; then \
41           $(bindir)/xsltproc --nonet --html $(srcdir)/site.xsl $(srcdir)/xslt.html > index.html ; fi )
42         -@(if [ -x $(bindir)/xmllint ] ; then \
43           $(bindir)/xmllint --nonet --valid --noout $(PAGES) ; fi );
44
45 $(top_srcdir)/NEWS: $(top_srcdir)/doc/news.xsl $(top_srcdir)/doc/news.html
46         -@(if [ -x $(bindir)/xsltproc ] ; then \
47           $(bindir)/xsltproc --nonet $(top_srcdir)/doc/news.xsl $(top_srcdir)/doc/news.html > $(top_srcdir)/NEWS ; fi );
48
49 libxslt.xsa: $(top_srcdir)/doc/xsa.xsl $(top_srcdir)/doc/news.html
50         -@(if [ -x $(bindir)/xsltproc ] ; then \
51           $(bindir)/xsltproc --nonet $(top_srcdir)/doc/xsa.xsl $(top_srcdir)/doc/news.html > libxslt.xsa ; fi );
52
53 $(APIPAGES): libxslt-refs.xml site.xsl api.xsl
54         -@(if [ -x $(bindir)/xsltproc ] ; then \
55           $(bindir)/xsltproc --nonet --html $(srcdir)/api.xsl $(srcdir)/xslt.html ; fi );
56
57 xsltproc.1: xsltproc.xml
58         -@(xsltproc --nonet xsltproc.xml)
59
60 scan:
61         -gtkdoc-scan --module=libxslt --source-dir=$(DOC_SOURCE_DIR)/libxslt --ignore-headers="acconfig.h config.h win32config.h"
62 #       gtkdoc-scan --module=libexslt --source-dir=$(DOC_SOURCE_DIR)/libexslt --ignore-headers="acconfig.h config.h win32config.h"
63
64 templates: scan
65         -gtkdoc-mktmpl --module=libxslt
66 #       gtkdoc-mktmpl --module=libexslt
67
68 xml:
69         if test -d xml ; then rm xml/* ; else mkdir xml ; fi
70         -gtkdoc-mkdb --module=libxslt --source-dir=$(DOC_SOURCE_DIR)/libxslt --output-format=xml --main-sgml-file=$(DOC_MAIN_XML_FILE)
71
72 html:
73         if ! test -d html ; then mkdir html ; fi
74         -cd html && gtkdoc-mkhtml libxslt ../$(DOC_MAIN_XML_FILE)
75            
76 libxslt-api.xml libexslt-api.xml: apibuild.py ../libxslt/*.h ../libxslt/*.c ../libexslt/*.h ../libexslt/*.c
77         -(./apibuild.py)
78
79 $(WIN32_DIR)/libxslt.def.src: libxslt-api.xml
80         -@(if [ -x $(bindir)/xsltproc ] ; then \
81           $(bindir)/xsltproc -o $(WIN32_DIR)/libxslt.def.src \
82           --nonet $(WIN32_DIR)/defgen.xsl libxslt-api.xml ; fi )
83
84 $(WIN32_DIR)/libexslt.def.src: libexslt-api.xml
85         -@(if [ -x $(bindir)/xsltproc ] ; then \
86           $(bindir)/xsltproc -o $(WIN32_DIR)/libexslt.def.src \
87           --nonet $(WIN32_DIR)/defgen.xsl libexslt-api.xml ; fi )
88
89 api: libxslt-api.xml libxslt-refs.xml $(WIN32_DIR)/libxslt.def.src $(WIN32_DIR)/libexslt.def.src
90
91 clean-local:
92         rm -f *~ *.bak *.hierarchy *.signals *-unused.txt
93
94 maintainer-clean-local: clean
95         rm -rf libxslt-decl-list.txt libxslt-decl.txt 
96
97 libxslt-decl-list.txt : templates
98
99 libxslt-sections.txt : scan
100         cp libxslt-decl-list.txt libxslt-sections.txt
101
102 rebuild: libxslt-sections.txt templates xml html
103
104 install-data-local: 
105         $(mkinstalldirs) $(DESTDIR)$(TARGET_DIR)
106         -@INSTALL@ -m 0644 $(srcdir)/*.html $(DESTDIR)$(TARGET_DIR)
107         -@INSTALL@ -m 0644 $(srcdir)/*.gif $(DESTDIR)$(TARGET_DIR)
108         -@INSTALL@ -m 0644 $(srcdir)/html/*.html $(DESTDIR)$(TARGET_DIR)
109         -@INSTALL@ -m 0644 $(srcdir)/html/index.sgml $(DESTDIR)$(TARGET_DIR)
110         $(mkinstalldirs) $(DESTDIR)$(TARGET_DIR)/tutorial
111         -@INSTALL@ -m 0644 $(srcdir)/tutorial/* $(DESTDIR)$(TARGET_DIR)/tutorial
112         -(cd $(DESTDIR); gtkdoc-fixxref --module=libxslt --html-dir=$(HTML_DIR))
113
114 dist-hook:
115         (cd $(srcdir) ; tar cvf - *.1 *.html site.xsl news.xsl xsa.xsl *.gif html/*.html html/*.png tutorial/libxslt*) | (cd $(distdir); tar xf -)
116
117 .PHONY : html xml templates scan