还没做完
目标是 FreeSWITCH 要支持 openssl1.1.1 ,以便使能 mod_sofia 的 wss
- CentOS6.9下载
https://archive.kernel.org/centos-vault/6.9/isos/x86_64/CentOS-6.9-x86_64-minimal.iso
最小安装
- 配置 yum 源
rm -rf /etc/yum.repos.d/*
curl -o /etc/yum.repos.d/CentOS-Base.repo https://mirrors.aliyun.com/repo/Centos-6.repo
sed -i 's|http://mirrors.aliyun.com/centos|https://mirrors.aliyun.com/centos-vault/centos|g' /etc/yum.repos.d/CentOS-Base.repo
curl -o /etc/yum.repos.d/epel.repo http://mirrors.aliyun.com/repo/epel-6.repo
sed -i 's|http://mirrors.aliyun.com/epel|http://archives.fedoraproject.org/pub/archive/epel|gp' /etc/yum.repos.d/epel.repo
sed -i 's|gpgcheck=1|gpgcheck=0|g' /etc/yum.repos.d/CentOS-Base.repo
- 安装 okay
yum install -y pyliblzma
rpm -ivh http://repo.okay.com.mx/centos/6/x86_64/release/okay-release-1-3.el6.noarch.rpm
sed -i 's+gpgcheck=1+gpgcheck=0+g' /etc/yum.repos.d/okay.repo
yum install -y --skip-broken speex-devel speexdsp-devel libshout-devel libmpg123-devel lame-devel libsndfile-devel
- 安装 gcc 编译工具等
yum install -y autoconf automake bison wget patch \
curl-devel \
gdbm-devel \
gcc-c++ \
gnutls-devel \
libcurl-devel \
libjpeg-devel \
libogg-devel \
libtiff-devel \
libtool \
libuuid-devel \
libxml2-devel \
ncurses-devel \
opus-devel \
pcre-devel \
pkgconfig \
portaudio-devel \
postgresql-devel \
python3-devel \
sqlite-devel \
unixODBC-devel \
zlib-devel \
yasm \
nasm \
libedit-devel \
libatomic
- openssl 升级
# 删除系统自带的 openssl.pc,否则 freeswitch 会自动找到这个自带的版本
rm -f /usr/lib64/pkgconfig/openssl.pc
cd /usr/local/src
# wget https://www.openssl.org/source/old/1.1.1/openssl-1.1.1k.tar.gz
# tar zxvf openssl-1.1.1k.tar.gz
# cd openssl-1.1.1k
wget https://www.openssl.org/source/old/1.1.0/openssl-1.1.0k.tar.gz
tar zxvf openssl-1.1.0k.tar.gz
cd openssl-1.1.0k
./Configure
./config
make && make install
- 编译 FreeSWITCH
cd /usr/local/src
wget https://files.freeswitch.org/releases/freeswitch/freeswitch-1.4.18.tar.gz
tar zxvf freeswitch-1.4.18.tar.gz
cd freeswitch-1.4.18
./rebootstrap.sh
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
# 要升级 srtp, 不然就报错
# 参考1:
# https://github.com/cisco/libsrtp/issues/394
# 参考2:
# https://stackoverflow.com/questions/47518843/error-field-ctx-has-incomplete-type-evp-cipher-ctx