zoukankan      html  css  js  c++  java
  • 源码安装ffmpeg(带libx264)

    环境:CentOS6.2_64

    1、下载源码包

    wget ftp://ftp.videolan.org/pub/x264/snapshots/x264-snapshot-20120718-2245-stable.tar.bz2

    解压:tar jxvf x264-snapshot-20120718-2245-stable.tar.bz2

    wget http://ffmpeg.org/releases/ffmpeg-0.11.1.tar.gz

    解压:tar zxvf ffmpeg-0.11.1.tar.gz

    2、安装x264

    2.1 安装依赖包

    缺少yasm

    安装:yum install yasm -y

    2.2 安装x264

    ./configure --prefix=/usr --enable-shared && make && make install

    重新加载配置:ldconfig

    3、安装ffmpeg

    ffplay必须依赖于sdl

    yum install SDL -y

    安装:

    ./configure --enable-libx264 --enable-gpl && make && make install
    附(自动安装脚本):

    #! /bin/bash
    
    echo "Install yasm  ..."
    yum install yasm SDL* gtk+* -y
    
    echo "Install libx264 ..."
    wget ftp://ftp.videolan.org/pub/x264/snapshots/x264-snapshot-20120718-2245-stable.tar.bz2
    tar jxvf x264-snapshot-20120718-2245-stable.tar.bz2
    cd x264-snapshot-20120718-2245-stable
    ./configure --enable-shared && make && make install
    ldconfig
    
    echo "Install ffmpeg ..."
    cd ..
    wget http://ffmpeg.org/releases/ffmpeg-0.11.1.tar.gz
    tar zxvf ffmpeg-0.11.1.tar.gz
    cd ffmpeg-0.11.1
    ./configure --enable-libx264 --enable-gpl && make && make install
  • E-Mail : Mike_Zhang@live.com
  • 转载请注明出处,谢谢!
查看全文
  • 相关阅读:
    简单的HelloWorld
    jsp获取绝对路径
    EasyUI validType属性
    Django meida(admin后台上传图片并可访问)
    postgresql char 与 varchar的区别
    git pull 源成分支遇到“There is no tracking information for the current branch.”错误
    Centos安装Pillow模块出错解决办法
    centos7网络配置
    表格排序插件tablesorter的初步使用介绍
    linux编译安装指定版本的python
  • 原文地址:https://www.cnblogs.com/MikeZhang/p/installFFmpegFromSourceCode.html
  • Copyright © 2011-2022 走看看