Unknown encoder 'libx264'

后端 未结 3 2049
梦毁少年i
梦毁少年i 2020-12-07 10:14

I installed ffmpeg 0.8.9 on ubuntu11 by

./configure --enable-gpl --enable-nonfree --enable-pthreads --enable-libfaac --enable-libmp3lame --enable-l

3条回答
  •  暖寄归人
    2020-12-07 11:08

    start by installing these libraries

    sudo apt-get install libfdk-aac-dev libass-dev libopus-dev  \
    libtheora-dev libvorbis-dev libvpx-dev libssl-dev
    

    For Ubuntu 20.04 issue

    sudo apt-get install nasm
    

    and hop over this manual nasm install ... yet as of Ubuntu 17.04 sudo apt-get install nasm does not supply a new enough nasm so install that manually

    get source for nasm at http://www.nasm.us/pub/nasm/releasebuilds/?C=M;O=D download the latest then

    cd ~/src/nasm-2.13.02  #  update to release you just downloaded
    ./configure
    make -j $(nproc)
    sudo make install
    

    Then for x264 :

    git clone https://code.videolan.org/videolan/x264.git
    cd x264
    ./configure --enable-static --enable-shared
    make -j $(nproc)
    sudo make install
    

    For mp3 get LAME (libmp3lame)

    sudo apt-get install libmp3lame-dev
    

    or install manually from http://lame.sourceforge.net/ version v3.100, then give it the normal

    cd lame-3.100/
    ./configure
    make -j $(nproc)
    sudo make install
    

    Finally download ffmpeg source and do install :

    git clone git://source.ffmpeg.org/ffmpeg.git
    cd ffmpeg
    
    ./configure  --enable-gpl   --enable-libass   --enable-libfdk-aac   --enable-libfreetype   --enable-libmp3lame   --enable-libopus   --enable-libtheora   --enable-libvorbis   --enable-libvpx   --enable-libx264   --enable-nonfree --enable-shared --enable-openssl   
    
    make -j $(nproc)
    sudo make install
    

    I feel your pain, but this works - still valid on Ubuntu 18.10

提交回复
热议问题