环境准备
- ubuntu 20.04
- ffmpeg-4.2.8.tar.bz2
- pjproject-2.13.tar.gz
安装依赖库
sudo apt install build-essential
# install sdl2
sudo apt install libsdl2-dev
sudo apt install libgl-dev
# yasm
sudo apt install yasm
# libfdk-aac
sudo apt install libfdk-aac-dev
# x264
sudo apt install libx264-dev
# vp8/vp9
sudo apt install libvpx-dev
# mp3lame
sudo apt install libmp3lame-dev
# opus
sudo apt install libopus-dev
# v4l
sudo apt install libv4l-dev
源码编译ffmpeg和pjsip
# build ffmpeg
tar xavf ffmpeg-4.2.8.tar.bz2
cd ffmpeg-4.2.8/
./configure --enable-gpl --enable-libx264
make
sudo make install
# build pjsip
tar xavf pjproject-2.13.tar.gz
cd pjproject-2.13/
./configure
echo "#define PJMEDIA_HAS_VIDEO 1" > /pjlib/include/pj/config_site.h
make dep
make
sudo make install
网友评论