Improve the node-doc-building logic.

This commit is contained in:
Graydon Hoare 2012-01-17 14:46:42 -08:00
parent b4fc99e09e
commit af4e18d980
2 changed files with 10 additions and 14 deletions

5
configure vendored
View File

@ -291,6 +291,11 @@ probe CFG_PANDOC pandoc
probe CFG_PDFLATEX pdflatex
probe CFG_NODE node
if [ -z "$CFG_NODE" ]
then
probe CFG_NODE nodejs
fi
if [ -z "$CFG_ENABLE_CLANG" -a -z "$CFG_GCC" ]
then
err "either clang or gcc is required"

View File

@ -44,20 +44,11 @@ endif
ifdef CFG_NODE
doc/tutorial/web/index.html: doc/tutorial/args.md \
doc/tutorial/control.md \
doc/tutorial/data.md \
doc/tutorial/ffi.md \
doc/tutorial/func.md \
doc/tutorial/generic.md \
doc/tutorial/iface.md \
doc/tutorial/index.md \
doc/tutorial/intro.md \
doc/tutorial/mod.md \
doc/tutorial/setup.md \
doc/tutorial/syntax.md \
doc/tutorial/task.md \
doc/tutorial/test.md
doc/tutorial/web/index.html: \
$(wildcard $(S)doc/tutorial/*.md)
@$(call E, cp: $@)
$(Q)cp -arv $(S)doc/tutorial doc/
@$(call E, node: build.js)
$(Q)cd doc/tutorial && $(CFG_NODE) build.js
endif