How to Install ffmpeg with libx264 in ubuntu 12.04/14.04

How to Install ffmpeg with libx264 in ubuntu 12.04/14.04

FFMPEG

ffmpeg is a multimedia framework that suppport many media file. Able to decode, encode, transcode, mux, demux, stream, filter and play pretty much anything that humans and machines have created.

libx264

free software library and application for encoding video streams into the H.264/MPEG-4 AVC compression format, and is released under the terms of the GNU GPL.

fdk-aac

FDK AAC is an open-source software library for encoding and decoding Advanced Audio Coding (AAC) format audio.

Now i just share about ffmpeg "How to Install ffmpeg with libx264 in ubuntu 12.04/14.04". i am use ubuntu 12.04 and i was do it too in my ubuntu 14.04 and its work fine :)

all we need is just install this all :
  1. yasm
  2. libx264
  3. fdk-aac
  4. ffmpeg
before we install all it, we need to remove old package of ffmpeg and others :
apt-get remove -y ffmpeg x264 libav-tools yasm && apt-get autoremove
Now begin to installation

Step 1 - Install the package needed.
sudo apt-get update && sudo apt-get install -y autoconf automake build-essential git libass-dev libfaac-dev libgpac-dev libmp3lame-dev libopus-dev libtheora-dev libtool libvorbis-dev libvpx-dev pkg-config texi2html zlib1g-dev python-dev cython
Step 2 - Setup directory installation and compilation :
cd /usr/local/src/
mkdir ffmpeg_sources
cd ffmpeg_sources
Step 3 - Install yasm, available version is 1.2.0, Download and compile yasm :

wget http://www.tortall.net/projects/yasm/releases/yasm-1.2.0.tar.gz
tar -xvf yasm-1.2.0.tar.gz
cd yasm-1.2.0
./configure --prefix="/usr/local/src/ffmpeg_build" --bindir="/usr/local/bin" --enable-python-bindings
make && make install && make distclean
cd ..
Step 4 - Install libx264 for Video encoder.

git clone --depth 1 git://git.videolan.org/x264.git
cd x264
./configure --prefix="/usr/local/src/ffmpeg_build" --bindir="/usr/local/bin" --enable-static
make && make install && make distclean
cd ..
Step 5 - Install fdk-aac for Audio encoder :

git clone --depth 1 git://github.com/mstorsjo/fdk-aac.git
cd fdk-aac
autoreconf -fiv
./configure --prefix="/usr/local/src/ffmpeg_build" --bindir="/usr/local/bin" --disable-shared
make && make install && make distclean
cd ..
Step 6 - The last Install ffmpeg and enale libx264 and fdk-aac :

git clone --depth 1 git://source.ffmpeg.org/ffmpeg
cd ffmpeg
./configure --prefix="/usr/local/src/ffmpeg_build" --extra-cflags="-I/usr/local/src/ffmpeg_build/include" \
  --extra-ldflags="-L/usr/local/src/ffmpeg_build/lib" --bindir="/usr/local/bin" --extra-libs="-ldl" --enable-gpl \
  --enable-libass --enable-libfaac --enable-libfdk-aac --enable-libmp3lame --enable-libopus --enable-postproc \
  --enable-libtheora --enable-libvorbis --enable-libvpx --enable-libx264 --enable-nonfree && \
make
make install
make distclean
hash -r
cd ..
Oke Fnish all and done. Now just try ffmpeg and happy encoding.

this is my :

How to Install ffmpeg with libx264 in ubuntu 12.04/14.04

Oke see next time and will give about "How to encode a video with ffmpeg"
Title : How to Install ffmpeg with libx264 in ubuntu 12.04/14.04
Description : FFMPEG ffmpeg is a multimedia framework that suppport many media file. Able to decode, encode, transcode, mux, demux, stream, filter a...

0 Response to "How to Install ffmpeg with libx264 in ubuntu 12.04/14.04"

Post a Comment