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安装报错:Cannot detect a launch configuration解决办法

《Pycharm安装报错:Cannotdetectalaunchconfiguration解决办法》本文主要介绍了Pycharm安装报错:Cannotdetectalaunchconfigur... 本文主要介绍了Pycharm安装报错:Cannot detect a launch configuratio

pytorch+torchvision+python版本对应及环境安装

《pytorch+torchvision+python版本对应及环境安装》本文主要介绍了pytorch+torchvision+python版本对应及环境安装,安装过程中需要注意Numpy版本的降级,... 目录一、版本对应二、安装命令(pip)1. 版本2. 安装全过程3. 命令相关解释参考文章一、版本对

Windows系统下如何查找JDK的安装路径

《Windows系统下如何查找JDK的安装路径》:本文主要介绍Windows系统下如何查找JDK的安装路径,文中介绍了三种方法,分别是通过命令行检查、使用verbose选项查找jre目录、以及查看... 目录一、确认是否安装了JDK二、查找路径三、另外一种方式如果很久之前安装了JDK,或者在别人的电脑上,想

大数据spark3.5安装部署之local模式详解

《大数据spark3.5安装部署之local模式详解》本文介绍了如何在本地模式下安装和配置Spark,并展示了如何使用SparkShell进行基本的数据处理操作,同时,还介绍了如何通过Spark-su... 目录下载上传解压配置jdk解压配置环境变量启动查看交互操作命令行提交应用spark,一个数据处理框架

Python FastAPI入门安装使用

《PythonFastAPI入门安装使用》FastAPI是一个现代、快速的PythonWeb框架,用于构建API,它基于Python3.6+的类型提示特性,使得代码更加简洁且易于绶护,这篇文章主要介... 目录第一节:FastAPI入门一、FastAPI框架介绍什么是ASGI服务(WSGI)二、FastAP

2025最新版Python3.13.1安装使用指南(超详细)

《2025最新版Python3.13.1安装使用指南(超详细)》Python编程语言自诞生以来,已经成为全球最受欢迎的编程语言之一,它简单易学易用,以标准库和功能强大且广泛外挂的扩展库,为用户提供包罗... 目录2025最新版python 3.13.1安装使用指南1. 2025年Python语言最新排名2.

Python依赖库的几种离线安装方法总结

《Python依赖库的几种离线安装方法总结》:本文主要介绍如何在Python中使用pip工具进行依赖库的安装和管理,包括如何导出和导入依赖包列表、如何下载和安装单个或多个库包及其依赖,以及如何指定... 目录前言一、如何copy一个python环境二、如何下载一个包及其依赖并安装三、如何导出requirem

Windows环境下安装达梦数据库的完整步骤

《Windows环境下安装达梦数据库的完整步骤》达梦数据库的安装大致分为Windows和Linux版本,本文将以dm8企业版Windows_64位环境为例,为大家介绍一下达梦数据库的具体安装步骤吧... 目录环境介绍1 下载解压安装包2 根据安装手册安装2.1 选择语言 时区2.2 安装向导2.3 接受协议

无需邀请码!Manus复刻开源版OpenManus下载安装与体验

《无需邀请码!Manus复刻开源版OpenManus下载安装与体验》Manus的完美复刻开源版OpenManus安装与体验,无需邀请码,手把手教你如何在本地安装与配置Manus的开源版OpenManu... Manus是什么?Manus 是 Monica 团队推出的全球首款通用型 AI Agent。Man

IDEA与JDK、Maven安装配置完整步骤解析

《IDEA与JDK、Maven安装配置完整步骤解析》:本文主要介绍如何安装和配置IDE(IntelliJIDEA),包括IDE的安装步骤、JDK的下载与配置、Maven的安装与配置,以及如何在I... 目录1. IDE安装步骤2.配置操作步骤3. JDK配置下载JDK配置JDK环境变量4. Maven配置下