精华内容
下载资源
问答
  • ffmpeg编译静态库
    2021-04-16 19:28:38

    网上查到的大多数都是android ndk与ffmpeg进行编译,想要c/c++库在c/c++环境调式,请执行以下命令:

    # $HOME/ffmpeg-build是库输出目录
    ./configure --prefix="$HOME/ffmpeg-build" --bindir="$HOME/bin"
    
    make -j 8
    make install

     

    编译后得到.a静态库

    更多相关内容
  • Ubuntu16.04 环境下编译ffmpeg生成静态库和共享库基本上按照这个步骤编Compile FFmpeg on Ubuntu,Debian,or MintGet the Dependenciessudo apt-get updatesudo apt-get -y install autoconf automake build-...

    Ubuntu16.04 环境下编译ffmpeg生成静态库和共享库

    基本上按照这个步骤编

    Compile FFmpeg on Ubuntu,Debian,or Mint

    Get the Dependencies

    sudo apt-get update

    sudo apt-get -y install autoconf automake build-essential libass-dev libfreetype6-dev

    libsdl2-dev libtheora-dev libtool libva-dev libvdpau-dev libvorbis-dev libxcb1-dev libxcb-shm0-dev

    libxcb-xfixes0-dev pkg-config texinfo wget zlib1g-dev

    Compilation & Installation

    mkdir ~/ffmpeg_sources

    任意指定一个目录即可

    Yasm

    强烈推荐使用,不然会编得很慢

    An assembler for x86 optimizations used by x264 and FFmpeg. Highly recommended or your resulting build may be very slow.

    If your repository provides yasm version ≥ 1.2.0 then you can install that instead of compiling:

    sudo apt-get install yasm

    cd ~/ffmpeg_sources

    wget http://www.tortall.net/projects/yasm/releases/yasm-1.3.0.tar.gz

    tar xzvf yasm-1.3.0.tar.gz

    cd yasm-1.3.0

    ./configure --prefix="$HOME/ffmpeg_build" --bindir="$HOME/bin"

    make

    make install

    nasm

    使用x264的话就需要

    NASM assembler. Required for compilation of x264 and other tools.

    cd ~/ffmpeg_sources

    wget http://www.nasm.us/pub/nasm/releasebuilds/2.13.01/nasm-2.13.01.tar.bz2

    tar xjvf nasm-2.13.01.tar.bz2

    cd nasm-2.13.01

    ./autogen.sh

    PATH="$HOME/bin:$PATH" ./configure --prefix="$HOME/ffmpeg_build" --bindir="$HOME/bin"

    PATH="$HOME/bin:$PATH" make

    make install

    libx264

    H.264 video encoder. See the H.264 Encoding Guide for more information and usage examples.

    Requires ffmpeg to be configured with –enable-gpl –enable-libx264.

    If your repository provides libx264-dev version ≥ 118 then you can install that instead of compiling:

    sudo apt-get install libx264-dev

    cd ~/ffmpeg_sources

    wget http://download.videolan.org/pub/x264/snapshots/last_x264.tar.bz2

    tar xjvf last_x264.tar.bz2

    cd x264-snapshot*

    PATH="$HOME/bin:$PATH" ./configure --prefix="$HOME/ffmpeg_build" --bindir="$HOME/bin" --enable-static --disable-opencl

    PATH="$HOME/bin:$PATH" make

    make install

    以下的库有选择地安装吧,有些音频的库用不到,都安装也可以,注意看英文说明,哪个需要在运行configure文件的时候,enable一下

    libx265

    H.265/HEVC video encoder. See the H.265 Encoding Guide for more information and usage examples.

    If your repository provides libx265-dev version ≥ 68 then you can install that instead of compiling:

    sudo apt-get install libx265-dev

    sudo apt-get install cmake mercurial

    cd ~/ffmpeg_sources

    hg clone https://bitbucket.org/multicoreware/x265

    cd ~/ffmpeg_sources/x265/build/linux

    PATH="$HOME/bin:$PATH" cmake -G "Unix Makefiles" -DCMAKE_INSTALL_PREFIX="$HOME/ffmpeg_build" -DENABLE_SHARED:bool=off ../../source

    make

    make install

    libfdk-aac

    AAC audio encoder. See the AAC Audio Encoding Guide for more information and usage examples.

    Requires ffmpeg to be configured with –enable-libfdk-aac (and –enable-nonfree if you also included –enable-gpl).

    If your repository provides libfdk-aac-dev then you can install that instead of compiling:

    sudo apt-get install libfdk-aac-dev

    cd ~/ffmpeg_sources

    wget -O fdk-aac.tar.gz https://github.com/mstorsjo/fdk-aac/tarball/master

    tar xzvf fdk-aac.tar.gz

    cd mstorsjo-fdk-aac*

    autoreconf -fiv

    ./configure --prefix="$HOME/ffmpeg_build" --disable-shared

    make

    make install

    libmp3lame

    MP3 audio encoder.

    Requires ffmpeg to be configured with –enable-libmp3lame.

    If your repository provides libmp3lame-dev version ≥ 3.98.3 then you can install that instead of compiling:

    sudo apt-get install libmp3lame-dev

    cd ~/ffmpeg_sources

    wget http://downloads.sourceforge.net/project/lame/lame/3.99/lame-3.99.5.tar.gz

    tar xzvf lame-3.99.5.tar.gz

    cd lame-3.99.5

    ./configure --prefix="$HOME/ffmpeg_build" --enable-nasm --disable-shared

    make

    make install

    libopus

    Opus audio decoder and encoder.

    Requires ffmpeg to be configured with –enable-libopus.

    If your repository provides libopus-dev version ≥ 1.1 then you can install that instead of compiling:

    sudo apt-get install libopus-dev

    cd ~/ffmpeg_sources

    wget https://archive.mozilla.org/pub/opus/opus-1.1.5.tar.gz

    tar xzvf opus-1.1.5.tar.gz

    cd opus-1.1.5

    ./configure --prefix="$HOME/ffmpeg_build" --disable-shared

    make

    make install

    libvpx

    VP8/VP9 video encoder and decoder. See the VP8 Video Encoding Guide for more information and usage examples.

    Requires ffmpeg to be configured with –enable-libvpx.

    If your repository provides libvpx-dev version ≥ 0.9.7 then you can install that instead of compiling:

    sudo apt-get install libvpx-dev

    sudo apt-get install git

    cd ~/ffmpeg_sources

    git clone --depth 1 https://chromium.googlesource.com/webm/libvpx.git

    cd libvpx

    PATH="$HOME/bin:$PATH" ./configure --prefix="$HOME/ffmpeg_build" --disable-examples --disable-unit-tests

    PATH="$HOME/bin:$PATH" make

    make install

    最后,ffmpeg

    cd ~/ffmpeg_sources

    wget http://ffmpeg.org/releases/ffmpeg-snapshot.tar.bz2

    tar xjvf ffmpeg-snapshot.tar.bz2

    cd ffmpeg

    PATH="$HOME/bin:$PATH" PKG_CONFIG_PATH="$HOME/ffmpeg_build/lib/pkgconfig"

    在解压后的ffmpeg目录下面有configure文件,打开或者运行./configure –help可看到使用说明,以下是官方文档中的配置,其中–pkg-config-flags=”–static”一句表明只生成静态库.a,若想生成共享库.so,或者都生成,参考文章最后的配置。

    ./configure

    --prefix="$HOME/ffmpeg_build" --pkg-config-flags="--static" --extra-cflags="-I$HOME/ffmpeg_build/include" --extra-ldflags="-L$HOME/ffmpeg_build/lib" --bindir="$HOME/bin" --enable-gpl --enable-libass --enable-libfdk-aac --enable-libfreetype --enable-libmp3lame --enable-libopus --enable-libtheora --enable-libvorbis --enable-libvpx --enable-libx264 --enable-libx265 --enable-nonfreePATH="$HOME/bin:$PATH" make

    make install

    hash -r

    只生成静态库.a:使用以上配置

    只生成共享库.so:

    删去–pkg-config-flags=”–static”一句

    使用–enable-shared –disable-static

    静态库.a和共享库.so都声称:

    删去–pkg-config-flags=”–static”一句

    仅使用–enable-shared(两条-)

    最终,在~/ffmpeg-build/lib目录下,可查看到生成的相关库。

    fe60dd665c802fa138f3d98847fb8ffe.png

    注:生成的.so有一些是.so.*形式的扩展名,如不想生成此种形式,需要修改configure文件。

    贴出网上的一种改法:

    将该文件中的如下四行:

    SLIBNAME_WITH_MAJOR=’(SLIBNAME).(LIBMAJOR)’

    LIB_INSTALL_EXTRA_CMD=’$$(RANLIB)”$(LIBDIR)/$(LIBNAME)”’

    SLIB_INSTALL_NAME=’$(SLIBNAME_WITH_VERSION)’

    SLIB_INSTALL_LINKS=’(SLIBNAMEWITHMAJOR)(SLIBNAME)’

    替换为:

    SLIBNAME_WITH_MAJOR=’(SLIBPREF)(FULLNAME)-(LIBMAJOR)(SLIBSUF)’

    LIB_INSTALL_EXTRA_CMD=’$$(RANLIB)”$(LIBDIR)/$(LIBNAME)”’

    SLIB_INSTALL_NAME=’$(SLIBNAME_WITH_MAJOR)’

    SLIB_INSTALL_LINKS=’$(SLIBNAME)’

    如果想撤销以上所有操作对你的系统造成的改变,使用以下命令

    rm -rf ~/ffmpeg_build ~/ffmpeg_sources

    ~/bin/{ffmpeg,ffprobe,ffplay,ffserver,x264,x265,nasm}

    sudo apt-get autoremove autoconf automake build-essential cmake libass-dev libfreetype6-dev

    libmp3lame-dev libopus-dev libsdl2-dev libtheora-dev libtool libva-dev libvdpau-dev

    libvorbis-dev libvpx-dev libx264-dev libxcb1-dev libxcb-shm0-dev ibxcb-xfixes0-dev mercurial texinfo zlib1g-dev

    sed -i '/ffmpeg_build/c' ~/.manpath

    hash -r

    更多内容请参考文章一开始贴出的官方文档网站。

    展开全文
  • Ubuntu ffmpeg编译静态库和共享库

    千次阅读 2017-07-09 20:10:20
    Ubuntu16.04 环境下编译ffmpeg生成静态库和共享库参考官方文档 https://trac.ffmpeg.org/wiki/CompilationGuide/Ubuntu#RevertingChangesMadebyThisGuide基本上按照这个步骤编Compile FFmpeg on Ubuntu,Debian,or ...

    Ubuntu16.04 环境下编译ffmpeg生成静态库和共享库

    参考官方文档
    https://trac.ffmpeg.org/wiki/CompilationGuide/Ubuntu#RevertingChangesMadebyThisGuide

    基本上按照这个步骤编

    Compile FFmpeg on Ubuntu,Debian,or Mint

    Get the Dependencies

    sudo apt-get update
    sudo apt-get -y install autoconf automake build-essential libass-dev libfreetype6-dev \
      libsdl2-dev libtheora-dev libtool libva-dev libvdpau-dev libvorbis-dev libxcb1-dev libxcb-shm0-dev \
      libxcb-xfixes0-dev pkg-config texinfo wget zlib1g-dev

    Compilation & Installation

    mkdir ~/ffmpeg_sources

    任意指定一个目录即可

    Yasm

    强烈推荐使用,不然会编得很慢
    An assembler for x86 optimizations used by x264 and FFmpeg. Highly recommended or your resulting build may be very slow.

    If your repository provides yasm version ≥ 1.2.0 then you can install that instead of compiling:

    sudo apt-get install yasm

    cd ~/ffmpeg_sources
    wget http://www.tortall.net/projects/yasm/releases/yasm-1.3.0.tar.gz
    tar xzvf yasm-1.3.0.tar.gz
    cd yasm-1.3.0
    ./configure --prefix="$HOME/ffmpeg_build" --bindir="$HOME/bin"
    make
    make install

    nasm

    使用x264的话就需要
    NASM assembler. Required for compilation of x264 and other tools.

    cd ~/ffmpeg_sources
    wget http://www.nasm.us/pub/nasm/releasebuilds/2.13.01/nasm-2.13.01.tar.bz2
    tar xjvf nasm-2.13.01.tar.bz2
    cd nasm-2.13.01
    ./autogen.sh
    PATH="$HOME/bin:$PATH" ./configure --prefix="$HOME/ffmpeg_build" --bindir="$HOME/bin"
    PATH="$HOME/bin:$PATH" make
    make install

    libx264

    H.264 video encoder. See the H.264 Encoding Guide for more information and usage examples.

    Requires ffmpeg to be configured with –enable-gpl –enable-libx264.

    If your repository provides libx264-dev version ≥ 118 then you can install that instead of compiling:

    sudo apt-get install libx264-dev

    cd ~/ffmpeg_sources
    wget http://download.videolan.org/pub/x264/snapshots/last_x264.tar.bz2
    tar xjvf last_x264.tar.bz2
    cd x264-snapshot*
    PATH="$HOME/bin:$PATH" ./configure --prefix="$HOME/ffmpeg_build" --bindir="$HOME/bin" --enable-static --disable-opencl
    PATH="$HOME/bin:$PATH" make
    make install

    以下的库有选择地安装吧,有些音频的库用不到,都安装也可以,注意看英文说明,哪个需要在运行configure文件的时候,enable一下

    libx265

    H.265/HEVC video encoder. See the H.265 Encoding Guide for more information and usage examples.

    If your repository provides libx265-dev version ≥ 68 then you can install that instead of compiling:

    sudo apt-get install libx265-dev

    sudo apt-get install cmake mercurial
    cd ~/ffmpeg_sources
    hg clone https://bitbucket.org/multicoreware/x265
    cd ~/ffmpeg_sources/x265/build/linux
    PATH="$HOME/bin:$PATH" cmake -G "Unix Makefiles" -DCMAKE_INSTALL_PREFIX="$HOME/ffmpeg_build" -DENABLE_SHARED:bool=off ../../source
    make
    make install

    libfdk-aac

    AAC audio encoder. See the AAC Audio Encoding Guide for more information and usage examples.

    Requires ffmpeg to be configured with –enable-libfdk-aac (and –enable-nonfree if you also included –enable-gpl).

    If your repository provides libfdk-aac-dev then you can install that instead of compiling:

    sudo apt-get install libfdk-aac-dev

    cd ~/ffmpeg_sources
    wget -O fdk-aac.tar.gz https://github.com/mstorsjo/fdk-aac/tarball/master
    tar xzvf fdk-aac.tar.gz
    cd mstorsjo-fdk-aac*
    autoreconf -fiv
    ./configure --prefix="$HOME/ffmpeg_build" --disable-shared
    make
    make install

    libmp3lame

    MP3 audio encoder.

    Requires ffmpeg to be configured with –enable-libmp3lame.

    If your repository provides libmp3lame-dev version ≥ 3.98.3 then you can install that instead of compiling:

    sudo apt-get install libmp3lame-dev

    cd ~/ffmpeg_sources
    wget http://downloads.sourceforge.net/project/lame/lame/3.99/lame-3.99.5.tar.gz
    tar xzvf lame-3.99.5.tar.gz
    cd lame-3.99.5
    ./configure --prefix="$HOME/ffmpeg_build" --enable-nasm --disable-shared
    make
    make install

    libopus

    Opus audio decoder and encoder.

    Requires ffmpeg to be configured with –enable-libopus.

    If your repository provides libopus-dev version ≥ 1.1 then you can install that instead of compiling:

    sudo apt-get install libopus-dev

    cd ~/ffmpeg_sources
    wget https://archive.mozilla.org/pub/opus/opus-1.1.5.tar.gz
    tar xzvf opus-1.1.5.tar.gz
    cd opus-1.1.5
    ./configure --prefix="$HOME/ffmpeg_build" --disable-shared
    make
    make install

    libvpx

    VP8/VP9 video encoder and decoder. See the VP8 Video Encoding Guide for more information and usage examples.

    Requires ffmpeg to be configured with –enable-libvpx.

    If your repository provides libvpx-dev version ≥ 0.9.7 then you can install that instead of compiling:

    sudo apt-get install libvpx-dev

    sudo apt-get install git
    cd ~/ffmpeg_sources
    git clone --depth 1 https://chromium.googlesource.com/webm/libvpx.git
    cd libvpx
    PATH="$HOME/bin:$PATH" ./configure --prefix="$HOME/ffmpeg_build" --disable-examples --disable-unit-tests
    PATH="$HOME/bin:$PATH" make
    make install

    最后,ffmpeg

    cd ~/ffmpeg_sources
    wget http://ffmpeg.org/releases/ffmpeg-snapshot.tar.bz2
    tar xjvf ffmpeg-snapshot.tar.bz2
    cd ffmpeg
    PATH="$HOME/bin:$PATH" PKG_CONFIG_PATH="$HOME/ffmpeg_build/lib/pkgconfig" 

    在解压后的ffmpeg目录下面有configure文件,打开或者运行./configure –help可看到使用说明,以下是官方文档中的配置,其中–pkg-config-flags=”–static”一句表明只生成静态库.a,若想生成共享库.so,或者都生成,参考文章最后的配置。

    ./configure \
      --prefix="$HOME/ffmpeg_build" \
      --pkg-config-flags="--static" \
      --extra-cflags="-I$HOME/ffmpeg_build/include" \
      --extra-ldflags="-L$HOME/ffmpeg_build/lib" \
      --bindir="$HOME/bin" \
      --enable-gpl \
      --enable-libass \
      --enable-libfdk-aac \
      --enable-libfreetype \
      --enable-libmp3lame \
      --enable-libopus \
      --enable-libtheora \
      --enable-libvorbis \
      --enable-libvpx \
      --enable-libx264 \
      --enable-libx265 \
      --enable-nonfree
    PATH="$HOME/bin:$PATH" make
    make install
    hash -r

    只生成静态库.a:使用以上配置
    只生成共享库.so:
    删去–pkg-config-flags=”–static”一句
    使用–enable-shared –disable-static
    静态库.a和共享库.so都声称:
    删去–pkg-config-flags=”–static”一句
    仅使用–enable-shared(两条-)

    最终,在~/ffmpeg-build/lib目录下,可查看到生成的相关库。
    这里写图片描述
    注:生成的.so有一些是.so.*形式的扩展名,如不想生成此种形式,需要修改configure文件。
    贴出网上的一种改法:
    将该文件中的如下四行:

    SLIBNAME_WITH_MAJOR=’ (SLIBNAME). (LIBMAJOR)’

    LIB_INSTALL_EXTRA_CMD=’$$(RANLIB)”$(LIBDIR)/$(LIBNAME)”’

    SLIB_INSTALL_NAME=’$(SLIBNAME_WITH_VERSION)’

    SLIB_INSTALL_LINKS=’ (SLIBNAMEWITHMAJOR) (SLIBNAME)’

    替换为:

    SLIBNAME_WITH_MAJOR=’ (SLIBPREF) (FULLNAME)- (LIBMAJOR) (SLIBSUF)’

    LIB_INSTALL_EXTRA_CMD=’$$(RANLIB)”$(LIBDIR)/$(LIBNAME)”’

    SLIB_INSTALL_NAME=’$(SLIBNAME_WITH_MAJOR)’

    SLIB_INSTALL_LINKS=’$(SLIBNAME)’

    如果想撤销以上所有操作对你的系统造成的改变,使用以下命令

     rm -rf ~/ffmpeg_build ~/ffmpeg_sources 
     ~/bin/{ffmpeg,ffprobe,ffplay,ffserver,x264,x265,nasm}
    sudo apt-get autoremove autoconf automake build-essential cmake libass-dev libfreetype6-dev \
      libmp3lame-dev libopus-dev libsdl2-dev libtheora-dev libtool libva-dev libvdpau-dev \
      libvorbis-dev libvpx-dev libx264-dev libxcb1-dev libxcb-shm0-dev ibxcb-xfixes0-dev mercurial texinfo zlib1g-dev
    sed -i '/ffmpeg_build/c\' ~/.manpath
    hash -r

    更多内容请参考文章一开始贴出的官方文档网站。

    展开全文
  • 该文件下包含FFmpeg静态库编译脚本文件ffmpeg-build.sh 以及 gas-preprocessor.pl 和源码下载的可执行脚本ffmpeg-download.sh
  • ubuntu20.04 可直接使用的ffmpeg静态编译) built with gcc 9 (Ubuntu 9.3.0-17ubuntu1~20.04) configuration: --prefix=/root/ffmpeg_build --pkg-config-flags=--static --extra-cflags=-I/root/ffmpeg_build/...
  • 使用ffmpeg2.7按照网上教程编译的,作者没有给出库,我编译分享一下. 仅仅收一分体现一下其本身的价值.
  • FFmpeg是一套可以用来记录、转换数字音频、视频,并能将其转化为流的开源计算机程序。采用LGPL或GPL许可证。...FFmpeg在Linux平台下开发,但它同样也可以在其它操作系统环境中编译运行,包括Windows...

    FFmpeg是一套可以用来记录、转换数字音频、视频,并能将其转化为流的开源计算机程序。采用LGPL或GPL许可证。它提供了录制、转换以及流化音视频的完整解决方案。它包含了非常先进的音频/视频编解码库libavcodec,为了保证高可移植性和编解码质量,libavcodec里很多code都是从头开发的。

    FFmpeg在Linux平台下开发,但它同样也可以在其它操作系统环境中编译运行,包括Windows、Mac OS X等。这个项目最早由Fabrice Bellard发起,2004年至2015年间由Michael Niedermayer主要负责维护。许多FFmpeg的开发人员都来自MPlayer项目,而且当前FFmpeg也是放在MPlayer项目组的服务器上。项目的名称来自MPEG视频编码标准,前面的"FF"代表"Fast Forward"。

    使用Shell脚本语言编译音视频.a静态库

    第一步:下载音视频框架

    网上下载,非常简单

    通过Shell脚本下载音视频框架

    脚本代码

    #!/bin/bash

    #库名称

    source="ffmpeg-3.4"

    #下载这个库

    if [ ! -r $source ]

    then

    #没有下载,那么执行下载操作

    echo "没有FFmpeg库, 我们需要下载。。。。。。"

    #下载

    curl http://ffmpeg.org/releases/${source}.tar.bz2 | tar xj || exit 1

    fi

    'curl'命令:它可以通过http/ftp等这样的网络方式下载和上传文件(一个强大网络工具),

    基本格式:curl 地址

    ${source}.tar.bz2:制定下载版本

    tar:表示解压和压缩,语法:tar options,例如:tar xj (x表示解压文件选项,j表示需要解压bz2压缩包)

    第二步:查看FFmpeg音视频编译配置选项

    1、查看选项

    进入FFmpeg框架包中

    执行命令查看配置 ./configure --help

    Help options:

    --help print this message

    --quiet Suppress showing informative output

    --list-decoders show all available decoders

    --list-encoders show all available encoders

    --list-hwaccels show all available hardware accelerators

    --list-demuxers show all available demuxers

    --list-muxers show all available muxers

    --list-parsers show all available parsers

    --list-protocols show all available protocols

    --list-bsfs show all available bitstream filters

    --list-indevs show all available input devices

    --list-outdevs show all available output devices

    --list-filters show all available filters

    Standard options:

    --logfile=FILE log tests and output to FILE [ffbuild/config.log]

    --disable-logging do not log configure debug information

    --fatal-warnings fail if any configure warning is generated

    --prefix=PREFIX install in PREFIX [/usr/local]

    --bindir=DIR install binaries in DIR [PREFIX/bin]

    --datadir=DIR install data files in DIR [PREFIX/share/ffmpeg]

    --docdir=DIR install documentation in DIR [PREFIX/share/doc/ffmpeg]

    --libdir=DIR install libs in DIR [PREFIX/lib]

    --shlibdir=DIR install shared libs in DIR [LIBDIR]

    --incdir=DIR install includes in DIR [PREFIX/include]

    --mandir=DIR install man page in DIR [PREFIX/share/man]

    --pkgconfigdir=DIR install pkg-config files in DIR [LIBDIR/pkgconfig]

    --enable-rpath use rpath to allow installing libraries in paths

    not part of the dynamic linker search path

    use rpath when linking programs (USE WITH CARE)

    --install-name-dir=DIR Darwin directory name for installed targets

    Licensing options:

    --enable-gpl allow use of GPL code, the resulting libs

    and binaries will be under GPL [no]

    --enable-version3 upgrade (L)GPL to version 3 [no]

    --enable-nonfree allow use of nonfree code, the resulting libs

    and binaries will be unredistributable [no]

    Configuration options:

    --disable-static do not build static libraries [no]

    --enable-shared build shared libraries [no]

    --enable-small optimize for size instead of speed

    --disable-runtime-cpudetect disable detecting CPU capabilities at runtime (smaller binary)

    --enable-gray enable full grayscale support (slower color)

    --disable-swscale-alpha disable alpha channel support in swscale

    --disable-all disable building components, libraries and programs

    --disable-autodetect disable automatically detected external libraries [no]

    Program options:

    --disable-programs do not build command line programs

    --disable-ffmpeg disable ffmpeg build

    --disable-ffplay disable ffplay build

    --disable-ffprobe disable ffprobe build

    --disable-ffserver disable ffserver build

    Documentation options:

    --disable-doc do not build documentation

    --disable-htmlpages do not build HTML documentation pages

    --disable-manpages do not build man documentation pages

    --disable-podpages do not build POD documentation pages

    --disable-txtpages do not build text documentation pages

    Component options:

    --disable-avdevice disable libavdevice build

    --disable-avcodec disable libavcodec build

    --disable-avformat disable libavformat build

    --disable-swresample disable libswresample build

    --disable-swscale disable libswscale build

    --disable-postproc disable libpostproc build

    --disable-avfilter disable libavfilter build

    --enable-avresample enable libavresample build [no]

    --disable-pthreads disable pthreads [autodetect]

    --disable-w32threads disable Win32 threads [autodetect]

    --disable-os2threads disable OS/2 threads [autodetect]

    --disable-network disable network support [no]

    --disable-dct disable DCT code

    --disable-dwt disable DWT code

    --disable-error-resilience disable error resilience code

    --disable-lsp disable LSP code

    --disable-lzo disable LZO decoder code

    --disable-mdct disable MDCT code

    --disable-rdft disable RDFT code

    --disable-fft disable FFT code

    --disable-faan disable floating point AAN (I)DCT code

    --disable-pixelutils disable pixel utils in libavutil

    Individual component options:

    --disable-everything disable all components listed below

    --disable-encoder=NAME disable encoder NAME

    --enable-encoder=NAME enable encoder NAME

    --disable-encoders disable all encoders

    --disable-decoder=NAME disable decoder NAME

    --enable-decoder=NAME enable decoder NAME

    --disable-decoders disable all decoders

    --disable-hwaccel=NAME disable hwaccel NAME

    --enable-hwaccel=NAME enable hwaccel NAME

    --disable-hwaccels disable all hwaccels

    --disable-muxer=NAME disable muxer NAME

    --enable-muxer=NAME enable muxer NAME

    --disable-muxers disable all muxers

    --disable-demuxer=NAME disable demuxer NAME

    --enable-demuxer=NAME enable demuxer NAME

    --disable-demuxers disable all demuxers

    --enable-parser=NAME enable parser NAME

    --disable-parser=NAME disable parser NAME

    --disable-parsers disable all parsers

    --enable-bsf=NAME enable bitstream filter NAME

    --disable-bsf=NAME disable bitstream filter NAME

    --disable-bsfs disable all bitstream filters

    --enable-protocol=NAME enable protocol NAME

    --disable-protocol=NAME disable protocol NAME

    --disable-protocols disable all protocols

    --enable-indev=NAME enable input device NAME

    --disable-indev=NAME disable input device NAME

    --disable-indevs disable input devices

    --enable-outdev=NAME enable output device NAME

    --disable-outdev=NAME disable output device NAME

    --disable-outdevs disable output devices

    --disable-devices disable all devices

    --enable-filter=NAME enable filter NAME

    --disable-filter=NAME disable filter NAME

    --disable-filters disable all filters

    --disable-v4l2_m2m disable V4L2 mem2mem code [autodetect]

    External library support:

    Using any of the following switches will allow FFmpeg to link to the

    corresponding external library. All the components depending on that library

    will become enabled, if all their other dependencies are met and they are not

    explicitly disabled. E.g. --enable-libwavpack will enable linking to

    libwavpack and allow the libwavpack encoder to be built, unless it is

    specifically disabled with --disable-encoder=libwavpack.

    Note that only the system libraries are auto-detected. All the other external

    libraries must be explicitly enabled.

    Also note that the following help text describes the purpose of the libraries

    themselves, not all their features will necessarily be usable by FFmpeg.

    --disable-alsa disable ALSA support [autodetect]

    --disable-appkit disable Apple AppKit framework [autodetect]

    --disable-avfoundation disable Apple AVFoundation framework [autodetect]

    --enable-avisynth enable reading of AviSynth script files [no]

    --disable-bzlib disable bzlib [autodetect]

    --disable-coreimage disable Apple CoreImage framework [autodetect]

    --enable-chromaprint enable audio fingerprinting with chromaprint [no]

    --enable-frei0r enable frei0r video filtering [no]

    --enable-gcrypt enable gcrypt, needed for rtmp(t)e support

    if openssl, librtmp or gmp is not used [no]

    --enable-gmp enable gmp, needed for rtmp(t)e support

    if openssl or librtmp is not used [no]

    --enable-gnutls enable gnutls, needed for https support

    if openssl is not used [no]

    --disable-iconv disable iconv [autodetect]

    --disable-jack disable libjack support [autodetect]

    --enable-jni enable JNI support [no]

    --enable-ladspa enable LADSPA audio filtering [no]

    --enable-libass enable libass subtitles rendering,

    needed for subtitles and ass filter [no]

    --enable-libbluray enable BluRay reading using libbluray [no]

    --enable-libbs2b enable bs2b DSP library [no]

    --enable-libcaca enable textual display using libcaca [no]

    --enable-libcelt enable CELT decoding via libcelt [no]

    --enable-libcdio enable audio CD grabbing with libcdio [no]

    --enable-libdc1394 enable IIDC-1394 grabbing using libdc1394

    and libraw1394 [no]

    --enable-libfdk-aac enable AAC de/encoding via libfdk-aac [no]

    --enable-libflite enable flite (voice synthesis) support via libflite [no]

    --enable-libfontconfig enable libfontconfig, useful for drawtext filter [no]

    --enable-libfreetype enable libfreetype, needed for drawtext filter [no]

    --enable-libfribidi enable libfribidi, improves drawtext filter [no]

    --enable-libgme enable Game Music Emu via libgme [no]

    --enable-libgsm enable GSM de/encoding via libgsm [no]

    --enable-libiec61883 enable iec61883 via libiec61883 [no]

    --enable-libilbc enable iLBC de/encoding via libilbc [no]

    --enable-libkvazaar enable HEVC encoding via libkvazaar [no]

    --enable-libmodplug enable ModPlug via libmodplug [no]

    --enable-libmp3lame enable MP3 encoding via libmp3lame [no]

    --enable-libopencore-amrnb enable AMR-NB de/encoding via libopencore-amrnb [no]

    --enable-libopencore-amrwb enable AMR-WB decoding via libopencore-amrwb [no]

    --enable-libopencv enable video filtering via libopencv [no]

    --enable-libopenh264 enable H.264 encoding via OpenH264 [no]

    --enable-libopenjpeg enable JPEG 2000 de/encoding via OpenJPEG [no]

    --enable-libopenmpt enable decoding tracked files via libopenmpt [no]

    --enable-libopus enable Opus de/encoding via libopus [no]

    --enable-libpulse enable Pulseaudio input via libpulse [no]

    --enable-librsvg enable SVG rasterization via librsvg [no]

    --enable-librubberband enable rubberband needed for rubberband filter [no]

    --enable-librtmp enable RTMP[E] support via librtmp [no]

    --enable-libshine enable fixed-point MP3 encoding via libshine [no]

    --enable-libsmbclient enable Samba protocol via libsmbclient [no]

    --enable-libsnappy enable Snappy compression, needed for hap encoding [no]

    --enable-libsoxr enable Include libsoxr resampling [no]

    --enable-libspeex enable Speex de/encoding via libspeex [no]

    --enable-libssh enable SFTP protocol via libssh [no]

    --enable-libtesseract enable Tesseract, needed for ocr filter [no]

    --enable-libtheora enable Theora encoding via libtheora [no]

    --enable-libtwolame enable MP2 encoding via libtwolame [no]

    --enable-libv4l2 enable libv4l2/v4l-utils [no]

    --enable-libvidstab enable video stabilization using vid.stab [no]

    --enable-libvmaf enable vmaf filter via libvmaf [no]

    --enable-libvo-amrwbenc enable AMR-WB encoding via libvo-amrwbenc [no]

    --enable-libvorbis enable Vorbis en/decoding via libvorbis,

    native implementation exists [no]

    --enable-libvpx enable VP8 and VP9 de/encoding via libvpx [no]

    --enable-libwavpack enable wavpack encoding via libwavpack [no]

    --enable-libwebp enable WebP encoding via libwebp [no]

    --enable-libx264 enable H.264 encoding via x264 [no]

    --enable-libx265 enable HEVC encoding via x265 [no]

    --enable-libxavs enable AVS encoding via xavs [no]

    --enable-libxcb enable X11 grabbing using XCB [autodetect]

    --enable-libxcb-shm enable X11 grabbing shm communication [autodetect]

    --enable-libxcb-xfixes enable X11 grabbing mouse rendering [autodetect]

    --enable-libxcb-shape enable X11 grabbing shape rendering [autodetect]

    --enable-libxvid enable Xvid encoding via xvidcore,

    native MPEG-4/Xvid encoder exists [no]

    --enable-libxml2 enable XML parsing using the C library libxml2 [no]

    --enable-libzimg enable z.lib, needed for zscale filter [no]

    --enable-libzmq enable message passing via libzmq [no]

    --enable-libzvbi enable teletext support via libzvbi [no]

    --disable-lzma disable lzma [autodetect]

    --enable-decklink enable Blackmagic DeckLink I/O support [no]

    --enable-libndi_newtek enable Newteck NDI I/O support [no]

    --enable-mediacodec enable Android MediaCodec support [no]

    --enable-libmysofa enable libmysofa, needed for sofalizer filter [no]

    --enable-openal enable OpenAL 1.1 capture support [no]

    --enable-opencl enable OpenCL code

    --enable-opengl enable OpenGL rendering [no]

    --enable-openssl enable openssl, needed for https support

    if gnutls is not used [no]

    --disable-sndio disable sndio support [autodetect]

    --disable-schannel disable SChannel SSP, needed for TLS support on

    Windows if openssl and gnutls are not used [autodetect]

    --disable-sdl2 disable sdl2 [autodetect]

    --disable-securetransport disable Secure Transport, needed for TLS support

    on OSX if openssl and gnutls are not used [autodetect]

    --disable-xlib disable xlib [autodetect]

    --disable-zlib disable zlib [autodetect]

    The following libraries provide various hardware acceleration features:

    --disable-audiotoolbox disable Apple AudioToolbox code [autodetect]

    --disable-cuda disable dynamically linked Nvidia CUDA code [autodetect]

    --enable-cuda-sdk enable CUDA features that require the CUDA SDK [no]

    --disable-cuvid disable Nvidia CUVID support [autodetect]

    --disable-d3d11va disable Microsoft Direct3D 11 video acceleration code [autodetect]

    --disable-dxva2 disable Microsoft DirectX 9 video acceleration code [autodetect]

    --enable-libdrm enable DRM code (Linux) [no]

    --enable-libmfx enable Intel MediaSDK (AKA Quick Sync Video) code via libmfx [no]

    --enable-libnpp enable Nvidia Performance Primitives-based code [no]

    --enable-mmal enable Broadcom Multi-Media Abstraction Layer (Raspberry Pi) via MMAL [no]

    --disable-nvenc disable Nvidia video encoding code [autodetect]

    --enable-omx enable OpenMAX IL code [no]

    --enable-omx-rpi enable OpenMAX IL code for Raspberry Pi [no]

    --enable-rkmpp enable Rockchip Media Process Platform code [no]

    --disable-vaapi disable Video Acceleration API (mainly Unix/Intel) code [autodetect]

    --disable-vda disable Apple Video Decode Acceleration code [autodetect]

    --disable-vdpau disable Nvidia Video Decode and Presentation API for Unix code [autodetect]

    --disable-videotoolbox disable VideoToolbox code [autodetect]

    Toolchain options:

    --arch=ARCH select architecture []

    --cpu=CPU select the minimum required CPU (affects

    instruction selection, may crash on older CPUs)

    --cross-prefix=PREFIX use PREFIX for compilation tools []

    --progs-suffix=SUFFIX program name suffix []

    --enable-cross-compile assume a cross-compiler is used

    --sysroot=PATH root of cross-build tree

    --sysinclude=PATH location of cross-build system headers

    --target-os=OS compiler targets OS []

    --target-exec=CMD command to run executables on target

    --target-path=DIR path to view of build directory on target

    --target-samples=DIR path to samples directory on target

    --tempprefix=PATH force fixed dir/prefix instead of mktemp for checks

    --toolchain=NAME set tool defaults according to NAME

    --nm=NM use nm tool NM [nm -g]

    --ar=AR use archive tool AR [ar]

    --as=AS use assembler AS []

    --ln_s=LN_S use symbolic link tool LN_S [ln -s -f]

    --strip=STRIP use strip tool STRIP [strip]

    --windres=WINDRES use windows resource compiler WINDRES [windres]

    --x86asmexe=EXE use nasm-compatible assembler EXE [nasm]

    --cc=CC use C compiler CC [gcc]

    --cxx=CXX use C compiler CXX [g++]

    --objcc=OCC use ObjC compiler OCC [gcc]

    --dep-cc=DEPCC use dependency generator DEPCC [gcc]

    --nvcc=NVCC use Nvidia CUDA compiler NVCC [nvcc]

    --ld=LD use linker LD []

    --pkg-config=PKGCONFIG use pkg-config tool PKGCONFIG [pkg-config]

    --pkg-config-flags=FLAGS pass additional flags to pkgconf []

    --ranlib=RANLIB use ranlib RANLIB [ranlib]

    --doxygen=DOXYGEN use DOXYGEN to generate API doc [doxygen]

    --host-cc=HOSTCC use host C compiler HOSTCC

    --host-cflags=HCFLAGS use HCFLAGS when compiling for host

    --host-cppflags=HCPPFLAGS use HCPPFLAGS when compiling for host

    --host-ld=HOSTLD use host linker HOSTLD

    --host-ldflags=HLDFLAGS use HLDFLAGS when linking for host

    --host-libs=HLIBS use libs HLIBS when linking for host

    --host-os=OS compiler host OS []

    --extra-cflags=ECFLAGS add ECFLAGS to CFLAGS []

    --extra-cxxflags=ECFLAGS add ECFLAGS to CXXFLAGS []

    --extra-objcflags=FLAGS add FLAGS to OBJCFLAGS []

    --extra-ldflags=ELDFLAGS add ELDFLAGS to LDFLAGS []

    --extra-ldexeflags=ELDFLAGS add ELDFLAGS to LDEXEFLAGS []

    --extra-ldlibflags=ELDFLAGS add ELDFLAGS to LDLIBFLAGS []

    --extra-libs=ELIBS add ELIBS []

    --extra-version=STRING version string suffix []

    --optflags=OPTFLAGS override optimization-related compiler flags

    --nvccflags=NVCCFLAGS override nvcc flags [-gencode arch=compute_30,code=sm_30 -O2]

    --build-suffix=SUFFIX library name suffix []

    --enable-pic build position-independent code

    --enable-thumb compile for Thumb instruction set

    --enable-lto use link-time optimization

    --env="ENV=override" override the environment variables

    Advanced options (experts only):

    --malloc-prefix=PREFIX prefix malloc and related names with PREFIX

    --custom-allocator=NAME use a supported custom allocator

    --disable-symver disable symbol versioning

    --enable-hardcoded-tables use hardcoded tables instead of runtime generation

    --disable-safe-bitstream-reader

    disable buffer boundary checking in bitreaders

    (faster, but may crash)

    --sws-max-filter-size=N the max filter size swscale uses [256]

    Optimization options (experts only):

    --disable-asm disable all assembly optimizations

    --disable-altivec disable AltiVec optimizations

    --disable-vsx disable VSX optimizations

    --disable-power8 disable POWER8 optimizations

    --disable-amd3dnow disable 3DNow! optimizations

    --disable-amd3dnowext disable 3DNow! extended optimizations

    --disable-mmx disable MMX optimizations

    --disable-mmxext disable MMXEXT optimizations

    --disable-sse disable SSE optimizations

    --disable-sse2 disable SSE2 optimizations

    --disable-sse3 disable SSE3 optimizations

    --disable-ssse3 disable SSSE3 optimizations

    --disable-sse4 disable SSE4 optimizations

    --disable-sse42 disable SSE4.2 optimizations

    --disable-avx disable AVX optimizations

    --disable-xop disable XOP optimizations

    --disable-fma3 disable FMA3 optimizations

    --disable-fma4 disable FMA4 optimizations

    --disable-avx2 disable AVX2 optimizations

    --disable-aesni disable AESNI optimizations

    --disable-armv5te disable armv5te optimizations

    --disable-armv6 disable armv6 optimizations

    --disable-armv6t2 disable armv6t2 optimizations

    --disable-vfp disable VFP optimizations

    --disable-neon disable NEON optimizations

    --disable-inline-asm disable use of inline assembly

    --disable-x86asm disable use of standalone x86 assembly

    --disable-mipsdsp disable MIPS DSP ASE R1 optimizations

    --disable-mipsdspr2 disable MIPS DSP ASE R2 optimizations

    --disable-msa disable MSA optimizations

    --disable-mipsfpu disable floating point MIPS optimizations

    --disable-mmi disable Loongson SIMD optimizations

    --disable-fast-unaligned consider unaligned accesses slow

    Developer options (useful when working on FFmpeg itself):

    --disable-debug disable debugging symbols

    --enable-debug=LEVEL set the debug level []

    --disable-optimizations disable compiler optimizations

    --enable-extra-warnings enable more compiler warnings

    --disable-stripping disable stripping of executables and shared libraries

    --assert-level=level 0(default), 1 or 2, amount of assertion testing,

    2 causes a slowdown at runtime.

    --enable-memory-poisoning fill heap uninitialized allocated space with arbitrary data

    --valgrind=VALGRIND run "make fate" tests through valgrind to detect memory

    leaks and errors, using the specified valgrind binary.

    Cannot be combined with --target-exec

    --enable-ftrapv Trap arithmetic overflows

    --samples=PATH location of test samples for FATE, if not set use

    $FATE_SAMPLES at make invocation time.

    --enable-neon-clobber-test check NEON registers for clobbering (should be

    used only for debugging purposes)

    --enable-xmm-clobber-test check XMM registers for clobbering (Win64-only;

    should be used only for debugging purposes)

    --enable-random randomly enable/disable components

    --disable-random

    --enable-random=LIST randomly enable/disable specific components or

    --disable-random=LIST component groups. LIST is a comma-separated list

    of NAME[:PROB] entries where NAME is a component

    (group) and PROB the probability associated with

    NAME (default 0.5).

    --random-seed=VALUE seed value for --enable/disable-random

    --disable-valgrind-backtrace do not print a backtrace under Valgrind

    (only applies to --disable-optimizations builds)

    --enable-osfuzz Enable building fuzzer tool

    --libfuzzer=PATH path to libfuzzer

    --ignore-tests=TESTS comma-separated list (without "fate-" prefix

    in the name) of tests whose result is ignored

    --enable-linux-perf enable Linux Performance Monitor API

    NOTE: Object files are built at the place where configure is launched.

    90bd8439ec71

    帮助文档.png

    90bd8439ec71

    标准选项.png

    90bd8439ec71

    许可选项(侵权).png

    90bd8439ec71

    配置备选选项.png

    90bd8439ec71

    外部库支持.png

    90bd8439ec71

    工具链选项.png

    90bd8439ec71

    优化选项.png

    90bd8439ec71

    开发者选项.png

    第三步:编写脚本代码

    #!/bin/bash

    #1、定义库名称

    source="ffmpeg-3.4.2"

    #2、定义一个临时目录,用于保存.c/.h/.m文件编译后的.o文件

    cache="cache"

    #3、定义".a"静态库保存目录 pwd获取当前路径

    staticdir=`pwd`/"zrs-ffmpeg-iOS"

    #4、添加ffmpeg配置选项

    #交叉编译 --enable-cross-compile

    #禁止使用debug模式 --disable-debug

    #禁用程序 --disable-programs 不允许去建立一些命令行程序

    #不需要编译文档 --disable-doc

    #允许建立与我们位置无关的代码 --enable-pic(默认的)

    configure_flags="--enable-cross-compile --disable-debug --disable-programs --disable-doc --enable-pic"

    #5、定义默认的CPU平台架构类型

    #arm64 armv7 真机CUP架构类型

    #xb6_64 i38 模拟器

    archs="arm64 armv7 xb6_64 i386"

    #6、指定我们的这个库编译系统版本 ios7.0以及以上版本使用

    targetversion="7.0"

    #7、开始编译

    #y表示允许编译 n表示不允许编译

    #complie="y"

    #我是动态接受命令行输入CPU平台架构类型(传入参数)

    #如果存在外部指令就执行

    if [ "$*" ]

    then

    #存在输入参数,也就是说:外部指定需要编译cpu架构类型

    archs="$*"

    fi

    #8、安装汇编器-yasm

    #目的:通过软件管理器(Homebrew),然后下载安装(或者更新)我的汇编器

    #判断一下是否存在汇编器

    if [ ! `which yasm` ]

    then

    #Homebrew:软件管理器

    #下载一个软件管理器:安装、卸载、更新、搜索等等...

    #错误二:`which` brew

    #正确二:`which brew`

    if [ ! `which brew` ]

    then

    echo "安装brew"

    ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)" || exit 1

    fi

    echo "安装yasm"

    #成功了

    #下载安装这个汇编器

    #exit 1->安装失败了,那么退出程序

    brew install yasm || exit 1

    fi

    #9、循环编译静态库

    currentdir=`pwd`

    for arch in $archs

    do

    echo "开始编译。。。。。"

    #9.1创建目录

    #在编译结果目录下-创建对应平台架构类型

    mkdir -p "$cache/$arch"

    #9.2进入到当前目录下

    cd "$cache/$arch"

    #9.3配置编译器的cou架构类型 -制定当前编译cpu架构类型

    archflags="-arch $arch"

    #9.4判断是模拟器还是真机.a静态库

    if [ "$arch" = "i386" -o "$arch" = "xb6_64" ]

    then

    #模拟器

    platform="iPhoneSimulator"

    #支持最小系统版本-iOS 系统

    archflags="$archflags -mios-simulator-version-min=$targetversion"

    else

    #真机

    #支持最小系统版本-iOS 系统

    archflags="$archflags -mios-version-min=$targetversion -fembed-bitcode"

    #注意优化处理

    #如果架构类型是"arm64",那么

    if [ "$arch" = "arm64" ]

    then

    #GNU汇编器(GNU Assembler),简称为GAS

    #GASPP->汇编器预处理程序

    #解决问题:分段错误

    #通俗一点:就是程序运行时,变量访问越界一类的问题

    EXPORT="GASPP_FIX_XCODE5=1"

    fi

    fi

    #10、正式编译

    #tr命令可以对来自标准输入的字符进行替换、压缩和删除

    #'[:upper:]'->将小写转成大写

    #'[:lower:]'->将大写转成小写

    #将platform->转成大写或者小写

    echo "正式编译...."

    XCRUN_SDK=`echo $platform | tr '[:upper:]' '[:lower:]'`

    #编译器->编译平台

    CC="xcrun -sdk $XCRUN_SDK clang"

    #架构类型->arm64

    if [ "$arch" = "arm64" ]

    then

    #音视频默认一个编译命令

    #preprocessor.pl帮助我们编译FFmpeg->arm64位静态库

    AS="gas-preprocessor.pl -arch aarch64 -- $CC"

    else

    #默认编译平台

    AS="$CC"

    fi

    echo "执行到了1"

    #目录找到FFmepg编译源代码目录->设置编译配置->编译FFmpeg源码

    #--target-os:目标系统->darwin(mac系统早起版本名字)

    #darwin:是mac系统、iOS系统祖宗

    #--arch:CPU平台架构类型

    #--cc:指定编译器类型选项

    #--as:汇编程序

    #$configure_flags最初配置

    #--extra-cflags

    #--prefix:静态库输出目录

    TMPDIR=${TMPDIR/%\/} $currentdir/$source/configure \

    --target-os=darwin \

    --arch=$arch \

    --cc="$CC" \

    --as="$AS" \

    $configure_flags \

    --extra-cflags="$archflags" \

    --extra-ldflags="$archflags" \

    --prefix="$staticdir/$arch" \

    || exit 1

    echo "执行了"

    #解决问题->分段错误问题

    #安装->导出静态库(编译.a静态库)

    #执行命令

    make -j3 install $EXPORT || exit 1

    #回到了我们的脚本文件目录

    cd $currentdir

    done

    1、将文件gas-preprocessor.pl放入执行文件目录下

    2、执行文件 传入参数arm64 ./ffmpeg-build.sh arm64

    展开全文
  • 编译FFmpeg静态库

    千次阅读 2019-04-04 11:37:27
    ffmpeg是很好的开源工具,对做视频理解来说很有帮助,内部机制也很经典,经过优化后的ffmpeg...有时候,需要编译ffmpeg静态库,方便部署: ./configure --prefix=$FFMPEG_HOME--pkg-config-flags="--static" ...
  • 然而ffmpeg支持的依赖库很多,用命令行,一个命令写错就编译失败了,本篇博客介绍如何使用vs2019编译最新的ffmpeg源码,可以编译静态库、动态库,支持x64和win32版本,例如下面是我的vs2019 编译结果: ...
  • 在开发一款android平台下的视频播放器,底层解码选择用开源解码库Ffmpeg,需要编译生成静态库编译的环境:ubuntu 12.04 64bitandroid-ndk-r9d linux 64bit,下载地址:android ndk下载地址ffmpeg 0.6.7,下载地址...
  • Android FFmpeg 脚本编译静态库

    千次阅读 2020-03-08 19:53:07
    #!/bin/bash NDK_ROOT=/root/...#TOOLCHAIN 变量指向NDK中的交叉编译gcc所在的目录 #/root/android-ndk-r17c/toolchains/arm-linux-androideabi-4.9/prebuilt/linux-x86_64/bin #/root/android-ndk-r17c...
  • 采用emcc编译ffmpeg静态库,在开发前端网页视频播放器时,需要使用emcc编写C语言代码完成与前端接口对接。 2022/03/09 14:43 20,931,420 libavcodec.a 2022/03/09 14:43 24,122 libavdevice.a 2022/03/09 14:43 2,...
  • 资料包里包含了ffmpeg4.4,ffmpeg5.0的静态库。由emmc编译,可以编译成wasm文件由前端js调用,完成浏览器端的视频解码,转码等功能。 Linux下、windows 下均可调用。 与平台无关。 编译方法: emcc wasm_ffmpeg/...
  • windows编译FFmpeg静态库,搭建Android Studio的FFmpeg环境
  • 内容概要:Android平台使用的FFmpeg静态库版本4.4.2。支持RTP拉流 适用人群:Android平台做RTP拉流的开发人员。 其他说明:在网上没有找到android平台的FFmpeg库,就自己编译了一个,我用的事RTP拉流的功能,教程上...
  • ffmpeg 64位静态库编译

    千次阅读 2021-10-16 21:14:04
    ffmpeg 64位静态库编译 最近在用vs2017编译webrtc,发现webrtc官方不让用msvc编译器编译里面的ffmpeg,但是又需要用到ffmpeg,于是单独编译ffmpeg编译的是ffmpeg的动态库版本,然后在webrtc里面链接库和头文件。...
  • vs2012编译FFmpeg动态库和静态库包括头文件,里面还有详细的编译方法txt文档,授人予鱼不如授人予渔!
  • dll lib 头文件等 .a的静态库 FFMPEG】win10上编译FFmpeg-64位动态库教程 ...
  • 动态(共享)链接自是有诸多优于静态链接的特点:如能共享内存空间; 节约整个系统的存储空间,从而使整个系统速度提高; 当只有某个动态链接有更新时--便于维护--只用更新这个。但在有些情况下,如,服务器并...
  • OpenSSL 在windows10环境下用Visual Studio 2017编译成功的链接,包括32/64位的动/静态链接,共四个。
  • 1.首先,先有ffmpeg,然后需要另外的一个文件,gas-preprocessor.pl 所有的一切具备之后,下面让我们开始编译
  • 之前4月份的时候在公司没编译出来,直接用的别人编译好了的库做的开发,现在有时间了,花了半天的时间编译成功,包括Windows下.lib和.dll,使用Android NDK编译生成的静态库.a和动态库.so。, 傻瓜式安装,但是要自己...
  • 第一步×××通过git下载git clone https://git.ffmpeg.org/ffmpeg.git ffmpeg或者直接下载wget http://ffmpeg.org/releases/ffmpeg-3.3.tar.bz2如果是下载的ffmpeg-3.3.tar.bz2 需要进行解压tar -jxvf ffmpeg-3.3....
  • 基于ffmpeg2.6.9编译静态库 完整内容 支持h265/h264
  • ffmpeg动态静态库

    2020-07-03 14:37:34
    ffmpeg动态静态库
  • https://iodefog.github.io/https://iodefog.github.io/https://iodefog.github.io/https://iodefog.github.io/1.首先,先有ffmpeg...2.然后我在ffmpeg里建了一个文件夹,命名为armv...
  • 编译FFMpeg windows 静态库的基本方法。 下载msys2 请在 官网 查找并下载 安装msys2 没什么可说的,下一步下一步……OK。 配置vs环境 @echo off set MSYS2_PATH_TYPE=inherit call "C:\Program Files (x86)\...
  • android平台ffmpeg编译静态库正常,app使用编译好的静态库时报错: libavcodec/ffv1enc.c:476: error: undefined reference to 'log2' libavcodec/ffv1enc.c:476: error: undefined reference to 'log2' ...
  • 介绍及其他版本链接: https://github.com/FutaAlice/ffmpeg-static-libs https://blog.csdn.net/u014755412/article/details/82835387

空空如也

空空如也

1 2 3 4 5 ... 20
收藏数 8,046
精华内容 3,218
关键字:

ffmpeg编译静态库