FreeSWITCH installation error “You must install libyuv-dev to build mod_fsv” solution

When I encountered this problem when installing FreeSWITCH yesterday afternoon, I didn’t solve it all afternoon, and I took many detours. If you install libyuv-devel directly through yum, you will get an error saying that the installation package cannot be found. Later, through the online chat on the FreeSWITCH official website, I asked FreeSWITCH staff to find out how to install libyuv-devel (please refer to: 20120727svn312.el6.x86_64.rpm.html ). However, the same error is reported after installation, and it feels that it is useless to install libyuv-devel through this method. Later, the problem was solved perfectly by the following methods.


Personal installation environment:

  OS: CentOS6.5 64-bit
  FreeSWITCH Ver: 1.6.0

The official manual installed by FreeSWITCH (for CentOS6.*):

Problems encountered during installation and solutions

  1. When executing “./configure -C”, if there is an error, it means that the development package file (library file) is missing. This error is easier to solve. If any library file is missing, install the corresponding library file.

  2. During the execution of “make && make install”, I encountered a troublesome error, which was not resolved for an entire afternoon yesterday afternoon, so this article was mainly written to share this error.

    Error content: Makefile:797: *** You must install libyuv-dev to build mod_fsv. Stop.


      (1) Download the libyuv source code and compile it

        cd freeswitch/libs
        git clone
        cd libyuv
        make -f CXXFLAGS=”-fPIC -O2 -fomit-frame-pointer -Iinclude/”
        make install
        cp /usr/lib/pkgconfig/libyuv.pc /usr/lib64/pkgconfig/

        (If you just install libyuv, there will be errors next. I will list the files that I need to install after reporting the error as follows)

      (2) Download the libvpx source code and compile it

        cd ..
        git clone
        cd libvpx
        ./configure –enable-pic –disable-static –enable-shared
        (If Configuration failed appears. Cause of error It is: Neither yasm nor nasm have been found, please refer to the following “※” to solve the error.)
        make install
        cp /usr/local/lib/pkgconfig/vpx.pc /usr/lib64/pkgconfig/

      (※) Download and compile yasm

        yasm is an assembler compiler, which is an upgraded version of nasm.
        Download address of yasm:
        yasm decompression command: tar -zxvf ****.tar.gz (I download
        Yasm-1.3.0.tar.gz ) yasm compile and install: ① ./configure, ② make, ③make install After
        yasm is installed, go back to the second step and reinstall libvpx

      (3) Download and compile opus

        cd ..
        git clone
        cd opus
        make install
        cp /usr/local/lib/pkgconfig/opus.pc /usr /lib64/pkgconfig

      (4) Download libpng and compile

        cd ..
        git clone
        cd libpng
        make install
        cp /usr/local/lib/pkgconfig/libpng* /usr/lib64/pkgconfig/

  After downloading and installing the above four dependent files, after re-executing FreeSWITCH’s “./configure”, “make && make install” can install FreeSWITCH normally. At least the installation was successful on my side.

  If there are other errors after the above four dependent files are installed, re-execute “./configure” and “make” if the following errors are reported, please refer to the following solutions:

  (1) The system does not install lua error

    CXX mod_lua_la-mod_lua.lo
    mod_lua.cpp:37:17: error: lua.h: No such file or directory
    mod_lua.cpp:38:21: error: lauxlib.h: No such file or directory
    mod_lua.cpp:39: 20: error: lualib.h: No such file or directory
      Solution: yum install lua lua-devel

      (2) The system lacks sndfile library files

    make[4]: Entering directory `/usr/local/src/freeswitch-1.6.0/src/mod/formats/mod_sndfile’
    Makefile:796: *** You must install libsndfile-dev to build mod_sndfile. Stop
      Download the package libsndfile-1.0.26.tar.gz and upload it to the server
      Download address
      tar zxvf libsndfile-1.0.26.tar.gz
      make install
      Re-execute /usr/local/lib/pkgconfig/sndfile.pc /usr/lib64/pkgconfig Re-execute FreeSWITCH’s “./configure”, then make and make install.

Read More:

Leave a Reply

Your email address will not be published. Required fields are marked *