FreeSWTICH安装过程中make编译遇到“Makefile:929: *** You must install libopus-dev to build mod_opus. Stop.”

环境

FreeSWITCH版本1.8.7
CentOS版本7.6
阿里云

起因
编译安装FreeSWITCH的过程中遇到如下的错误,导致安装中止:

making all mod_opus
make[4]: Entering directory `/usr/src/freeswitch-1.8.7/src/mod/codecs/mod_opus'
Makefile:929: *** You must install libopus-dev to build mod_opus.  Stop.
make[4]: Leaving directory `/usr/src/freeswitch-1.8.7/src/mod/codecs/mod_opus'
make[3]: *** [mod_opus-all] Error 1
make[3]: Leaving directory `/usr/src/freeswitch-1.8.7/src/mod'
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory `/usr/src/freeswitch-1.8.7/src'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/usr/src/freeswitch-1.8.7'
make: *** [all] Error 2

分析:
这个错误提示信息是比较明确的,就是缺少 libopus-dev 。因此,我们的努力方向也就很明确了。
首先尝试:

yum install libopus-devel

结果如下:

No package libopus-devel available.
Error: Nothing to do

实际上,opus opus-devel都是已经安装了的。

Package opus-devel-1.0.2-6.el7.x86_64 already installed and latest version
Package opus-1.0.2-6.el7.x86_64 already installed and latest version

难道是版本低?直接去官网opus-code.org下载最新版本

wget https://archive.mozilla.org/pub/opus/opus-1.3.1.tar.gz

安装opus最新版本1.3.1之后,问题还是不能解决。看来没那么简单,要花点功夫。OPUS这个编码目前使用的也不多,其实直接删除也不影响使用的。那就删除吧。 _
找到codecs目录,直接删除codec_opus子目录。编译成功。

你可能感兴趣的:(FreeSWITCH)