[PATCH] docs-rst: automatically convert Graphviz and SVG images

Mauro Carvalho Chehab mchehab at s-opensource.com
Thu Mar 2 21:47:00 UTC 2017


Em Thu, 2 Mar 2017 18:36:31 -0300
Mauro Carvalho Chehab <mchehab at s-opensource.com> escreveu:

> > Found another issue on the patch. The HTML output is pointing to the
> > wrong place: instead of using a relative patch, it is keeping 
> > an absolute one.
> > 
> > This is what it produced from Documentation/media/uapi/v4l/dev-subdev.rst:
> > 
> > <div class="figure align-center" id="id2">
> > <img alt="pipeline.dot" src="/d00/kernel/Documentation/output/media/uapi/v4l/pipeline.svg" /><p class="caption"><span class="caption-text">Image Format Negotiation on Pipelines</span></p>
> > <div class="legend">
> > High quality and high speed pipeline configuration</div>
> > </div>
> > 
> > There, the "src=" is pointing to the full patch, with doesn't work, as
> > my html server uses a different patch to find the file. It should,
> > instead, use a patch relative to the place where the html file is
> > stored, e. g. in this case, either:
> > 	./pipeline.svg
> > or just:
> > 	pipeline.svg  
> 
> Btw, PDF conversion is also not working:
> 
> 
>   File "/d00/kernel/Documentation/sphinx/kfigure.py", line 241, in svg2pdf
>     cmd = [convert_cmd, svg_fname, pdf_fname]
> 
> 	NameError: name 'convert_cmd' is not defined
> 
> And including SVG files for HTML output also seems to be problematic.

Forgot to mention, but I'm using here Sphinx 1.4.9, installed via
pip3 (So, python3).

> 
> I'll post the RFCv2 patch that I'm using to test it.

Patch posted. Hopefully, it will help you to see the problems I'm 
facing on my tests.

Thanks,
Mauro


More information about the dri-devel mailing list