changeset 27296:a316bc1ea84d

Only build the documentation in the languages requested from configure. Fixes Bugzilla #978. inspired by a patch from Jonas Berlin, bugs outerspace.dyndns org
author diego
date Sat, 19 Jul 2008 02:00:56 +0000
parents 04655a6c01d4
children d41a06f831ee
files DOCS/xml/Makefile configure
diffstat 2 files changed, 13 insertions(+), 11 deletions(-) [+]
line wrap: on
line diff
--- a/DOCS/xml/Makefile	Fri Jul 18 16:04:31 2008 +0000
+++ b/DOCS/xml/Makefile	Sat Jul 19 02:00:56 2008 +0000
@@ -1,7 +1,6 @@
 # Makefile for generating the HTML documentation
 
-# List of subdirectories to be processed.
-SUBDIRS = en es fr hu it pl cs de ru zh_CN
+include ../../config.mak
 
 # Generated chunked HTML files go here.
 HTML_CHUNKED = ../HTML
@@ -14,10 +13,10 @@
 help:
 	@echo "Targets:"
 	@echo "********"
-	@echo "all               : Build everything (default)."
-	@echo "html-single       : Build HTML documentation (single file)."
+	@echo "all               : Build everything for configured languages (default)."
+	@echo "html-single       : HTML documentation for configured languages (single file)"
 	@echo "html-single-LANG  : As above, but only one language."
-	@echo "html-chunked      : Build HTML documentation (multiple files)."
+	@echo "html-chunked      : HTML documentation for configured languages (multiple files)"
 	@echo "html-chunked-LANG : As above, but only one language."
 	@echo "xmllint           : Check syntax of all xml files."
 	@echo "xmllint-LANG      : Check syntax of LANG xml files."
@@ -29,17 +28,17 @@
 	@echo "clean-LANG        : Remove HTML files for one language."
 	@echo "releaseclean-LANG : Remove generated files for one language."
 	@echo "distclean-LANG    : Remove ALL generated files for one language."
-	@echo "Substitute LANG for one of $(SUBDIRS)"
+	@echo "Substitute LANG for one of $(DOC_LANG_ALL)"
 
-html-chunked: xsltproc.sh xmllint.sh chunked-dir $(addprefix html-chunked-,$(SUBDIRS))
+html-chunked: xsltproc.sh xmllint.sh chunked-dir $(addprefix html-chunked-,$(DOC_LANGS))
 chunked-dir:
 	-mkdir -p $(HTML_CHUNKED)
 
-html-single: xsltproc.sh xmllint.sh single-dir $(addprefix html-single-,$(SUBDIRS))
+html-single: xsltproc.sh xmllint.sh single-dir $(addprefix html-single-,$(DOC_LANGS))
 single-dir:
 	-mkdir -p $(HTML_SINGLE)
 
-xmllint: xmllint.sh $(addprefix xmllint-,$(SUBDIRS))
+xmllint: xmllint.sh $(addprefix xmllint-,$(DOC_LANG_ALL))
 
 clean-html-chunked:
 	-rm -rf $(HTML_CHUNKED)
@@ -47,7 +46,7 @@
 clean-html-single:
 	-rm -rf $(HTML_SINGLE)
 
-releaseclean: $(addprefix releaseclean-,$(SUBDIRS))
+releaseclean: $(addprefix releaseclean-,$(DOC_LANG_ALL))
 	-rm -f html-chunk.xsl html-single.xsl xsltproc.sh xmllint.sh
 
 distclean: clean releaseclean
@@ -78,7 +77,7 @@
 	$(MAKE) HTMLDIR=../$(HTML_CHUNKED)/$(1) -C $(1) distclean
 endef
 
-$(foreach lang, $(SUBDIRS),$(eval $(call lang-def,$(lang))))
+$(foreach lang, $(DOC_LANG_ALL),$(eval $(call lang-def,$(lang))))
 
 .PHONY: all help html-chunked* chunked-dir html-single* single-dir xmllint*
 .PHONY: clean-html-chunked clean-html-single releaseclean* distclean* clean*
--- a/configure	Fri Jul 18 16:04:31 2008 +0000
+++ b/configure	Sat Jul 19 02:00:56 2008 +0000
@@ -7623,6 +7623,9 @@
 # Ensure that locale settings do not interfere with shell commands.
 export LC_ALL = C
 
+DOC_LANG = $doc_lang
+DOC_LANGS = $doc_langs
+DOC_LANG_ALL = $doc_lang_all
 MAN_LANG = $man_lang
 MAN_LANGS = $man_langs
 MAN_LANG_ALL = $man_lang_all