[FFmpeg-user] ffmpeg built static, yet "libopenjp2.so.7: cannot open shared object file"

Moritz Barsnick barsnick at gmx.net
Sat Aug 12 23:27:24 EEST 2017


On Fri, Aug 11, 2017 at 16:27:16 -0700, tlum wrote:

Wow, how did you manage to compose this email? See here, this is what
the users get:
http://ffmpeg.org/pipermail/ffmpeg-user/2017-August/036951.html

I can see it here though:
http://www.ffmpeg-archive.org/ffmpeg-built-static-yet-quot-libopenjp2-so-7-cannot-open-shared-object-file-quot-td4680895.html

> I'm having trouble adding OpenJPEG to my ffmpeg build. I'm doing a static
> build, still I'm getting:
>
> ffmpeg: error while loading shared libraries: libopenjp2.so.7: cannot open shared object file: No such file or directory

So apparently, ffmpeg isn't static after all.

> ffmpeg is being configured like so:
>
> PKG_CONFIG_PATH="$HOME/ffmpeg_build/lib/pkgconfig" ./configure --prefix="$HOME/ffmpeg_build" \
>   --extra-cflags="-I$HOME/ffmpeg_build/include" --extra-ldflags="-L$HOME/ffmpeg_build/lib -ldl" \
>   --bindir="$HOME/bin" --pkg-config-flags="--static" \
>   --enable-gpl \
>   --enable-libfdk_aac \
>   --enable-libfreetype \
>   --enable-libmp3lame \
>   --enable-libopus \
>   --enable-libvorbis \
>   --enable-libvpx \
>   --enable-libx264 \
>   --enable-libx265 \
>   --enable-nonfree \
>   --enable-libvidstab \
>   --enable-libfontconfig \
>   --enable-libfribidi \
>   --enable-libass \
>   --enable-libopenjpeg
[...]
> configure confirms:
> 
> configure confirms:
>
> static                    yes
> shared                    no

Well, either something is going wrong during the configure or linking
process, or you are not using that ffmpeg binary.

What does
$ which ffmpeg
$ file ffmpeg
$ ldd ffmpeg
and finally
$ ffmpeg
say?

Moritz


More information about the ffmpeg-user mailing list