centos 7无需token编译安装freeswitch 1.10.11 ——筑梦之路

2024-06-18 08:04

本文主要是介绍centos 7无需token编译安装freeswitch 1.10.11 ——筑梦之路,希望对大家解决编程问题提供一定的参考价值,需要的开发者们随着小编来一起学习吧!

准备工作

安装编译工具和依赖包

yum update -y
sudo yum install epel-release vim tcpdump net-tools.x86_64 -y
sudo yum install gcc-c++ sqlite-devel zlib-devel libcurl-devel pcre-devel speex-devel ldns-devel libedit-devel openssl-devel git -y
yum install yasm nasm opus-devel -y
yum groupinstall perl* -y
yum install python -y
yum install bzip2 -y
yum install -y libshout-devel lame-devel libmpg123-devel
yum install bc -y
yum install curl -y
yum install expect telnet -y
yum install -y unixODBC unixODBC-devel mysql-connector-odbc
yum install -y yum-plugin-ovl centos-release-scl rpmdevtools yum-utils git wget vim devtoolset-7-gcc* devtoolset-7 libtiff-devel cmake3 libatomic unixODBC unixODBC-devel.x86_64 postgresql-libs postgresql-devel libpqxx-devel
yum install -y gcc-c++ autoconf automake libtool ncurses-devel zlib-devel libjpeg-devel openssl-devel e2fsprogs-devel sqlite-devel libcurl-devel pcre-devel speex-devel ldns-devel libedit-devel libxml2-devel libyuv-devel libvpx-devel libvpx2* libdb4* libidn-devel unbound-devel libuuid-devel lua-devel libsndfile-devel yasm-develreboot

拉取freeswitch源码

cd /rootgit clone --branch v1.10.11 https://github.com/signalwire/freeswitch.git

编译安装sofia-sip模块

cd /root/freeswitchgit clone https://github.com/freeswitch/sofia-sip
cd sofia-sip./bootstrap.sh -j
./configure
make
make install
export PKG_CONFIG_PATH=/usr/local/lib/pkgconfig:${PKG_CONFIG_PATH}ldconfig

编译安装spandsp模块

cd /root/freeswitchgit clone https://github.com/freeswitch/spandsp.gitcd spandsp./bootstrap.sh -j./configuremake
make install
ldconfig

注意:该步骤如果按照上面,后面编译freeswitch的时候会报错

mod_spandsp_dsp.c:159:10: error: ‘V18_MODE_5BIT_4545’ undeclared (first use in this function)

正确步骤如下:

 
git clone https://github.com/freeswitch/spandsp.git
cd spandsp
git checkout -b finecode20230705 0d2e6ac65e0e8f53d652665a743015a88bf048d4./bootstrap.sh -j
./configure
make
make install

参考资料:FreeSwitch 1.10.9 在CentOS7.9编译spandsp,V18_MODE_5BIT_4545错误_spandsp编译-CSDN博客https://www.cnblogs.com/zhongqifeng/p/15688517.html

设置要启用的模块

cd /root/freeswitch./bootstrap.shsed -i 's/#formats\/mod_shout/formats\/mod_shout/g' /root/freeswitch/modules.confsed -i 's/applications\/mod_signalwire/#applications\/mod_signalwire/g' /root/freeswitch/modules.confsed -i 's/endpoints\/mod_verto/#endpoints\/mod_verto/g' /root/freeswitch/modules.confsed -i 's/applications\/mod_av/#applications\/mod_av/g' /root/freeswitch/modules.confsed -i 's/codecs\/mod_opus/#codecs\/mod_opus/g' /root/freeswitch/modules.confsed -i 's/#applications\/mod_callcenter/applications\/mod_callcenter/g' /root/freeswitch/modules.confsed -i 's/#applications\/mod_httapi/applications\/mod_httapi/g' /root/freeswitch/modules.confsed -i 's/#event_handlers\/mod_odbc_cdr/event_handlers\/mod_odbc_cdr/g' /root/freeswitch/modules.conf

编译安装freeswitch

./bootstrap.sh./configure --enable-portable-binary --prefix=/usr/local/freeswitch --with-gnu-ld --with-python --with-openssl --enable-core-odbc-support --enable-zrtp
make
make installmake -j cd-sounds-install
make -j cd-moh-install

官方语音包下载地址:Index of /releases/sounds

设置软链接和开机启动

sudo ln -sf /usr/local/freeswitch/bin/freeswitch /usr/local/bin/
sudo ln -sf /usr/local/freeswitch/bin/fs_cli /usr/local/bin/
cp -r /usr/local/freeswitch/bin/freeswitch /etc/rc.d/init.d
echo -e "/etc/init.d/freeswitch -nonat -nc" >> /etc/rc.d/rc.local
chmod +x /etc/rc.d/rc.local

FAQ

以下记录下出现频率比较高的报错信息和相应解决办法,并不一定适用当前这篇。

1. checking for spandsp >= 3.0... configure: error: no usable spandsp; please install spandsp3 devel package or equivalent

