centos7安装freeswitch1.2.6
-
安装基础包
$ wget http://files.freeswitch.org/freeswitch-releases/freeswitch-1.2.6.tar.bz2
$ sudo yum install bzip2 -y
$ tar xvjf freeswitch-1.2.6.tar.bz2 -
安装依赖包
$ 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 -
代码依赖包
$ cd freeswitch-1.2.6
$ cd libs/
$ git clone https://freeswitch.org/stash/scm/sd/libyuv.git
$ cd freeswitch-1.2.6
$ 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/
$ cd …
$ git clone https://freeswitch.org/stash/scm/sd/libvpx.git
$ cd libvpx/
$ sudo yum install yasm -y(如无法获取则去站点下载编译http://www.tortall.net/projects/yasm/releases/yasm-1.3.0.tar.gz)
$ ./configure --enable-pic --disable-static --enable-shared
$ make
$ sudo make install
$ sudo cp /usr/local/lib/pkgconfig/vpx.pc /usr/lib64/pkgconfig/
$ 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
$ 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/
-
编译
$ cd freeswitch-1.2.6
$ ./configure
$ make
$ sudo make install -
安装声音文件
$ sudo make cd-sounds-install
$ sudo make cd-moh-install -
启动freeswitch
进入cd /usr/local/freeswitch/bin/目录,然后运行 ./freeswitch命令。