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

So far, I've tried:

  1. Obviously re-configure and re-compile.
  2. Deleting all binaries from build dir, as well as looking for direct hard-coded references to lib versions (which I didn't found).
  3. 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?

1 Answer 1


For anybody getting this issue: it was the shared libraries in /usr/local/lib, built months ago, before the update. The newer compilations did build everything fine, but I wasn't running sudo make install in order to deploy the newer shared libs. So, the newer executable was trying to use the older shared libs, which in turn indeed pointed to now non existant libs.

Case closed.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.