centos6.5 under compile and install FFmpeg

Source: Internet
Author: User

The following installation steps are basically from the official website, make a note to facilitate your own later view

Http://trac.ffmpeg.org/wiki/CompilationGuide

1. Installing dependent Packages

[Python]View Plaincopyprint?
    1. <span style="FONT-SIZE:14PX;" >yum install autoconf automake gcc gcc-c++ git libtool make nasm pkgconfig zlib-devel</span>

2. New folder to store the source code

mkdir ~/ffmpeg_sources

3. Compile & Install

Yasm

Yasm is a assembler used by x264 and FFmpeg.

[Python]View Plaincopyprint?
    1. CD ~/ffmpeg_sources
    2. Curl-o http://www.tortall.net/projects/yasm/releases/yasm-1.2. 0.tar.gz
    3. Tar xzvf yasm-1.2. 0.tar.gz
    4. CD yasm-1.2. 0
    5. ./configure--prefix="$HOME/ffmpeg_build"--bindir="$HOME/bin"
    6. Make
    7. Make install
    8. Make Distclean
    9. Export "path= $PATH: $HOME/bin"

libx264

H. Video Encoder.

[Python]View Plaincopyprint?
    1. CD ~/ffmpeg_sources
    2. git clone--depth 1 git://git.videolan.org/x264
    3. CD x264
    4. ./configure--prefix="$HOME/ffmpeg_build"--bindir="$HOME/bin"--enable-static
    5. Make
    6. Make install
    7. Make Distclean

Libfdk_aac

AAC Audio Encoder.

[Python]View Plaincopyprint?
    1. CD ~/ffmpeg_sources
    2. git clone--depth 1 GIT://GIT.CODE.SF.NET/P/OPENCORE-AMR/FDK-AAC
    3. CD FDK-AAC
    4. Autoreconf-fiv
    5. ./configure--prefix="$HOME/ffmpeg_build"--disable-shared
    6. Make
    7. Make install
    8. Make Distclean

Libmp3lame

Opus Audio decoder and encoder.

[Python]View Plaincopyprint?
    1. CD ~/ffmpeg_sources
    2. Curl-o http://downloads.xiph.org/releases/opus/opus-1.1.tar.gz
    3. Tar xzvf opus-1.1.tar.gz
    4. CD opus-1.1
    5. ./configure--prefix="$HOME/ffmpeg_build"--disable-shared
    6. Make
    7. Make install
    8. Make Distclean

Libogg

Ogg Bitstream Library. Required by Libtheora and Libvorbis.

[Python]View Plaincopyprint?
    1. CD ~/ffmpeg_sources
    2. Curl-o http://downloads.xiph.org/releases/ogg/libogg-1.3. 1.tar.gz
    3. Tar xzvf libogg-1.3. 1.tar.gz
    4. CD libogg-1.3. 1
    5. ./configure--prefix="$HOME/ffmpeg_build"--disable-shared
    6. Make
    7. Make install
    8. Make Distclean

Libvorbis

Vorbis Audio Encoder. Requires Libogg.

[Python]View Plaincopyprint?
    1. CD ~/ffmpeg_sources
    2. Curl-o http://downloads.xiph.org/releases/vorbis/libvorbis-1.3. 4.tar.gz
    3. Tar xzvf libvorbis-1.3. 4.tar.gz
    4. CD libvorbis-1.3. 4
    5. ./configure--prefix="$HOME/ffmpeg_build"--with-ogg="$HOME/ffmpeg_build"--disable-shared
    6. Make
    7. Make install
    8. Make Distclean

Libvpx

VP8/VP9 Video Encoder.

[Python]View Plaincopyprint?
    1. CD ~/ffmpeg_sources
    2. git clone--depth 1 https://chromium.googlesource.com/webm/libvpx.git
    3. CD LIBVPX
    4. ./configure--prefix="$HOME/ffmpeg_build"--disable-examples
    5. Make
    6. Make install
    7. Make clean

Note: Because the country recently unable to access Google so libvpx cannot git clone, at this time can go elsewhere to download: Http://yunpan.cn/QhNk5tDqQV3MM access password 45f6

Ffmpeg
CD ~/ffmpeg_sourcesgit clone--depth 1 git://source.ffmpeg.org/ffmpegcd ffmpegpkg_config_path= "$HOME/ffmpeg_build/ Lib/pkgconfig "Export pkg_config_path./configure--prefix=" $HOME/ffmpeg_build "--extra-cflags="-I$HOME/ffmpeg_ Build/include "--extra-ldflags="-l$home/ffmpeg_build/lib "--bindir=" $HOME/bin "--EXTRA-LIBS=-LDL--ENABLE-GPL-- Enable-nonfree--enable-libfdk_aac--enable-libmp3lame--enable-libopus--enable-libvorbis--enable-libvpx-- Enable-libx264makemake installmake distcleanhash-r. ~/.bash_profile

End of Installation view version:

centos6.5 under compile and install FFmpeg

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.