系統版本centos7.6,內核3.10
-
依賴
pkg-config
地址: https://pkg-config.freedesktop.org/releases/
找一個最新的包,下載解壓
./configure
make
make check
make install
注:如果出現 glib-2.0>=2.16 這樣的錯誤,編譯時使用 ./configure --with-internal-glib
sdl
使用yum 安裝sdl,sdl2
libfdk_aac
下載aac,地址 https://sourceforge.net/projects/opencore-amr/files/fdk-aac/
./configure&&make&&make install
speex
yum install -y speex*
注:centos8好像需要源碼安裝,yum安裝後查看是否生產了執行文件。源碼下載 https://www.speex.org/downloads/
X264
git clone http://git.videolan.org/git/x264.git
./configure --enable-shared --enable-static --enable-debug
make & make install
編譯時可能會提示 Minimum version is nasm-2.13,那麼需要檢查nasm版本,重新安裝2.13及以上版本
wget https://www.nasm.us/pub/nasm/releasebuilds/2.14/nasm-2.14.tar.bz2 2020年6月最新版
./configure
make & make install
X265
http://ftp.videolan.org/pub/videolan/x265/
選擇最新版本x265_3.2.1.tar.gz
tar -xzf x265_3.2.1.tar.gz
$ cd x265/build/linux
$ ./make-Makefiles.bash
$ make && make install
-
下載安裝
Ffmpeg 下載地址 http://ffmpeg.org/download.html
注:如果網速可以,下載git版
./configure --prefix=/usr/local/ffmpeg --enable-gpl --enable-nonfree --enable-libfdk-aac --enable-libx264 --enable-libx265 --enable-filter=delogo --enable-debug --disable-optimizations --enable-libspeex --enable-shared --enable-pthreads
make
make install
如果依賴部分都安裝上了,則/usr/local/ffmpeg/bin下有三個文件,否則可能缺失ffplay