Repository : ssh://git@open-mesh.org/doc
On branches: batman-adv-doc,master
commit 45f0a62b0a8c99ddfabf77c3b0792770aeab5971 Author: Sven Eckelmann sven.eckelmann@gmx.de Date: Fri Jan 23 02:03:31 2009 +0100
Process XML DocBook with xsl stylesheets
docbook2(html|pdf) are designed for SGML DocBook and use parser which are only capable of processing sgml files. Many new versions of these tools also stop with an error when they start to process these files.
xmlto helps us to execute a XSLT processor with correct paths set to the xsl stylesheets for docbook. It needs extra tools like fop to generate more complex output files like pdf or ps, but fop doesn't support eps or pdf as when generating pdf files. It is possible to use ps output and conversation to pdf as workaround.
45f0a62b0a8c99ddfabf77c3b0792770aeab5971 Makefile | 15 ++++++++++----- batman_iv.docbook | 38 +++++++++++++++++++------------------- images/Makefile | 19 ++++++++----------- 3 files changed, 37 insertions(+), 35 deletions(-)
diff --git a/Makefile b/Makefile index b8cac436..e15d8082 100644 --- a/Makefile +++ b/Makefile @@ -2,14 +2,19 @@ default: all all: batman_doc .PHONY: clean images batman_doc: Makefile *.docbook images - docbook2html batman.docbook - docbook2pdf batman.docbook + xmlto html batman.docbook + xmlto fo batman.docbook + fop batman.fo -ps batman.ps + ps2pdf batman.ps + batman_iv_only_doc: Makefile *.docbook images - docbook2html batman_iv_only.docbook - docbook2pdf batman_iv_only.docbook + xmlto html batman_iv_only.docbook + xmlto fo batman_iv_only.docbook + fop batman_iv_only.fo -ps batman_iv_only.ps + ps2pdf batman_iv_only.ps
images: make -C images/ clean: - rm -f *.html *.pdf *.log *.refs + rm -f *.html *.pdf *.fo *.ps make -C images clean diff --git a/batman_iv.docbook b/batman_iv.docbook index b76981a2..d965df4b 100644 --- a/batman_iv.docbook +++ b/batman_iv.docbook @@ -89,7 +89,7 @@ TODO Explain multiple interfaces, which interface sends which OGM by which TTL, <para> Example: OGMs from Node A propagate to B. The link is asymetric, therefore B receives all packets from A in contrast to A which receives almost nothing from B. As all the packets from A get to B the packet count at B's side goes up. B will assume that it has a perfect link towards A which is not the case. <inlinemediaobject> - <imageobject> <imagedata fileref="images/asymetry.pdf" format="EPS" scale="50"/> </imageobject> + <imageobject> <imagedata fileref="images/asymetry.eps" format="EPS" scale="50"/> </imageobject> <imageobject> <imagedata fileref="images/asymetry.png" format="PNG" /> </imageobject> <textobject> <phrase>asymetry illustration</phrase> </textobject> </inlinemediaobject> @@ -165,7 +165,7 @@ TODO Explain multiple interfaces, which interface sends which OGM by which TTL, </para> <para> <inlinemediaobject> - <imageobject> <imagedata fileref="images/rq.pdf" format="EPS" scale="50" /> </imageobject> + <imageobject> <imagedata fileref="images/rq.eps" format="EPS" scale="50" /> </imageobject> <imageobject> <imagedata fileref="images/rq.png" format="PNG" /> </imageobject> <textobject> <phrase>Receive Quality (RQ)</phrase> </textobject> </inlinemediaobject> @@ -177,7 +177,7 @@ TODO Explain multiple interfaces, which interface sends which OGM by which TTL, </para> <para> <inlinemediaobject> - <imageobject> <imagedata fileref="images/eq_alt1.pdf" format="EPS" scale="50" /> </imageobject> + <imageobject> <imagedata fileref="images/eq_alt1.eps" format="EPS" scale="50" /> </imageobject> <imageobject> <imagedata fileref="images/eq_alt1.png" format="PNG" /> </imageobject> <textobject> <phrase>Echo Link Quality (EQ)</phrase> </textobject> </inlinemediaobject> @@ -189,14 +189,14 @@ TODO Explain multiple interfaces, which interface sends which OGM by which TTL, </para> <para> <inlinemediaobject> - <imageobject> <imagedata fileref="images/tq.pdf" format="EPS" scale="50" /> </imageobject> + <imageobject> <imagedata fileref="images/tq.eps" format="EPS" scale="50" /> </imageobject> <imageobject> <imagedata fileref="images/tq.png" format="PNG" /> </imageobject> <textobject> <phrase>Transmit Link Quality (TQ)</phrase> </textobject> </inlinemediaobject> </para> <para> <inlinemediaobject> - <imageobject> <imagedata fileref="images/compute_tq.pdf" format="EPS"/> </imageobject> + <imageobject> <imagedata fileref="images/compute_tq.eps" format="EPS"/> </imageobject> <imageobject> <imagedata fileref="images/compute_tq.png" format="PNG" /> </imageobject> <textobject> <phrase>compute the Transmit Link Quality</phrase> </textobject> </inlinemediaobject> @@ -219,7 +219,7 @@ TODO Explain multiple interfaces, which interface sends which OGM by which TTL, </para> <para> <inlinemediaobject> - <imageobject> <imagedata fileref="images/tq_prop_calc.pdf" format="EPS" /> </imageobject> + <imageobject> <imagedata fileref="images/tq_prop_calc.eps" format="EPS" /> </imageobject> <imageobject> <imagedata fileref="images/tq_prop_calc.png" format="PNG" /> </imageobject> <textobject> <phrase>TQ calcuation</phrase> </textobject> </inlinemediaobject> @@ -229,7 +229,7 @@ TODO Explain multiple interfaces, which interface sends which OGM by which TTL, </para> <para> <inlinemediaobject> - <imageobject> <imagedata fileref="images/tq_prop.pdf" format="EPS" scale="40" /> </imageobject> + <imageobject> <imagedata fileref="images/tq_prop.eps" format="EPS" scale="40" /> </imageobject> <imageobject> <imagedata fileref="images/tq_prop.png" format="PNG" /> </imageobject> <textobject> <phrase>TQ propagation</phrase> </textobject> </inlinemediaobject> @@ -241,7 +241,7 @@ TODO Explain multiple interfaces, which interface sends which OGM by which TTL, Example: Node A and B are neighbors. Node A has a good connection towards node B but not vice versa. The node C has a good connection towards node A and a bad connection back, and C has a good receiving link quality and bad sending quality towards B. </para> <para> <inlinemediaobject> - <imageobject> <imagedata fileref="images/tq_prop_best1.pdf" format="EPS" scale="40" /> </imageobject> + <imageobject> <imagedata fileref="images/tq_prop_best1.eps" format="EPS" scale="40" /> </imageobject> <imageobject> <imagedata fileref="images/tq_prop_best1.png" format="PNG" /> </imageobject> <textobject> <phrase>TQ propagation - example topology</phrase> </textobject> </inlinemediaobject> @@ -251,7 +251,7 @@ TODO Explain multiple interfaces, which interface sends which OGM by which TTL, </para> <para> <inlinemediaobject> - <imageobject> <imagedata fileref="images/tq_prop_best2.pdf" format="EPS" scale="40" /> </imageobject> + <imageobject> <imagedata fileref="images/tq_prop_best2.eps" format="EPS" scale="40" /> </imageobject> <imageobject> <imagedata fileref="images/tq_prop_best2.png" format="PNG" /> </imageobject> <textobject> <phrase>TQ propagation - different paths for the OGM</phrase> </textobject> </inlinemediaobject> @@ -262,7 +262,7 @@ TODO Explain multiple interfaces, which interface sends which OGM by which TTL, </para> <para> <inlinemediaobject> - <imageobject> <imagedata fileref="images/tq_prop_best3.pdf" format="EPS" scale="40" /> </imageobject> + <imageobject> <imagedata fileref="images/tq_prop_best3.eps" format="EPS" scale="40" /> </imageobject> <imageobject> <imagedata fileref="images/tq_prop_best3.png" format="PNG" /> </imageobject> <textobject> <phrase>TQ propagation - only the best path is propagated</phrase> </textobject> </inlinemediaobject> @@ -294,7 +294,7 @@ TODO Explain multiple interfaces, which interface sends which OGM by which TTL, </para> <para> <inlinemediaobject> - <imageobject> <imagedata fileref="images/asym_link1.pdf" format="EPS" scale="50" /> </imageobject> + <imageobject> <imagedata fileref="images/asym_link1.eps" format="EPS" scale="50" /> </imageobject> <imageobject> <imagedata fileref="images/asym_link1.png" format="PNG" scale="50" /> </imageobject> <textobject> <phrase>Asymetry situation without asymetry penalty</phrase> </textobject> </inlinemediaobject> @@ -304,7 +304,7 @@ TODO Explain multiple interfaces, which interface sends which OGM by which TTL, </para> <para> <inlinemediaobject> - <imageobject> <imagedata fileref="images/asym_penalty.pdf" format="EPS" /> </imageobject> + <imageobject> <imagedata fileref="images/asym_penalty.eps" format="EPS" /> </imageobject> <imageobject> <imagedata fileref="images/asym_penalty.png" format="PNG" /> </imageobject> <textobject> <phrase>graph for asymetry penalty</phrase> </textobject> </inlinemediaobject> @@ -314,7 +314,7 @@ TODO Explain multiple interfaces, which interface sends which OGM by which TTL, </para> <para> <inlinemediaobject> - <imageobject> <imagedata fileref="images/asym_link2.pdf" format="EPS" scale="50" /> </imageobject> + <imageobject> <imagedata fileref="images/asym_link2.eps" format="EPS" scale="50" /> </imageobject> <imageobject> <imagedata fileref="images/asym_link2.png" format="PNG" /> </imageobject> <textobject> <phrase>Asymetry situation with applied asymetry penalty</phrase> </textobject> </inlinemediaobject> @@ -331,7 +331,7 @@ TODO Explain multiple interfaces, which interface sends which OGM by which TTL, </para> <para> <inlinemediaobject> - <imageobject> <imagedata fileref="images/hop_penalty3.pdf" format="EPS" scale="50" /> </imageobject> + <imageobject> <imagedata fileref="images/hop_penalty3.eps" format="EPS" scale="50" /> </imageobject> <imageobject> <imagedata fileref="images/hop_penalty3.png" format="PNG" /> </imageobject> <textobject> <phrase>example topology</phrase> </textobject> </inlinemediaobject> @@ -341,7 +341,7 @@ TODO Explain multiple interfaces, which interface sends which OGM by which TTL, </para> <para> <inlinemediaobject> - <imageobject> <imagedata fileref="images/hop_penalty4.pdf" format="EPS" scale="50" /> </imageobject> + <imageobject> <imagedata fileref="images/hop_penalty4.eps" format="EPS" scale="50" /> </imageobject> <imageobject> <imagedata fileref="images/hop_penalty4.png" format="PNG" /> </imageobject> <textobject> <phrase>packet hops</phrase> </textobject> </inlinemediaobject> @@ -354,7 +354,7 @@ TODO Explain multiple interfaces, which interface sends which OGM by which TTL, </para> <para> <inlinemediaobject> - <imageobject> <imagedata fileref="images/hop_penalty5.pdf" format="EPS" scale="50" /> </imageobject> + <imageobject> <imagedata fileref="images/hop_penalty5.eps" format="EPS" scale="50" /> </imageobject> <imageobject> <imagedata fileref="images/hop_penalty5.png" format="PNG" /> </imageobject> <textobject> <phrase>route candidates</phrase> </textobject> </inlinemediaobject> @@ -367,7 +367,7 @@ TODO Explain multiple interfaces, which interface sends which OGM by which TTL, </para> <para> <inlinemediaobject> - <imageobject> <imagedata fileref="images/hop_penalty6.pdf" format="EPS" scale="50" /> </imageobject> + <imageobject> <imagedata fileref="images/hop_penalty6.eps" format="EPS" scale="50" /> </imageobject> <imageobject> <imagedata fileref="images/hop_penalty6.png" format="PNG" /> </imageobject> <textobject> <phrase>applied hop penalty</phrase> </textobject> </inlinemediaobject> @@ -382,7 +382,7 @@ TODO Explain multiple interfaces, which interface sends which OGM by which TTL, </para> <para> <inlinemediaobject> - <imageobject> <imagedata fileref="images/echo_cancel1.pdf" format="EPS" scale="50" /> </imageobject> + <imageobject> <imagedata fileref="images/echo_cancel1.eps" format="EPS" scale="50" /> </imageobject> <imageobject> <imagedata fileref="images/echo_cancel1.png" format="PNG" /> </imageobject> <textobject> <phrase>communication without echo cancellation penalty</phrase> </textobject> </inlinemediaobject> @@ -400,7 +400,7 @@ TODO Explain multiple interfaces, which interface sends which OGM by which TTL, </para> <para> <inlinemediaobject> - <imageobject> <imagedata fileref="images/echo_cancel2.pdf" format="EPS" scale="50" /> </imageobject> + <imageobject> <imagedata fileref="images/echo_cancel2.eps" format="EPS" scale="50" /> </imageobject> <imageobject> <imagedata fileref="images/echo_cancel2.png" format="PNG" /> </imageobject> <textobject> <phrase>communication without echo cancellation penalty</phrase> </textobject> </inlinemediaobject> diff --git a/images/Makefile b/images/Makefile index 03f5ded9..405b892f 100644 --- a/images/Makefile +++ b/images/Makefile @@ -9,15 +9,15 @@ TEX_IMAGES=compute_tq.tex tq_prop_calc.tex PNG_IMAGES= $(DIA_IMAGES:.dia=.png) PNG_IMAGES+=$(GP_IMAGES:.gp=.png) PNG_IMAGES+=$(TEX_IMAGES:.tex=.png) -PDF_IMAGES= $(DIA_IMAGES:.dia=.pdf) -PDF_IMAGES+=$(GP_IMAGES:.gp=.pdf) -PDF_IMAGES+=$(TEX_IMAGES:.tex=.pdf) +EPS_IMAGES= $(DIA_IMAGES:.dia=.eps) +EPS_IMAGES+=$(GP_IMAGES:.gp=.eps) +EPS_IMAGES+=$(TEX_IMAGES:.tex=.eps)
.PHONY: clean -.SUFFIXES: .dia .png .eps .pdf .gp +.SUFFIXES: .dia .png .eps .gp
default: all -all: $(PDF_IMAGES) $(PNG_IMAGES) +all: $(EPS_IMAGES) $(PNG_IMAGES)
.gp.png: gnuplot $< @@ -28,16 +28,13 @@ all: $(PDF_IMAGES) $(PNG_IMAGES) /usr/bin/dia -e $@ $< .dia.eps: /usr/bin/dia -e $@ $< -.eps.pdf: - /usr/bin/epstopdf --outfile=$@ $< -.tex.pdf: +.tex.eps: rm -f file_tmp.* cp $< file_tmp.tex latex file_tmp.tex dvips file_tmp.dvi ps2eps -l file_tmp.ps - epstopdf file_tmp.eps - mv file_tmp.pdf $@ + mv file_tmp.eps $@ rm -f file_tmp.*
.tex.png: @@ -48,4 +45,4 @@ all: $(PDF_IMAGES) $(PNG_IMAGES) convert file_tmp.ps $@ rm -f file_tmp.* clean: - rm -f *.png *.eps *.pdf + rm -f *.png *.eps