Ubuntu 18.04 has IM built with no rsvg delegate.
Is there any way to get convert to use rsvg without recompiling IM?
delegates.xml contains a reference for rsvg-convert, but it is ignored by convert.
So far I have tried:
- installed rsvg toolset -- well, of course
- removed inkscape entry from delegates -- no changes
- tried to create new fake fromat FSVG with its delegate -- could not manage to create a mapping from svg files to FSVG or format to show up in list.
- changed rsvg-convert decode="svg" to decode="svg.decode" -- rsvg-convert is now executed, but arguments are numeric. If I change argument tyoes from %o/%i to %s, arguments look right (file names), but files contain no data.
- created fake inkscape script that internally uses rsvg-convert -- closest to the result, but IM seems to use inkscape conversion report that I don't know how to generate.
Any further suggestions?
I really would like to avoid installing inkscape on the servers or create separate workflow for svg and other images formats.
rsvg-convert
Re: rsvg-convert
Managed to get it working to some extent.
1. edited delegates.xml, replaced
with
2. created /usr/bin/im-rsvg-convert file
3. chmod +x /usr/bin/im-rsvg-convert
Works on my computer™, but it is nasty hack that can break any time. I'm not feeling comfortable to go to prod with it. Anyway, may be it will help someone.
1. edited delegates.xml, replaced
Code: Select all
<delegate decode="svg" ...
<delegate decode="svg:decode" ...
Code: Select all
<delegate decode="svg:decode" command=""im-rsvg-convert" "%s" "%s""/>
Code: Select all
#!/bin/bash
rsvg-convert -o "$2" "$1"
Works on my computer™, but it is nasty hack that can break any time. I'm not feeling comfortable to go to prod with it. Anyway, may be it will help someone.