summaryrefslogtreecommitdiffstats
path: root/DOCS/xml/Makefile.inc
diff options
context:
space:
mode:
authorlumag <lumag@b3059339-0415-0410-9bf9-f77b7e298cf2>2003-10-20 09:56:48 +0000
committerlumag <lumag@b3059339-0415-0410-9bf9-f77b7e298cf2>2003-10-20 09:56:48 +0000
commit44d459e63ec4b6488b53819511367891d943cf9b (patch)
tree7ea0c97dece86dd9fe716d6237df979e1b8a359f /DOCS/xml/Makefile.inc
parent1843717d9ce84c9c20056ab57b984212c7c53386 (diff)
downloadmpv-44d459e63ec4b6488b53819511367891d943cf9b.tar.bz2
mpv-44d459e63ec4b6488b53819511367891d943cf9b.tar.xz
Add support for building all-in-one HTML docs. (Files go to DOCS/HTML-single)
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@11189 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'DOCS/xml/Makefile.inc')
-rw-r--r--DOCS/xml/Makefile.inc37
1 files changed, 33 insertions, 4 deletions
diff --git a/DOCS/xml/Makefile.inc b/DOCS/xml/Makefile.inc
index 7ec2f36d5b..c4de7b002f 100644
--- a/DOCS/xml/Makefile.inc
+++ b/DOCS/xml/Makefile.inc
@@ -2,26 +2,55 @@
# Makefile.inc for Makefiles in subdirectories.
#
-# Use customized html.xsl file if it exists...
+# Use customized html.xsl and/or html-chunk.xsl file if they exist...
+# Also add html-common.xsl to depends if it exists.
ifeq (html.xsl,$(wildcard html.xsl))
HTML_XSL := html.xsl
-XSL_DEPS := $(HTML_XSL) ../html.xsl ../html-common.xsl
+ifeq (html-common.xsl,$(wildcard html-common.xsl))
+XSL_DEPS := $(HTML_XSL) html-common.xsl ../html.xsl ../html-common.xsl
+else
+XSL_DEPS := $(HTML_XSL) html-common.xsl ../html.xsl ../html-common.xsl
+endif
else
HTML_XSL := ../html.xsl
XSL_DEPS := $(HTML_XSL) ../html-common.xsl
endif
+ifeq (html-chunk.xsl,$(wildcard html-chunk.xsl))
+HTML_CHUNK_XSL := html-chunk.xsl
+ifeq (html-common.xsl,$(wildcard html-common.xsl))
+CHUNK_XSL_DEPS := $(HTML_CHUNK_XSL) html-common.xsl ../html-chunk.xsl ../html-common.xsl
+else
+CHUNK_XSL_DEPS := $(HTML_CHUNK_XSL) ../html-chunk.xsl ../html-common.xsl
+endif
+else
+HTML_CHUNK_XSL := ../html-chunk.xsl
+CHUNK_XSL_DEPS := $(HTML_CHUNK_XSL) ../html-common.xsl
+endif
+
# Fall back to the default HTML stylesheet if none is specified.
HTML_STYLESHEET ?= ../default.css
# This is the main target...
-$(HTMLDIR)/index.html: documentation.xml $(XSL_DEPS)
+all: html html-chunked
+html: $(HTMLFILE)
+html-chunked: $(HTMLDIR)/index.html
+
+$(HTMLDIR)/index.html: documentation.xml $(CHUNK_XSL_DEPS)
@if test "$(HTMLDIR)" = "" ; then echo "Error: HTMLDIR not set!!!"; echo "Typically this means, that you've run make from subdir of DOCS/xml. Don't do this!" ; false; fi
if test "$(USE_SYMLINKS)" = "yes" ; then for file in ../en/*.xml ; do if ! test -r `basename $$file` ; then ln -s $$file `basename $$file` ; fi ; done ; fi
-rm -f $(HTMLDIR)/*
../xmllint.sh $<
cp $(HTML_STYLESHEET) $(HTMLDIR)/
- ../xsltproc.sh $(HTMLDIR)/ $(HTML_XSL) $<
+ ../xsltproc.sh $(HTMLDIR)/ $(HTML_CHUNK_XSL) $<
+
+$(HTMLFILE): documentation.xml $(XSL_DEPS)
+ @if test "$(HTMLFILE)" = "" ; then echo "Error: HTMLFILE not set!!!"; echo "Typically this means, that you've run make from subdir of DOCS/xml. Don't do this!" ; false; fi
+ if test "$(USE_SYMLINKS)" = "yes" ; then for file in ../en/*.xml ; do if ! test -r `basename $$file` ; then ln -s $$file `basename $$file` ; fi ; done ; fi
+ -rm -f $(HTMLFILE)
+ ../xmllint.sh $<
+ cp -f $(HTML_STYLESHEET) `dirname $(HTMLFILE)`
+ ../xsltproc.sh $(HTMLFILE) $(HTML_XSL) $<
../html.xsl:
cd .. && sh configure