码迷,mamicode.com
首页 > 其他好文 > 详细

freeswitch安装

时间:2018-05-17 11:47:57      阅读:477      评论:0      收藏:0      [点我收藏+]

标签:sites   设置   文件   pkg   shutdown   sip   isa   信息   sql   

OS环境:

CentOS release 6.5 (Final)

1.安装

$ sudo yum install epel-release vim -y
$ wget http://files.freeswitch.org/freeswitch-releases/freeswitch-1.6.20.tar.bz2
$ tar xvjf freeswitch-1.6.20.tar.bz2

 

2.安装依赖包

$ sudo yum install gcc-c++ sqlite-devel zlib-devel libcurl-devel pcre-devel speex-devel ldns-devel libedit-devel openssl-devel -y 
$ sudo yum install libjpeg-devel lua-devel libsndfile-devel libyuv-devel git libtool -y

 

3.安装代码依赖包

$ cd freeswitch-1.6.20

 ------1)安装libyuv(先查看是否存在目录,存在跳过本步骤)

$ cd libs/ 
$ git clone https://freeswitch.org/stash/scm/sd/libyuv.git 
$ cd libyuv/ 
$ make -f linux.mk CXXFLAGS="-fPIC -O2 -fomit-frame-pointer -Iinclude/" 
$ sudo make install
$ sudo cp /usr/lib/pkgconfig/libyuv.pc /usr/lib64/pkgconfig/

 

------2)安装libvpx(先查看是否存在目录,存在跳过本步骤)

$ cd ..
$ git clone https://freeswitch.org/stash/scm/sd/libvpx.git
$ cd libvpx/
$ sudo yum install yasm -y
$ ./configure --enable-pic --disable-static --enable-shared
$ make
$ sudo make install
$ sudo cp /usr/local/lib/pkgconfig/vpx.pc /usr/lib64/pkgconfig/

 ------3)安装opus

$ cd ..
$ git clone https://freeswitch.org/stash/scm/sd/opus.git
$ cd opus/
$ ./autogen.sh
$ ./configure
$ make
$ sudo make install
$ sudo cp /usr/local/lib/pkgconfig/opus.pc /usr/lib64/pkgconfig

 -------4)安装libpng

$ cd ..
$ git clone https://freeswitch.org/stash/scm/sd/libpng.git
$ cd libpng/
$ ./configure
$ make
$ sudo make install
$ sudo cp /usr/local/lib/pkgconfig/libpng* /usr/lib64/pkgconfig/

 4.编译

$ cd freeswitch-1.6.20
$ ./configure
$ make
$ sudo make install

 注:make的时候出现"Neither yasm nor nasm have been found. See the prerequisites section in the README for more info." 报错的话直接 "yum install yasm"即可

5.安装声音文件

$ sudo make cd-sounds-install
$ sudo make cd-moh-install

 6.设置链接符号,便于使用

$ sudo ln -sf /usr/local/freeswitch/bin/freeswitch /usr/local/bin/
$ sudo ln -sf /usr/local/freeswitch/bin/fs_cli /usr/local/bin/

 7.禁用freeswitch上ipv6

cd /usr/local/freeswitch/conf/sip_profiles
mv external-ipv6.xml external-ipv6.xml.inactive

 8.启动

/usr/local/freeswitch/bin/freeswitch

 9.停止

shutdown        
freeswitch -stop           //当运行在后台可以在linux 下使用该命令结束

 至此freeswitch-1.6.2版本在centos 6.5上安装完成,可注册分机拨打测试

后面将记录freeswitch配置操作信息

freeswitch安装

标签:sites   设置   文件   pkg   shutdown   sip   isa   信息   sql   

原文地址:https://www.cnblogs.com/kk123/p/9049310.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!