From: Michal Vaner Date: Sat, 4 Oct 2008 12:48:52 +0000 (+0200) Subject: Doc. system: link docs under run directory X-Git-Tag: holmes-import~267 X-Git-Url: http://mj.ucw.cz/gitweb/?a=commitdiff_plain;h=9e297bec45613b4b20d5935ba10709d5dacc625b;p=libucw.git Doc. system: link docs under run directory They are divided into modules, stored in run/doc/modulename. Only ucw module exists now. --- diff --git a/build/Makebottom b/build/Makebottom index 84db650c..bbb62b11 100644 --- a/build/Makebottom +++ b/build/Makebottom @@ -3,7 +3,7 @@ # The run tree -runtree: run/.tree-stamp $(addsuffix /.dir-stamp,$(addprefix $(o)/,$(DIRS))) +runtree: run/.tree-stamp $(addsuffix /.dir-stamp,$(addprefix $(o)/,$(DIRS)) $(addprefix run/$(DOCDIR)/,$(DOC_MODULES))) run/.tree-stamp: $(o)/config.mk $(M)Creating runtree @@ -194,9 +194,13 @@ $(DATAFILES): $(o)/%: $(s)/% # Rules for documentation -$(o)/%.html: $(o)/%.txt $(s)/build/asciidoc.conf $(s)/build/asciidoc-xhtml.conf + +DOCDIR=doc + +$(o)/%.html: $(o)/%.txt $(s)/build/asciidoc.conf $(s)/build/asciidoc-xhtml.conf run/$(DOCDIR)/$(DOC_MODULE)/.dir-stamp $(M)"DOC-HTML $<" $(Q)asciidoc -e -f $(s)/build/asciidoc.conf -f $(s)/build/asciidoc-xhtml.conf -f /etc/asciidoc/asciidoc.conf -f /etc/asciidoc/xhtml11.conf $< + $(Q)$(call symlink,$@,run/$(DOCDIR)/$(DOC_MODULE)) # In reality, we do not depend on the .txt files, but on the corresponding .deflist's. # However, the Makefile language cannot express that doc-extract generates both .txt diff --git a/ucw/doc/Makefile b/ucw/doc/Makefile index d031d8b9..5fdf0375 100644 --- a/ucw/doc/Makefile +++ b/ucw/doc/Makefile @@ -4,9 +4,12 @@ DIRS+=ucw/doc UCW_DOCS=fastbuf index basecode hash docsys conf mempool UCW_INDEX=$(o)/ucw/doc/def_index.html +UCW_DOCS_HTML=$(addprefix $(o)/ucw/doc/,$(addsuffix .html,$(UCW_DOCS))) $(UCW_INDEX): DOC_HEAD=$(s)/ucw/doc/def_index.txt $(UCW_INDEX): DOC_LIST=$(patsubst %,$(o)/ucw/doc/%.deflist,$(UCW_DOCS)) +$(UCW_INDEX) $(UCW_DOCS_HTML): DOC_MODULE=ucw -DOCS+=$(addprefix $(o)/ucw/doc/,$(addsuffix .html,$(UCW_DOCS))) +DOCS+=$(UCW_DOCS_HTML) DOC_INDICES+=$(UCW_INDEX) +DOC_MODULES+=ucw