Install OKey repository:
yum install http://repo.okay.com.mx/centos/7/x86_64/release/okay-release-1-1.noarch.rpmInstall cheese repository:
yum install http://www.nosuchhost.net/~cheese/fedora/packages/epel-7/x86_64/cheese-release-7-1.noarch.rpmyum install -y spandsp3
yum install -y spandsp3-devel

 2. checking for sofia-sip-ua >= 1.13.6... configure: error: no usable sofia-sip; please install sofia-sip-ua devel package or equivalent

yum install -y sofia-sip
yum install -y sofia-sip-devel

参考资料:

在CentOS7.9系统内安装目前最新版本FreeSWITCH 1.10.11

FreeSWITCH_1.10.11源码安装(centos7)_freeswitch v1.10.11安装-CSDN博客

https://www.cnblogs.com/aowind/p/15655308.html

这篇关于centos 7无需token编译安装freeswitch 1.10.11 ——筑梦之路的文章就介绍到这儿,希望我们推荐的文章对编程师们有所帮助!



http://www.chinasem.cn/article/1071724

相关文章

如何在pycharm安装torch包

《如何在pycharm安装torch包》:本文主要介绍如何在pycharm安装torch包方式,具有很好的参考价值,希望对大家有所帮助,如有错误或未考虑完全的地方,望不吝赐教... 目录在pycharm安装torch包适http://www.chinasem.cn配于我电脑的指令为适用的torch包为总结在p

在PyCharm中安装PyTorch、torchvision和OpenCV详解

《在PyCharm中安装PyTorch、torchvision和OpenCV详解》:本文主要介绍在PyCharm中安装PyTorch、torchvision和OpenCV方式,具有很好的参考价值,... 目录PyCharm安装PyTorch、torchvision和OpenCV安装python安装PyTor

Python Transformer 库安装配置及使用方法

《PythonTransformer库安装配置及使用方法》HuggingFaceTransformers是自然语言处理(NLP)领域最流行的开源库之一,支持基于Transformer架构的预训练模... 目录python 中的 Transformer 库及使用方法一、库的概述二、安装与配置三、基础使用:Pi

idea maven编译报错Java heap space的解决方法

《ideamaven编译报错Javaheapspace的解决方法》这篇文章主要为大家详细介绍了ideamaven编译报错Javaheapspace的相关解决方法,文中的示例代码讲解详细,感兴趣的... 目录1.增加 Maven 编译的堆内存2. 增加 IntelliJ IDEA 的堆内存3. 优化 Mave

如何解决mmcv无法安装或安装之后报错问题

《如何解决mmcv无法安装或安装之后报错问题》:本文主要介绍如何解决mmcv无法安装或安装之后报错问题,具有很好的参考价值,希望对大家有所帮助,如有错误或未考虑完全的地方,望不吝赐教... 目录mmcv无法安装或安装之后报错问题1.当我们运行YOwww.chinasem.cnLO时遇到2.找到下图所示这里3.

Python 安装和配置flask, flask_cors的图文教程

《Python安装和配置flask,flask_cors的图文教程》:本文主要介绍Python安装和配置flask,flask_cors的图文教程,本文通过图文并茂的形式给大家介绍的非常详细,... 目录一.python安装:二,配置环境变量,三:检查Python安装和环境变量,四:安装flask和flas

Win11安装PostgreSQL数据库的两种方式详细步骤

《Win11安装PostgreSQL数据库的两种方式详细步骤》PostgreSQL是备受业界青睐的关系型数据库,尤其是在地理空间和移动领域,:本文主要介绍Win11安装PostgreSQL数据库的... 目录一、exe文件安装 (推荐)下载安装包1. 选择操作系统2. 跳转到EDB(PostgreSQL 的

Java编译生成多个.class文件的原理和作用

《Java编译生成多个.class文件的原理和作用》作为一名经验丰富的开发者,在Java项目中执行编译后,可能会发现一个.java源文件有时会产生多个.class文件,从技术实现层面详细剖析这一现象... 目录一、内部类机制与.class文件生成成员内部类(常规内部类)局部内部类(方法内部类)匿名内部类二、

Linux系统中卸载与安装JDK的详细教程

《Linux系统中卸载与安装JDK的详细教程》本文详细介绍了如何在Linux系统中通过Xshell和Xftp工具连接与传输文件,然后进行JDK的安装与卸载,安装步骤包括连接Linux、传输JDK安装包... 目录1、卸载1.1 linux删除自带的JDK1.2 Linux上卸载自己安装的JDK2、安装2.1

JSON Web Token在登陆中的使用过程

《JSONWebToken在登陆中的使用过程》:本文主要介绍JSONWebToken在登陆中的使用过程,具有很好的参考价值,希望对大家有所帮助,如有错误或未考虑完全的地方,望不吝赐教... 目录JWT 介绍微服务架构中的 JWT 使用结合微服务网关的 JWT 验证1. 用户登录,生成 JWT2. 自定义过滤