Linux – FFmpeg: Update FFmpeg to the latest ( GIT ) version


I need to use the new xfade option of FFmpeg which was added about a week ago. My FFmpeg installation on the server ( Ubuntu 18.04.2 ) was about 2 months ago, so I need to update it as I'm getting the following issue:

No such filter: xfade

So, I've tried to update FFmpeg with the following options

Option 1

sudo add-apt-repository -y ppa:mc3man/trusty-media
sudo apt-get update
sudo apt-get install --only-upgrade ffmpeg

Option 2

sudo apt-get update
sudo apt-get install ffmpeg

Both versions say that

ffmpeg is already the newest version (7:3.4.6-0ubuntu0.18.04.1).
0 upgraded, 0 newly installed, 0 to remove and 129 not upgraded

Also, I can see some differences in the ffmpeg -version output from my local and from server.

enter image description here

As you can see, on the local it shows ffmpeg version git-2020-02-03-... but on the server it shows ffmpeg version 3.4.6-0ubuntu0.18.04.1

So, for having xfade option on my server as well I need to update the FFmpeg to the latest ( GIT ) version? What else can I try?

Best Answer

  1. Remove the PPA. It does not provide a current build from the git master branch.

    sudo apt remove ffmpeg
    sudo add-apt-repository --remove ppa:mc3man/trusty-media
  2. Get ffmpeg. There are two options to get ffmpeg from the current git master branch for Ubuntu users:

    • Follow FFmpeg Wiki: Ubuntu which is a step-by-step compilation guide, or
    • Download an already compiled ffmpeg from Make sure to download the git version as the current release branch (4.2 as of writing this answer) does not and will not include the xfade filter. Move it to ~/bin or /usr/local/bin if you want it in your PATH: you may have to re-login for your shell to recognize it. Read the FAQ for additional installation/removal info.

Compiling allows you to fully customize what you need. Downloading is quick and easy.

Related Question