BMP does not work in very specific situations ("bmp is not a known buffer format") #4035
Replies: 1 comment 3 replies
-
Does the build output indicate that libvips was successfully built against IM? You should see something similar to the following:
You might also try passing Note that it's generally much easier to install libvips via your package manager (see e.g. #1184). I usually recommend using Rocky Linux (or any other RHEL derivative) in combination with Remi's RPM repository, a third-party repository that includes an up-to-date version of libvips. I've provided an example with BMP support via GraphicsMagick here: |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Hey, I realize this will probably be stretching your willingness to help because the whole setup is very custom-made, but I'm asking in the hopes that you've had a similar issue in the past and could give me a pointer to what may fix it.
So here's the issue in as much detail as possible: I've adopted the build script @kleisauke uses for the NetVips distribution to also include imagemagick, because I need BMP support (please don't ask why). I've done it pretty straightforward with the following additions to the script (beyond some version handling boilerplate):
This produces, as far as I can see, a static library for imagemagick, as well as an ImageMagick folder which contains some documentation. Because libvips should be statically built, and
ldd libvips.so
doesn't list any dependencies beyond the usual.If I use Debain as base for my distribution, then everything works as expected. However, if I use the Scratch docker image and copy
libvips.so
(and its dependencies) over (the same as I do when using debian), then everything works, except any format using libmagick (TIFF does work but from what I can tell, you've added code for it to work without imagemagick). This leads me to believe that something is missing from the produced libvips.so (and dependencies), but gets installed with Debian. But for all the documentation available, there should be nothing missing.Here's the ldd for libvips:
When executing on the Debian distribution, here's what libvips seems to open:
Do notice that there's nothing actually opened in the second part of it. The only thing missing from
ldd libvips.so
islibgomp.so
, but the file seems to be present regardless.I have no idea what else to check. I'm running a complete trace right now to see if there's anything funky going on aside from simple dlopen calls, but I really doubt it. I can't run a trace on the Scratch image by extension of it being scratch and not containing anything I could use. The one thing I could check, if all the files it opens in the Debain version are present, does seem to be the case.
The BMP file is actually created and is a valid BMP file containing the image I expect, so it doesn't fail silently or anything like that.
Beta Was this translation helpful? Give feedback.
All reactions