1

I want to install the latest ffmpeg 2.8.5 on the Centos server. Followed this website http://www.mysql-apache-php.com/ffmpeg-install.htm and completed the installation. But the installed ffmpeg is an old 0.6.5 version. And I tried yum update ffmpeg, but it said there's no update available.

And now I have download the latest version on ffmpeg official website, and extracted the tar.gz file. But there's no configure.sh. and I totally have no idea what I should do now.

2
  • Generic steps. 1) You have to install the dev libarires. See: stackoverflow.com/questions/13227162/… || possiblelossofprecision.net/?p=949 . 2) ./configure --prefix=/usr 3) make 4) make install (run this as root) ||| You should run command 2, 3, 4 in the folder of the extracted source. And even like this, it is not 100% sure that it will compile. CentOS ships with really old libraries and software. You should just use Ubuntu LTS, or the latest Ubuntu.
    – Apache
    Jan 27, 2016 at 9:13
  • i can't install the dev libraries. Centos said error: Unable to open ffmpeg.spec: No such file or directory Jan 27, 2016 at 9:28

2 Answers 2

8

You were looking in the wrong place for documentation. Always check the official sources first. For ffmpeg, the packages provided by distributions are always more or less outdated.

Basically, you have two options:

  1. Install a static build, which is already compiled and ready for use. Go to the download page and select the "Linux Static Builds", not the source code. Extract the build and simply run the ffmpeg binary. You can also copy it to /usr/local/bin or another directory in your $PATH to have it accessible system-wide.

  2. Compile FFmpeg yourself according to the always up-to-date instructions on the FFmpeg wiki. It should be enough to copy-paste all the instructions there. There are also guides for Ubuntu and related distros.

Method 2 gives you more options on the encoders that you can use. The static builds however usually contain everything you absolutely need.

8
  • I just tried to compile the package myself on CentOS and ran into numerous issues. Eg. it needs nasm 2.13 or bigger. My CentOS has only 2.10 installed and it's not obvious how to get a new version installed other than compile those as well. I'm heading towards the binaries builds now. May 25, 2017 at 16:23
  • @SteffenRoller Indeed CentOS only packages 2.10 at the moment. But I would be surprised if it failed… could you please ask a new question about those compilation problems? As far as I can see, only LAME requires nasm, and then only when building from source. You may be able to install libmp3lame-devel and skip building LAME yourself.
    – slhck
    May 26, 2017 at 8:21
  • @SteffenRoller I just checked again, on a fresh CentOS install, the guide works without problems and LAME can be compiled with nasm 2.10.07.
    – slhck
    May 26, 2017 at 8:35
  • I'll check as soon as I'll have access to my computer again. My problem was that make just stopped with "can't find nasm" and also hinted it would need v1.13 or higher. I downloaded the precompiled packages in the end. I also wanted to install libx264, linx265 and vp9. Perhaps the problem was there? May 27, 2017 at 21:34
  • @slhck I followed exactly the CompilationGuide/CentOS[trac.ffmpeg.org/wiki/CompilationGuide/Centos] - it didn't work out for me. Here's the output: pastebin.com/qjwpdvc9 May 29, 2017 at 21:27
0

Let's assume you are trying to install FFmpeg on CentOS/RHEL 7.

1. The RPM Fusion repository depends on the EPEL software repository. If the EPEL is not enabled on your system, enable it by typing:

sudo yum install epel-release

2. Next, enable the RPM Fusion repository by installing the rpm package :

sudo yum localinstall --nogpgcheck https://download1.rpmfusion.org/free/el/rpmfusion-free-release-7.noarch.rpm

3. Once the repository is enabled, install FFmpeg:

sudo yum install ffmpeg ffmpeg-devel

4. Verify the FFmpeg installation by checking its version:

ffmpeg -version

The procedure for CentOS/RHEL 8 is very similar.

1. First you enable the EPEL on RHEL

sudo dnf -y install https://download.fedoraproject.org/pub/epel/epel-release-latest-8.noarch.rpm
sudo yum-config-manager --enable powertools

2. Then you enable the RPM Fusion for EL

sudo dnf localinstall --nogpgcheck https://download1.rpmfusion.org/free/el/rpmfusion-free-release-8.noarch.rpm
sudo dnf install --nogpgcheck https://download1.rpmfusion.org/nonfree/el/rpmfusion-nonfree-release-8.noarch.rpm

3. Finally you can install:

sudo dnf -y install ffmpeg ffmpeg-devel

4. Verify the FFmpeg installation by checking its version:

ffmpeg -version

You must log in to answer this question.

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