I have a custom FFmpeg build, with custom filters, built from FFmpeg master branch. It's working fine in 20.04, in several machines. However, when I tried to run it in my personal machine, updated from 20.04 to 22.04 a few weeks ago, I got this error:
$ ./ffmpeg
./ffmpeg: error while loading shared libraries: libvpx.so.6: cannot open shared object file: No such file or directory
The obvious reason for that the need to recompile it using new headers from new packages pointing to new versions of the libs. Which I did. However, no matter how many times I recompiled it, it always ends up looking for the same old versions of the libs.
Here's a list of libs not working in my build process:
$ ldd ./ffmpeg | grep not
libvpx.so.6 => not found
libwebp.so.6 => not found
libcodec2.so.0.9 => not found
libx264.so.155 => not found
libx265.so.179 => not found
All of them have newer versions installed:
$ find /usr/ -name "libvpx.so*" -or -name "libwebp.so*" -or -name "libcodec2.so*" -or -name "libx264.so*" -or -name "libx265.so*" 2>/dev/null
/usr/lib/i386-linux-gnu/libwebp.so.7.1.3
/usr/lib/i386-linux-gnu/libwebp.so.7
/usr/lib/x86_64-linux-gnu/libwebp.so.5
/usr/lib/x86_64-linux-gnu/libx264.so.163
/usr/lib/x86_64-linux-gnu/libcodec2.so
/usr/lib/x86_64-linux-gnu/libx265.so.79
/usr/lib/x86_64-linux-gnu/libvpx.so.3.0.0
/usr/lib/x86_64-linux-gnu/libwebp.so.5.0.4
/usr/lib/x86_64-linux-gnu/x264-10bit/libx264.so.148
/usr/lib/x86_64-linux-gnu/libvpx.so.7.0.0
/usr/lib/x86_64-linux-gnu/libwebp.so
/usr/lib/x86_64-linux-gnu/libvpx.so.7.0
/usr/lib/x86_64-linux-gnu/libcodec2.so.1.0
/usr/lib/x86_64-linux-gnu/libvpx.so.3
/usr/lib/x86_64-linux-gnu/libvpx.so.7
/usr/lib/x86_64-linux-gnu/libwebp.so.7.1.3
/usr/lib/x86_64-linux-gnu/libvpx.so
/usr/lib/x86_64-linux-gnu/libwebp.so.7
/usr/lib/x86_64-linux-gnu/libx265.so
/usr/lib/x86_64-linux-gnu/libvpx.so.3.0
/usr/lib/x86_64-linux-gnu/libx265.so.199
/usr/lib/x86_64-linux-gnu/libx264.so
/usr/lib/x86_64-linux-gnu/libx264.so.148
So far, I've tried:
- Obviously re-configure and re-compile.
- Deleting all binaries from build dir, as well as looking for direct hard-coded references to lib versions (which I didn't found).
- Cloning the repo on a clean directory, with the same configuration flags but no custom code.
In all cases, the build is successful, but the binary files have references to those non existant libraries. My configuration flags are all --enable-libstuff
for different libs, as is normal when setting up some build, and does not have explicit versioning.
I don't see anybody online having this problem, so I suppose may be some local issue. But I don't understand what it could be, as I don't have those versions hardcoded anywhere.
So, my question is: what could be affecting my build in Ubuntu 22.04, that ends up behaving this way?