Build FreeSWITCH from source on Ubuntu 12.04


FreeSWITCH has a fairly detailed Wiki page on download and installation. This post cuts to the chaff.

Execute the following commands from terminal in the order specified. You should be fine doing it in your home folder.

sudo apt-get install git-core build-essential autoconf automake libtool libncurses5 libncurses5-dev make libjpeg-dev pkg-config unixodbc unixodbc-dev zlib1g-dev libcurl4-openssl-dev libexpat1-dev libssl-dev libtiff4-dev libx11-dev unixodbc-dev zlib1g-dev libzrtpcpp-dev libasound2-dev libogg-dev libvorbis-dev libperl-dev libgdbm-dev libdb-dev python-dev uuid-dev bison autoconf g++ libncurses-dev speex libspeexdsp-dev libedit-dev libpcre3-dev

git clone https://freeswitch.org/stash/scm/fs/freeswitch.git

cd freeswitch

./bootstrap.sh

./configure

make

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

Configuration files are located under /usr/local/freeswitch/conf, if you want to edit any.

Execute FreeSWITCH as superuser thus

sudo /usr/local/freeswitch/bin/freeswitch -nc

Remove -nc option to run in console mode.

To stop FreeSWITCH

sudo /usr/local/freeswitch/bin/freeswitch -stop

If you get “libspandsp.a: No such file or directoryerror when executing make after a make clean, execute the following commands and resume make.

cd libs/spandsp
make clean
make
cd ../..

To ensure a clean build, use git clean -f -x instead of make clean.

Kudos: Henrique Borges, Vitória Vasconcelos

13 thoughts on “Build FreeSWITCH from source on Ubuntu 12.04

  1. [HELP]
    when i type “./configure”, and the result is this:
    checking for gunzip… /bin/gunzip
    checking for bzip2… /bin/bzip2
    checking for xz… /usr/bin/xz
    checking for gtar… no
    checking for tar… /bin/tar
    checking for wget… /usr/bin/wget
    checking for curl… no
    checking for libpng >= 1.6.16… checking for libpng16 >= 1.6.16… checking for libpng >= 1.2.49… no
    checking for freetype2 >= 2.4.9… no
    checking for sqlite3 >= 3.6.20… Package sqlite3 was not found in the pkg-config search path. Perhaps you should add the directory containing `sqlite3.pc’ to the PKG_CONFIG_PATH environment variable No package ‘sqlite3’ found
    configure: error: Library requirements (sqlite3 >= 3.6.20) not met; consider adjusting the PKG_CONFIG_PATH environment variable if your libraries are in a nonstandard prefix so pkg-config can find them.
    could u help me, i still newbie :)
    Thank you.

      1. Thanks it works!
        but there are another error:

        checking for libpcre >= 7.8… Package libpcre was not found in the pkg-config search path. Perhaps you should add the directory containing `libpcre.pc’ to the PKG_CONFIG_PATH environment variable No package ‘libpcre’ found
        configure: error: Library requirements (libpcre >= 7.8) not met; consider adjusting the PKG_CONFIG_PATH environment variable if your libraries are in a nonstandard prefix so pkg-config can find them.

  2. Thanks!

    but still get error after type “make”
    Makefile:808: *** You must install libyuv-dev to build mod_fsv. Stop.
    make[4]: Leaving directory `/usr/local/src/freeswitch/src/mod/applications/mod_fsv’
    make[3]: *** [mod_fsv-all] Error 1
    make[3]: Leaving directory `/usr/local/src/freeswitch/src/mod’
    make[2]: *** [all-recursive] Error 1
    make[2]: Leaving directory `/usr/local/src/freeswitch/src’
    make[1]: *** [all-recursive] Error 1
    make[1]: Leaving directory `/usr/local/src/freeswitch’
    make: *** [all] Error 2

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s