-
Notifications
You must be signed in to change notification settings - Fork 65
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add librsvg for SVG rasterization support #444
Comments
Hey! yes that would be nice. I did try it some years ago master...librsvg but lost motivation when there was some rust issues etc, don't remember the details. I think the situation is probably much better today but i think we still probably have to figure out how to build static libglib, pango and maybe something more. |
Have a WIP PR now #445 it's a bit of a mess to get it working but should be doable and i did managed to build a static ffmpeg binary with just librsvg and it's dependencies. Now have to make it all work together :) If the multi-arch test build succeeds there should be a image tag called |
Amazing! 🤩 |
Ran into rust-lang/rust#104707 static-ffmpeg links with librav1e and now librsvg which both are written in rust which seems to cause symbol collision. Hope there is some workaround, will have a look later today |
Think found a workaround using If things go well there should be a |
@khiemtong could you have a look at the new section in the readme https://github.com/wader/static-ffmpeg/blob/316f67840ab1b9fdf91b31071c471fd30d4b320f/README.md#fonts-usage-with-svg-or-draw-text-filters-etc about fonts and see if it works (use the |
@wader Works as expected 🎊 🏅
I'll do more testing on other files but looks like we're cooking, thanks for all the work on this! |
An alternative to |
@khiemtong things seem to work? I'm still a bit reluctant about If this command returns a line with count 2 we probably have a collision for i in $(rm -f ffmpeg* ; make V=1 LD="gcc -Wl,-t" | sort | grep '.a$' | uniq | grep -Ev '(librav1e|librsvg|libtheora|libav)'); do nm --extern-only $i | awk '/^\d+ [TDB]/ {pr
int $3}' | sort | uniq ; done | sort | uniq -c | sort -n |
@wader Yes, for our use cases things work so defer to you how to proceed. Frankly the compilation and symbols are out of my depth but I'm trying to follow as best I can 😄 I've been thinking about how to ensure stability based on your comments. Only idea I've had is to just compile a separate tags that includes i.e. If you want main path
If you want everything
Then as things get more tested, we can move more options into the stable path or forever leave librsvg to the unstable tag. A bit more maintenance but mitigates the risk? Another option is if there's just a Dockerfile arg to build with librsvg that would work too since whoever needs it could opt-in that way and build it themselves |
Great! Ideally i would want librsvg to be included by default and no args etc to keep things simple. The problem we encountered now is not really an issue with librsvg, it just happen to be the second rust-based library to link with, so this was probably inevitable to happen as more and more libraries use rust. So i think i'm lening towards using |
Now merged 🥳 and i've also tagged 7.0-2 |
Feature request to add
librsvg
for SVG supportThe text was updated successfully, but these errors were encountered: