1
0
Fork 0

Add diagram generation with graphviz

* configure.ac (TWOPI, HAS_TWOPI): Add variables.
  Check for towpi.
* doc/.gitignore (diagrams/*.svg): Add output file ignore.
* doc/Makefile.am: Add svg diagram building.
master
Mike Gerwitz 2017-04-07 12:25:01 -04:00
parent 657573ab63
commit 54d2eff8b9
3 changed files with 17 additions and 1 deletions

View File

@ -34,6 +34,11 @@ AC_CHECK_PROGS(NODE, [node nodejs])
test -n "$NODE" || AC_MSG_ERROR([missing Node.js])
# graphviz
AC_ARG_VAR([TWOPI], [Graphviz twopi layout])
AC_CHECK_PROGS(TWOPI, [twopi])
AM_CONDITIONAL(HAS_TWOPI, [test "$TWOPI"])
# only needed for older versions of Node
AC_MSG_CHECKING([node --harmony_destructuring])
AS_IF([node --harmony_destructuring >/dev/null 2>/dev/null],

1
doc/.gitignore vendored
View File

@ -13,6 +13,7 @@
*.pdf
*.dvi
*.html
diagrams/*.svg
# generated by configure/autotools
Makefile

View File

@ -21,4 +21,14 @@
MAKEINFOHTML = $(MAKEINFO) --html --css-include liza.css
info_TEXINFOS = liza.texi
liza_TEXINFOS = design.texi macros.texi config.texi liza.css
liza_TEXINFOS = design.texi macros.texi config.texi liza.css \
diagram/event-graph.svg
diagram/%.svg: diagram/%.dot
if HAS_TWOPI
$(TWOPI) -Tsvg "$<" > "$@"
else
@echo "cannot build $<;" >&2
@echo "install graphviz package and re-configure" >&2
endif