-
Notifications
You must be signed in to change notification settings - Fork 87
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
Vips::Error VipsForeignSave in gif images (not a known file format) #16
Comments
Thanks for opening this issue. I'll look into this and see if it looks doable. I don't have a problem doing this as long as it doesn't cause bloat. I'm not sure how much space usage libmagick introduces (the name is reminiscent of imagemagick which is what makes me wonder). If you would like, you are welcome to fork the repo and add this to the build. Then we can compare the build sizes. If you would rather I do the test, I'll try to work on it this weekend. |
Thanks for the answer @brandoncc 🙂 I tried forking the repo and doing a new build installing I suspect I didn't configure the build properly. JCupitt mentioned to add libmagick support but I'm not quite sure how to do that in the buildpack. |
👋 @mllocs and @brandoncc I made this change on our fork and the net increase inside the @brandoncc if that seems like an acceptable increase in size I'd be happy to submit a PR with the updated configuration and builds. It might be worth pointing out that the libvips install guides flag the increased attack surface by including Imagemagick in the build.
|
libvips 8.12 has a new built-in GIF saver, so you no longer need imagemagick for this feature. |
Hi, thanks for this build pack, however I still see the original issue mentioned on libvips 8.12.1-Wed |
Sorry, I misspoke, libvips has a new GIF saver, but it needs cgif for the actual encode. This should be added to the build and imagemagick removed. https://github.com/dloebl/cgif (cgif is only v0.2, but it's being used by quite a few large sites (like shopify), so (imo) it's fine) libvips 8.12.1 didn't fall back to imagemagick correctly for GIF, but 8.12.2 fixes this. |
Thank you for letting us know about that new GIF saver, John! I'll work on adding this over the weekend. Sorry for the delay on this issue, everyone. |
Yeah, I had real trouble adding cgif via aptfile if anyone knows how please share the result. |
@jcupitt I'm guessing that I need to add cgif to the build script, rather than just installing it on the server after the fact. Can you confirm that? @matthewford if John confirms, then this is the reason. I'll build it with cgif this weekend (likely tomorrow). |
Yes, you need to build from source (it's very simple) since cgif hasn't been packaged yet (as far as I know). |
And just to push this verification a little further, it needs to be built/available during the build of libvips. Is that correct, John? |
That's right -- check the messages from configure. I would add libspng as well, if you're revising this stuff. It's quite a bit faster and smaller than libpng. I see:
You can use |
You are the best, John. Thank you again. |
Hi @brandoncc any chance of updating the buildpack? Many thanks. |
Sorry I haven't pushed any changes. I actually did the upgrades but I
haven't had time to test them. Maybe I'll push to a PR so others can do
some testing too. I'm slightly fearful of breaking things that already work.
…On Thu, Mar 10, 2022, 2:08 AM Matthew Ford ***@***.***> wrote:
Hi @brandoncc <https://github.com/brandoncc> any chance of updating the
buildpack? Many thanks.
—
Reply to this email directly, view it on GitHub
<#16 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAEEZZNXFXHRAQCRDHIPO2DU7HC3PANCNFSM4Z3MLU5A>
.
You are receiving this because you were mentioned.Message ID:
***@***.***>
|
@brandoncc happy to test if there is a branch/pr? |
I'm sorry for the extremely long delay on this issue. Saving GIFs should work now https://github.com/brandoncc/heroku-buildpack-vips/blob/4d51d1cb1546ace27ccfd8aa928c017c2cfd4a3d/build/configurations/heroku-22.config.log#L38 If there is any further trouble, feel free to re-open the issue. |
Hello,
I'm using this buildpack in a Rails applications in Heroku. I managed to make it work but I'm having issues with gif images.
I get the error when dealing with gif images:
I found this thread exposing a similar issue and the proposed solution is to rebuild libvips with libmagick support.
I there a way to do that using this buildpack or should I do a fork instead?
Thanks!
The text was updated successfully, but these errors were encountered: