build/graphviz-filter.conf: add config for svgs
Add a custom graphviz-filter.conf, so asciidoc instructs graphviz to generate svgs. Related: SYS#6380 Change-Id: Iee54012c41f554608b0915d707f7cf64bfbdc418
This commit is contained in:
parent
18ee65de21
commit
7a71db4d0a
|
@ -38,7 +38,14 @@ CLEAN_FILES += $(ASCIIDOC_PDF) $(ASCIIDOC_NAME:%=%.html)
|
|||
UPLOAD_FILES += $(ASCIIDOC_PDF)
|
||||
|
||||
ABS_SRCDIR := $(or $(abs_srcdir),$(shell realpath $(srcdir)))
|
||||
ASCIIDOC_OPTS := -f $(BUILDDIR)/mscgen-filter.conf -f $(BUILDDIR)/diag-filter.conf -f $(BUILDDIR)/docinfo-releaseinfo.conf -a srcdir='$(ABS_SRCDIR)' -a commondir='$(COMMONDIR)'
|
||||
ASCIIDOC_OPTS := \
|
||||
-f $(BUILDDIR)/mscgen-filter.conf \
|
||||
-f $(BUILDDIR)/diag-filter.conf \
|
||||
-f $(BUILDDIR)/docinfo-releaseinfo.conf \
|
||||
-f $(BUILDDIR)/graphviz-filter.conf \
|
||||
-a srcdir='$(ABS_SRCDIR)' \
|
||||
-a commondir='$(COMMONDIR)' \
|
||||
$(NULL)
|
||||
DBLATEX_OPTS := -s $(ASCIIDOCSTYLE) -P draft.mode=yes -P draft.watermark=0
|
||||
|
||||
ifeq (,$(BUILD_RELEASE))
|
||||
|
|
|
@ -0,0 +1,24 @@
|
|||
#
|
||||
# AsciiDoc Graphviz filter configuration file.
|
||||
#
|
||||
|
||||
[graphviz-filter-style]
|
||||
graphviz-style=template="graphviz{format?-{format}}-block",subs=(),posattrs=("style","target","layout","format"),filter='dot -o "{outdir={indir}}/{imagesdir=}{imagesdir?/}{target}" -T {format=svg} && echo " "'
|
||||
|
||||
[blockdef-open]
|
||||
template::[graphviz-filter-style]
|
||||
|
||||
[blockdef-listing]
|
||||
template::[graphviz-filter-style]
|
||||
|
||||
[paradef-default]
|
||||
template::[graphviz-filter-style]
|
||||
|
||||
[graphviz-block]
|
||||
template::[filter-image-svgblockmacro]
|
||||
|
||||
[filter-image-svgblockmacro]
|
||||
{target%}{counter2:target-number}
|
||||
{target%}{set2:target:{docname}__{target-number}.svg}
|
||||
|
|
||||
template::[image-blockmacro]
|
Loading…
Reference in New Issue