首先配置linux虚拟环境(编译环境),https://blog.csdn.net/afei198409/article/details/88560411
1.下载ffmpeg,官方地址:http://ffmpeg.org/download.html
2.解压后项目结构如下:
3.使用命令行运行脚本ffbuild/libversion.sh, ffbuild/pkgconfig_generate.sh, ffbuild/version.sh
4.修改根目录下configure文件
将该文件中的如下四行:
SLIBNAME_WITH_MAJOR='$(SLIBNAME).$(LIBMAJOR)'
LIB_INSTALL_EXTRA_CMD='$$(RANLIB) "$(LIBDIR)/$(LIBNAME)"'
SLIB_INSTALL_NAME='$(SLIBNAME_WITH_VERSION)'
SLIB_INSTALL_LINKS='$(SLIBNAME_WITH_MAJOR)$(SLIBNAME)'
替换为:
SLIBNAME_WITH_MAJOR='$(SLIBPREF)$(FULLNAME)-$(LIBMAJOR)$(SLIBSUF)'
LIB_INS