Debian12 源码编译 FreeSWITCH 1.10.12

这是一篇命题作文 :)

第一步,更换 apt 源

复制代码
cat <<"EOF" > /etc/apt/sources.list

deb http://mirrors.huaweicloud.com/debian/ bookworm main non-free non-free-firmware contrib
deb http://mirrors.huaweicloud.com/debian-security/ bookworm-security main
deb http://mirrors.huaweicloud.com/debian/ bookworm-updates main non-free non-free-firmware contrib
deb http://mirrors.huaweicloud.com/debian/ bookworm-backports main non-free non-free-firmware contrib
 
EOF

apt update

比 163 快


第二步,安装 git vim gcc 等工具

复制代码
apt install -y --fix-missing git sed m4 bison build-essential pkg-config uuid-dev zlib1g-dev libjpeg-dev libsqlite3-dev libcurl4-openssl-dev \
	libpcre3-dev libspeexdsp-dev libldns-dev libedit-dev libtiff5-dev yasm libopus-dev libsndfile1-dev unzip \
	libshout-dev libmpg123-dev libmp3lame-dev \
	libavformat-dev libswscale-dev liblua5.2-dev lua5.2 cmake libpq-dev ca-certificates python3 python3-dev python3-distutils \
	unixodbc-dev autoconf automake ntpdate libxml2-dev libpq-dev libpq5 sngrep vim sip-tester


cat <<"EOF" > ~/.vimrc

set shiftwidth=4
set softtabstop=4
set tabstop=4
set number
set fileencodings=utf-8
set encoding=utf-8

EOF

编译 libks

复制代码
git clone https://github.com/signalwire/libks.git /usr/src/libks
cd /usr/src/libks
cmake . -DCMAKE_INSTALL_PREFIX:PATH=/usr/local
make && make install

编译 sofia-sip

复制代码
git clone https://github.com/freeswitch/sofia-sip /usr/src/sofia-sip

cd /usr/src/sofia-sip
./bootstrap.sh
./configure
make && make install

编译 spandsp

复制代码
git clone https://github.com/freeswitch/spandsp /usr/src/spandsp

cd /usr/src/spandsp
# https://github.com/signalwire/freeswitch/issues/2248
git checkout 0d2e6ac
./bootstrap.sh
./configure
make &&  make install

编译 FreeSWITCH

复制代码
git clone https://github.com/signalwire/freeswitch.git -b v1.10.12 /usr/src/freeswitch
cd /usr/src/freeswitch
./bootstrap.sh

sed -i '/mod_signalwire/d' modules.conf
sed -i '/mod_enum/d' modules.conf
sed -i '/mod_opus/d' modules.conf
sed -i 's+#formats/mod_shout+formats/mod_shout+g' modules.conf
sed -i 's+#applications/mod_curl+applications/mod_curl+g' modules.conf
sed -i 's+#xml_int/mod_xml_curl+xml_int/mod_xml_curl+g' modules.conf
#sed -i 's+#languages/mod_python3+languages/mod_python3+g' modules.conf

./configure

make && make install
make cd-sounds-install && make cd-moh-install

echo '/usr/local/lib' >> /etc/ld.so.conf
ldconfig 
ln -s /usr/local/freeswitch/bin/freeswitch /usr/bin
ln -s /usr/local/freeswitch/bin/fs_cli /usr/bin

关于mod_xml_curl 这个模块的介绍,请参考下面的链接:

https://rts.cn/docs/FreeSWITCH-Explained/Modules/mod_xml_curl_1049001


mod_python3 编译似乎有点问题

找了2个工单:

https://github.com/signalwire/freeswitch/issues/1389

https://github.com/signalwire/freeswitch/issues/1479

相关推荐
so~what5 小时前
6G Day 1
信息与通信·通信
littleBird_24 天前
NR 5G-A NTN 小区搜索及NTN相关SIB
5g·通信·nr
搞科研的小刘选手4 天前
【见刊检索快 | 重庆线上线下同步】第五届信号处理、计算机网络与通信国际学术会议(SPCNC 2026)
计算机网络·信号处理·通信·学术会议·会议推荐·重庆
星恒讯工业路由器7 天前
双栈时代的访问断层:当同一个域名走向两条网络路径
网络·物联网·信息与通信·ipv4·通信·ipv6·双栈网络
littleBird_28 天前
NR 5G-A NTN技术概述
5g·通信·nr
一条大祥脚15 天前
26CCPC网络赛 DFS|数学|解方程|异或哈希|通信|二分|倍增|期望DP|最短路计数
通信·倍增·ccpc网络赛·疑惑哈希·期望dp
小贺儿开发17 天前
Unity 局域网遥控幻灯片展示工具 3.0
科技·http·unity·工具·ppt·通信·网页
搞科研的小刘选手20 天前
【中国·海口(线上+线下)】2026年智能感知、通信与海洋应用国际学术会议(ISCMA 2026)
通信·学术会议·会议推荐·智能感知·海洋应用·海口·海南大学
码上有光21 天前
Linux进程通信——共享内存、消息队列和信号量
android·linux·运维·共享内存·通信
Seoyoneh1 个月前
呼叫中心系统上云还是本地部署?架构、成本与运维全维度技术对比
人工智能·信息与通信·通信