1. 编译srt
1.1 下载及编译srt代码
git clone https://github.com/Haivision/srt.git
cd srt
./configure
make && make install //或者使用clion的cmake
2. 安装ffmepg之间的准备
依赖ffmpeg动态库,libsrt, libx264, lib265, libfdk_aac等。
2.1 检查是否安装openssl
cmd$ pkg-config --list-all|grep openssl
openssl OpenSSL - Secure Sockets Layer and cryptography libraries and tools
如果已经成功安装,则略过,否则执行
brew install openssl
brew link openssl --force //必须要执行
可能需要执行:
export PKG_CONFIG_PATH="/usr/local/lib/pkgconfig:/usr/local/opt/openssl/lib/pkgconfig"
libx264
wget https://johnvansickle.com/ffmpeg/release-source/libx264-git.tar.xz
xz -d libx264-git.tar.xz
tar -xvf libx264-git.tar
cd ./libx264-git

本文详细介绍了如何在Linux系统中编译ffmpeg并整合libsrt库。首先,通过git克隆并编译srt源码,然后安装ffmpeg的依赖库如libx264、libx265和libfdk_aac。接着,配置并编译ffmpeg,确保启用libsrt选项。在编译过程中,检查openssl的安装,解决可能出现的错误和依赖问题。最后,执行make和make install完成ffmpeg的安装。
1407

被折叠的 条评论
为什么被折叠?



