27

I have been using avconv without issue, however since upgrading to 15.10 and switching to ffmpeg, I have a library configuration mismatch warning in my script output.

This is my command to rip CDs for my iPod and Fiio X5 Mk2.

#!/bin/bash

cdparanoia -Bv
for f in ./*.wav; do avconv -i "$f" -acodec alac "${f%.*}.m4a"; done
eject
ls

When I replaced avconv with ffmpeg I now see WARNING: library configuration mismatch in the middle of the output:

ffmpeg version 2.7.3-0ubuntu0.15.10.1 Copyright (c) 2000-2015 the FFmpeg developers
  built with gcc 5.2.1 (Ubuntu 5.2.1-22ubuntu2) 20151010
  configuration: --prefix=/usr --extra-version=0ubuntu0.15.10.1 --build-suffix=-ffmpeg --toolchain=hardened --libdir=/usr/lib/x86_64-linux-gnu --incdir=/usr/include/x86_64-linux-gnu --enable-gpl --enable-shared --disable-stripping --enable-avresample --enable-avisynth --enable-frei0r --enable-gnutls --enable-ladspa --enable-libass --enable-libbluray --enable-libbs2b --enable-libcaca --enable-libcdio --enable-libflite --enable-libfontconfig --enable-libfreetype --enable-libfribidi --enable-libgme --enable-libgsm --enable-libmodplug --enable-libmp3lame --enable-libopenjpeg --enable-openal --enable-libopus --enable-libpulse --enable-librtmp --enable-libschroedinger --enable-libshine --enable-libspeex --enable-libtheora --enable-libtwolame --enable-libvorbis --enable-libvpx --enable-libwavpack --enable-libwebp --enable-libxvid --enable-libzvbi --enable-opengl --enable-x11grab --enable-libdc1394 --enable-libiec61883 --enable-libzmq --enable-libssh --enable-libsoxr --enable-libx264 --enable-libopencv --enable-libx265
  WARNING: library configuration mismatch
  avcodec     configuration: --prefix=/usr --extra-version=0ubuntu0.15.10.1 --build-suffix=-ffmpeg --toolchain=hardened --libdir=/usr/lib/x86_64-linux-gnu --incdir=/usr/include/x86_64-linux-gnu --enable-gpl --enable-shared --disable-stripping --enable-avresample --enable-avisynth --enable-frei0r --enable-gnutls --enable-ladspa --enable-libass --enable-libbluray --enable-libbs2b --enable-libcaca --enable-libcdio --enable-libflite --enable-libfontconfig --enable-libfreetype --enable-libfribidi --enable-libgme --enable-libgsm --enable-libmodplug --enable-libmp3lame --enable-libopenjpeg --enable-openal --enable-libopus --enable-libpulse --enable-librtmp --enable-libschroedinger --enable-libshine --enable-libspeex --enable-libtheora --enable-libtwolame --enable-libvorbis --enable-libvpx --enable-libwavpack --enable-libwebp --enable-libxvid --enable-libzvbi --enable-opengl --enable-x11grab --enable-libdc1394 --enable-libiec61883 --enable-libzmq --enable-libssh --enable-libsoxr --enable-libx264 --enable-libopencv --enable-libx265 --enable-version3 --disable-doc --disable-programs --disable-avdevice --disable-avfilter --disable-avformat --disable-avresample --disable-postproc --disable-swscale --enable-libopencore_amrnb --enable-libopencore_amrwb --enable-libvo_aacenc --enable-libvo_amrwbenc
  libavutil      54. 27.100 / 54. 27.100
  libavcodec     56. 41.100 / 56. 41.100
  libavformat    56. 36.100 / 56. 36.100
  libavdevice    56.  4.100 / 56.  4.100
  libavfilter     5. 16.101 /  5. 16.101
  libavresample   2.  1.  0 /  2.  1.  0
  libswscale      3.  1.101 /  3.  1.101
  libswresample   1.  2.100 /  1.  2.100
  libpostproc    53.  3.100 / 53.  3.100
Guessed Channel Layout for  Input Stream #0.0 : stereo
Input #0, wav, from './track01.cdda.wav':
  Duration: 00:02:36.20, bitrate: 1411 kb/s
    Stream #0:0: Audio: pcm_s16le ([1][0][0][0] / 0x0001), 44100 Hz, 2 channels, s16, 1411 kb/s
Output #0, ipod, to './track01.cdda.m4a':
  Metadata:
    encoder         : Lavf56.36.100
    Stream #0:0: Audio: alac (alac / 0x63616C61), 44100 Hz, stereo, s16p, 128 kb/s
    Metadata:
      encoder         : Lavc56.41.100 alac
Stream mapping:
  Stream #0:0 -> #0:0 (pcm_s16le (native) -> alac (native))
Press [q] to stop, [?] for help
size=   16226kB time=00:02:36.22 bitrate= 850.9kbits/s   
video:0kB audio:16219kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: 0.046357%

Checking other sites suggests I have installed ffmpeg on an early version of Ubuntu where avconv was the default, but this wasn't the case here.

Can anyone suggest a resolution for me?

6
  • Check askubuntu.com/questions/373322/…
    – Rmano
    Dec 26, 2015 at 13:29
  • 2
    The library mismatch warning is due to the use of the 'extra' packages/packaging. It's benign & can be ignored
    – doug
    Dec 26, 2015 at 14:30
  • Is there any way to hide the terminal spam without removing the libavcodec-ffmpeg-extra56 package? May 16, 2016 at 23:05
  • 1
    I found a way; although this doesn't answer the original question, which uses a bash script, I put for i in ffmpeg ffplay ffprobe ffserver; do alias $i="$i -hide_banner"; done in my .bashrc file. May 16, 2016 at 23:43
  • Launchpad bug for this warning message: bugs.launchpad.net/ubuntu/+source/ffmpeg-extra/+bug/730159
    – Cas
    Mar 28, 2017 at 16:26

5 Answers 5

18

To fix this remove the following package:

sudo apt remove libavcodec-ffmpeg-extra56

Apt will remove the package and replace it with libavcodec-ffmpeg56 resulting in ffmpeg no longer output a warning message.

For details on libavcodec-ffmpeg-extra56 package and why it is likely no needed, see: https://askubuntu.com/a/847566/8570

7
  • 2
    it resolved same issue in ubuntu 16.04 as well.
    – Ejaz
    Sep 24, 2016 at 3:52
  • 4
    In ubuntu 17.10, this has become libavcodec-extra57 / libavcodec-extra. Amazing that this is still a thing.
    – Dav Clark
    Dec 12, 2017 at 23:53
  • At the risk of upsetting the Ubuntu Police: This also worked on Mint 18. (Great answer, BTW—The quick fix, the explanation, and the reference link. Thank you.) Aug 19, 2018 at 15:41
  • The comment of @DavClark is still valid for Ubuntu 18.04 Oct 27, 2018 at 10:15
  • 3
    Thanks @DavClark! It works on ubuntu 18.04. I get rid of the warning via sudo apt remove libavcodec-extra57.
    – hao
    Jun 18, 2019 at 5:43
12

Adding what worked for me personally (Ubuntu 20.10) because this is one of the first results when searching for this error, and it's been making me mad for the past couple days:

sudo apt install --reinstall libavcodec58 libavdevice58 libavfilter7 libavformat58 libavresample4 libavutil56 libpostproc55 libswresample3 libswscale5

I didn't even need to reinstall FFmpeg.

2
  • 2
    You are a star! This worked for me on Mint 20.2, but the earlier answers here didn't. Thank you! Nov 6, 2021 at 15:29
  • I confirm this answer is the only one that worked for me on Mint 20.3 as well. Much appreciated!
    – Adrien
    Jun 20, 2022 at 13:35
11

On Ubuntu 18.04:

sudo apt remove libavcodec-extra57
3

On Ubuntu 22.04 I just had to install libavcodec58. It warned that it would remove libavcodec-extra and libavcodec-extra58.

0

This is because your libs built from ffmpeg source and libs in your system(/usr/lib/ or /usr/local/lib/) are in conflict. So

find . -name "avcodec"

If libavcodec.so.* in /usr/local/lib, /usr/lib/, /usr/lib/x86_64-linux-gnu or /usr/lib/i386-linux-gnu, please replace them with the libs built from ffmpeg source and create soft links.

cp -r /the/path/to/ffmpeg/build/lib/* /usr/local/lib/
sudo ln -s /usr/local/lib/libavcodec.so.59.18.100 /usr/local/lib/libavcodec.so.59

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .