1、下载相关软件:
wget https://github.com/pkuvcl/FFmpegAVS2.git
wget https://github.com/pkuvcl/xavs2.git
wget https://github.com/pkuvcl/davs2.git
2、编译安装avs2编码库
unzip xavs2-master.zip
cd xavs2-master/build/linux/
./configure --prefix=/Users/fu/avs2/avs2_lib --enable-pic --enable-shared
make -j8
make install
3、编译安装avs2解码库
unzip davs2-master.zip
cd davs2-master/build/linux/
./configure --prefix=/Users/fu/avs2/avs2_lib --enable-pic --enable-shared
make -j8
make install
4、编译安装SDL2.0
- 如果需要编译安装ffplay,则需要下载SDL2.0
- SDL2-2.0.10.zip
unzip SDL2-2.0.10.zip
cd SDL2-2.0.10
./configure --prefix=/Users/fu/avs2/avs2_lib
make -j8
make install
5、编辑安装FFmpegAVS2 加载avs2编解码库
unzip FFmpegAVS2-master.zip
cd FFmpegAVS2-master
export PKG_CONFIG_PATH=$PKG_CONFIG_PATH:/Users/fu/avs2/avs2_lib/lib/pkgconfig
./configure --prefix=/Users/fu/avs2/avs2_lib --enable-gpl --enable-libxavs2 --enable-libdavs2 --enable-shared --enable-static
make -j8
make install
export PATH=$PATH:/Users/fu/avs2/avs2_lib/bin