Best way to install ffmpeg
-
- Posts: 59
- Joined: 2015/07/02 08:47:24
Best way to install ffmpeg
I need to install ffmpeg for a script that I will be using. What is the best way to install that, as of now? I may need something like php-ffmpeg too, I am not sure. I cant do that with yum install ffmpeg, and I was reading that I could add an extra repo. At the same time, I was reading in the books not to be adding too many repos too. In general I would like to do it in the best possible way. Maybe download the code from ffmpeg.org? It does not seem like they have good installation instructions there...
-
- Posts: 59
- Joined: 2015/07/02 08:47:24
Re: Best way to install ffmpeg
http://xmodulo.com/how-to-set-up-epel-r ... entos.html
http://ask.xmodulo.com/enable-nux-dexto ... -rhel.html
yum install epel-release (this is needed for Nux Desktop Repo)
rpm --import http://li.nux.ro/download/nux/RPM-GPG-KEY-nux.ro
rpm -Uvh http://li.nux.ro/download/nux/dextop/el ... noarch.rpm
yum install ffmpeg
Do I need php-ffmpeg? This is for a php based tube site script, advanced.
http://ask.xmodulo.com/enable-nux-dexto ... -rhel.html
yum install epel-release (this is needed for Nux Desktop Repo)
rpm --import http://li.nux.ro/download/nux/RPM-GPG-KEY-nux.ro
rpm -Uvh http://li.nux.ro/download/nux/dextop/el ... noarch.rpm
yum install ffmpeg
Do I need php-ffmpeg? This is for a php based tube site script, advanced.
Re: Best way to install ffmpeg
Note that the nux version of ffmpeg is pretty old. It may work quite well for your scripts though. I wound up installing from source, which is also doable.
https://gist.github.com/mustafaturan/7053900 gives instructions
https://gist.github.com/mustafaturan/7053900 gives instructions
New users should check the FAQ and Read Me First pages
Re: Best way to install ffmpeg
I wanted to add that I installed the nux package version of ffmpeg and found it does not seem to have libvpx support compiled into it, so you cannot encode webm (VP8) video. This has killed it as an option for me as a transcoder for web-ready videos for HTML5 videos, since as far as I know you need at least an mp4 and a webm version to satisfy major modern browsers.
If anyone can suggest how to use the nux packages and easily add libvpx support I'm all ears.
Here's the output from it:
Trying to encode to vp8 following instructions at https://trac.ffmpeg.org/wiki/Encode/VP8:
If anyone can suggest how to use the nux packages and easily add libvpx support I'm all ears.
Here's the output from it:
Code: Select all
# rpm -qi ffmpeg
Name : ffmpeg Relocations: (not relocatable)
Version : 2.6.8 Vendor: Nux!
Release : 3.el6.nux Build Date: Tue 03 May 2016 18:48:36 BST
Install Date: Thu 06 Apr 2017 10:16:07 BST Build Host: rpmbuilder
Group : Unspecified Source RPM: ffmpeg-2.6.8-3.el6.nux.src.rpm
Size : 7145654 License: GPLv2+
Signature : RSA/SHA1, Tue 03 May 2016 18:49:05 BST, Key ID e98bfbe785c6cd8a
Packager : http://li.nux.ro/
URL : http://ffmpeg.org/
Summary : Digital VCR and streaming server
Description :
FFmpeg is a complete and free Internet live audio and video
broadcasting solution for Linux/Unix. It also includes a digital
VCR. It can encode in real time in many formats including MPEG1 audio
and video, MPEG4, h263, ac3, asf, avi, real, mjpeg, and flash.
Code: Select all
# ffmpeg -buildconf
ffmpeg version 2.6.8 Copyright (c) 2000-2016 the FFmpeg developers
built with gcc 4.4.7 (GCC) 20120313 (Red Hat 4.4.7-16)
configuration: --prefix=/usr --bindir=/usr/bin --datadir=/usr/share/ffmpeg --incdir=/usr/include/ffmpeg --libdir=/usr/lib64 --mandir=/usr/share/man --arch=x86_64 --optflags='-O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m64 -mtune=generic' --enable-bzlib --disable-crystalhd --enable-gnutls --enable-ladspa --enable-libass --enable-libdc1394 --enable-libfaac --enable-nonfree --disable-indev=jack --enable-libfreetype --enable-libgsm --enable-libmp3lame --enable-openal --enable-libopenjpeg --enable-libopus --enable-libpulse --enable-libschroedinger --enable-libsoxr --enable-libspeex --enable-libtheora --enable-libvorbis --enable-libv4l2 --enable-libx264 --enable-libx265 --enable-libxvid --enable-x11grab --enable-avfilter --enable-avresample --enable-postproc --enable-pthreads --disable-static --enable-shared --enable-gpl --disable-debug --disable-stripping --shlibdir=/usr/lib64 --enable-runtime-cpudetect
libavutil 54. 20.100 / 54. 20.100
libavcodec 56. 26.100 / 56. 26.100
libavformat 56. 25.101 / 56. 25.101
libavdevice 56. 4.100 / 56. 4.100
libavfilter 5. 11.102 / 5. 11.102
libavresample 2. 1. 0 / 2. 1. 0
libswscale 3. 1.101 / 3. 1.101
libswresample 1. 1.100 / 1. 1.100
libpostproc 53. 3.100 / 53. 3.100
configuration:
--prefix=/usr
--bindir=/usr/bin
--datadir=/usr/share/ffmpeg
--incdir=/usr/include/ffmpeg
--libdir=/usr/lib64
--mandir=/usr/share/man
--arch=x86_64
--optflags='-O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector
--param=ssp-buffer-size=4 -m64 -mtune=generic'
--enable-bzlib
--disable-crystalhd
--enable-gnutls
--enable-ladspa
--enable-libass
--enable-libdc1394
--enable-libfaac
--enable-nonfree
--disable-indev=jack
--enable-libfreetype
--enable-libgsm
--enable-libmp3lame
--enable-openal
--enable-libopenjpeg
--enable-libopus
--enable-libpulse
--enable-libschroedinger
--enable-libsoxr
--enable-libspeex
--enable-libtheora
--enable-libvorbis
--enable-libv4l2
--enable-libx264
--enable-libx265
--enable-libxvid
--enable-x11grab
--enable-avfilter
--enable-avresample
--enable-postproc
--enable-pthreads
--disable-static
--enable-shared
--enable-gpl
--disable-debug
--disable-stripping
--shlibdir=/usr/lib64
--enable-runtime-cpudetect
Code: Select all
# ffmpeg -i somefile.mp4 -c:v libvpx -b:v 1M -c:a libvorbis output.webm
ffmpeg version 2.6.8 Copyright (c) 2000-2016 the FFmpeg developers
built with gcc 4.4.7 (GCC) 20120313 (Red Hat 4.4.7-16)
configuration: --prefix=/usr --bindir=/usr/bin --datadir=/usr/share/ffmpeg --incdir=/usr/include/ffmpeg --libdir=/usr/lib64 --mandir=/usr/share/man --arch=x86_64 --optflags='-O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m64 -mtune=generic' --enable-bzlib --disable-crystalhd --enable-gnutls --enable-ladspa --enable-libass --enable-libdc1394 --enable-libfaac --enable-nonfree --disable-indev=jack --enable-libfreetype --enable-libgsm --enable-libmp3lame --enable-openal --enable-libopenjpeg --enable-libopus --enable-libpulse --enable-libschroedinger --enable-libsoxr --enable-libspeex --enable-libtheora --enable-libvorbis --enable-libv4l2 --enable-libx264 --enable-libx265 --enable-libxvid --enable-x11grab --enable-avfilter --enable-avresample --enable-postproc --enable-pthreads --disable-static --enable-shared --enable-gpl --disable-debug --disable-stripping --shlibdir=/usr/lib64 --enable-runtime-cpudetect
libavutil 54. 20.100 / 54. 20.100
libavcodec 56. 26.100 / 56. 26.100
libavformat 56. 25.101 / 56. 25.101
libavdevice 56. 4.100 / 56. 4.100
libavfilter 5. 11.102 / 5. 11.102
libavresample 2. 1. 0 / 2. 1. 0
libswscale 3. 1.101 / 3. 1.101
libswresample 1. 1.100 / 1. 1.100
libpostproc 53. 3.100 / 53. 3.100
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'somefile.mp4':
Metadata:
major_brand : mp42
minor_version : 0
compatible_brands: mp42mp41
creation_time : 2017-04-11 14:51:39
Duration: 00:02:39.81, start: 0.000000, bitrate: 10411 kb/s
Stream #0:0(eng): Video: h264 (Main) (avc1 / 0x31637661), yuv420p(tv, bt709), 1920x1080, 10089 kb/s, 25 fps, 25 tbr, 25k tbn, 50 tbc (default)
Metadata:
creation_time : 2017-04-11 14:51:39
handler_name : Alias Data Handler
encoder : AVC Coding
Stream #0:1(eng): Audio: aac (LC) (mp4a / 0x6134706D), 48000 Hz, stereo, fltp, 317 kb/s (default)
Metadata:
creation_time : 2017-04-11 14:51:39
handler_name : Alias Data Handler
Unknown encoder 'libvpx'
Re: Best way to install ffmpeg
Ask nux to include the option. He has his own forum and is open to requests.
The future appears to be RHEL or Debian. I think I'm going Debian.
Info for USB installs on http://wiki.centos.org/HowTos/InstallFromUSBkey
CentOS 5 and 6 are deadest, do not use them.
Use the FAQ Luke
Info for USB installs on http://wiki.centos.org/HowTos/InstallFromUSBkey
CentOS 5 and 6 are deadest, do not use them.
Use the FAQ Luke
Re: Best way to install ffmpeg
Thank you, I have done now https://forums.nux.ro/index.php?t=msg&t ... 3#msg_3823TrevorH wrote:Ask nux to include the option. He has his own forum and is open to requests.
-
- Posts: 1
- Joined: 2017/10/10 16:35:53
Re: Best way to install ffmpeg
I contacted Nux and he said libvpx in CentOS is too old to be picked up by more recent ffmpeg versions. After installing and trying a few binaries that didn't include libvpx either I finally went ahead and built it from sources. Wasn't too painful should take about 20-30 min if you make the small changes I suggest.
https://trac.ffmpeg.org/wiki/CompilationGuide/Centos
The guide is a little out of date as of the time of this post, you do need to install Yasm in order to make libvpx (they say to skip yasm now), and:
http://downloads.xiph.org/releases/
is now redirecting to:
https://ftp.osuosl.org/pub/xiph/releases/
So you have to update those urls under the libogg and libvorbis sections appropriately.
I also had to install yum-utils to get access to yum-config-manger.
Other than that it worked out of the box for Centos 7.3.1611x64 just copy and pasting all the steps into terminal
https://trac.ffmpeg.org/wiki/CompilationGuide/Centos
The guide is a little out of date as of the time of this post, you do need to install Yasm in order to make libvpx (they say to skip yasm now), and:
http://downloads.xiph.org/releases/
is now redirecting to:
https://ftp.osuosl.org/pub/xiph/releases/
So you have to update those urls under the libogg and libvorbis sections appropriately.
I also had to install yum-utils to get access to yum-config-manger.
Other than that it worked out of the box for Centos 7.3.1611x64 just copy and pasting all the steps into terminal