diff --git a/doc/Makefile.am b/doc/Makefile.am index e4b60a6..08c0b45 100644 --- a/doc/Makefile.am +++ b/doc/Makefile.am @@ -303,6 +303,7 @@ source_file_deps = \ $(wildcard $(top_srcdir)/*.c) libxml2-api.xml libxml2-refs.xml ../libxml2.syms: apibuild.py symbols.xml syms.xsl checkapisym.xsl $(source_file_deps) + test -f $(top_srcdir)/include/libxml/xmlversion.h (cd $(srcdir) && ./apibuild.py) ($(XSLTPROC) $(srcdir)/checkapisym.xsl $(srcdir)/libxml2-api.xml) ($(XSLTPROC) -o ../libxml2.syms $(srcdir)/syms.xsl $(srcdir)/symbols.xml) @@ -346,4 +347,4 @@ install-data-local: -$(INSTALL) -m 0644 $(srcdir)/tutorial/images/callouts/*.* \ $(DESTDIR)$(HTML_DIR)/tutorial/images/callouts -.PHONY : html xml templates scan +.PHONY: docs api web wiki rebuild diff --git a/doc/devhelp/Makefile.am b/doc/devhelp/Makefile.am index c904311..dad7975 100644 --- a/doc/devhelp/Makefile.am +++ b/doc/devhelp/Makefile.am @@ -68,7 +68,12 @@ EXTRA_FORMAT= \ EXTRA_DIST = devhelp.xsl html.xsl +if REBUILD_DOCS +rebuild: libxml2.devhelp $(HTML_FILES) +.PHONY: rebuild + libxml2.devhelp $(HTML_FILES): devhelp.xsl html.xsl $(top_srcdir)/doc/libxml2-api.xml -@(if [ -x $(XSLTPROC) ] ; then \ echo Rebuilding devhelp files ; \ $(XSLTPROC) --nonet -o $(srcdir)/libxml2.devhelp $(srcdir)/devhelp.xsl $(top_srcdir)/doc/libxml2-api.xml ; fi ); +endif diff --git a/doc/examples/index.py b/doc/examples/index.py index 7b13d83..25903c3 100755 --- a/doc/examples/index.py +++ b/doc/examples/index.py @@ -13,7 +13,7 @@ sys.path.insert(0, "..") from apibuild import CParser, escape examples = [] -extras = ['examples.xsl', 'index.py'] +extras = ['examples.xsl', 'index.html', 'index.py'] tests = [] sections = {} symbols = {} @@ -231,7 +231,9 @@ LDADD = $(RDL_LIBS) $(STATIC_BINARIES) $(top_builddir)/libxml2.la $(THREAD_LIBS) CLEANFILES = *.tmp +if REBUILD_DOCS rebuild: examples.xml index.html +.PHONY: rebuild examples.xml: index.py $(noinst_PROGRAMS:=.c) cd $(srcdir) && $(PYTHON) index.py @@ -240,6 +242,7 @@ examples.xml: index.py $(noinst_PROGRAMS:=.c) index.html: examples.xml examples.xsl cd $(srcdir) && xsltproc examples.xsl examples.xml && echo "Rebuilt web page" -cd $(srcdir) && xmllint --valid --noout index.html +endif install-data-local: $(MKDIR_P) $(DESTDIR)$(HTML_DIR)