Difference between revisions of "Building recon"

From reSIProcate
Jump to navigation Jump to search
Line 54: Line 54:
 
## Modify the Additional Include Directories settings of the sipXmediaAdapterLib, sipXmedaLib and sipXportLib projects to include: ";..\..\resip\contrib\pcre"
 
## Modify the Additional Include Directories settings of the sipXmediaAdapterLib, sipXmedaLib and sipXportLib projects to include: ";..\..\resip\contrib\pcre"
 
# Build solution.
 
# Build solution.
 +
Note:  If you are building under VS2005, and are getting missing symbols
 +
        in MpResamplerSpeex.  The file resampler.c may be missing from the
 +
        libspeex project file.  You can manaully add this file to the
 +
        project in order to get around these errors.
  
 
===Running testUA on Windows===
 
===Running testUA on Windows===

Revision as of 20:04, 21 August 2008

Setting up the build environment

You build directory structure should be setup as follows:

/resip/                      <- https://svn.resiprocate.org/rep/resiprocate/main
/resip/contrib/openssl       <- https://svn.resiprocate.org/rep/resiprocate/contrib/dtls-srtp/openssl
/resip/contrib/boost_1_34_1  <- BOOST 1.34.1 (required in this location for Windows builds only)
/sipXtapi                    <- https://scm.sipfoundry.org/rep/sipX/branches/sipXtapi
  1. Go to directory where you want to create build env.
  2. svn checkout https://svn.resiprocate.org/rep/resiprocate/main resip
  3. svn checkout https://scm.sipfoundry.org/rep/sipX/branches/sipXtapi sipXtapi
  4. cd resip/contrib
  5. svn checkout https://svn.resiprocate.org/rep/resiprocate/contrib/dtls-srtp/openssl openssl
Note:  Ensure you use at least SVN revision 10660 of sipXtapi.


Building dtls-srtp version of OpenSSL on Windows

recon currently uses a branch of OpenSSL that contains modifications to do dtls-srtp.

/resip/contrib/openssl <- https://svn.resiprocate.org/rep/resiprocate/contrib/dtls-srtp/openssl

You will need ActiveState Perl, available from http://www.activestate.com/ActivePerl - there is a free version available for download.

To build openSSL for windows using VS2003

  1. Use VS2003 Command Prompt window - Note: 0.9.8g will not build Crypto ASM fns with VS2003 MASM - we will build openssl with no ASM
  2. From openssl root run: perl Configure VC-WIN32 enable-tlsext
  3. Run: perl util\mkfiles.pl >MINFO
  4. Run: perl util\mk1mf.pl no-asm debug VC-WIN32 > d32.mak
  5. Run: perl util\mk1mf.pl no-asm VC-WIN32 > 32.mak
  6. Run: nmake -f d32.mak
  7. Run: nmake -f 32.mak

To build openSSL for windows using VS2005

  1. Use VS2005 Command Prompt window
  2. From openssl root run: perl Configure VC-WIN32 enable-tlsext
  3. Run: ms\do_masm
  4. Run: perl util\mkfiles.pl >MINFO
  5. Run: perl util\mk1mf.pl debug VC-WIN32 > d32.mak
  6. Run: perl util\mk1mf.pl VC-WIN32 > 32.mak
  7. Run: nmake -f d32.mak
  8. Run: nmake -f 32.mak


Building recon on Windows

  1. Ensure the build environment is setup as indicated above.
  2. Use the recon_7_1.sln Visual Studio 2003 or recon_8_0.sln Visual Studio 2005 solution file
  3. Open the sipXmediaAdapterLib project settings and enable the following defines by removing the 'xx' characters from the Preprocessor defines. You should do this for both Debug and Release project settings.
    1. DISABLE_DEFAULT_PHONE_MEDIA_INTERFACE_FACTORY
    2. ENABLE_TOPOLOGY_FLOWGRAPH_INTERFACE_FACTORY
  4. Open the sipXmediaAdapterLib and sipXmediaLib project settings and add DISABLE_STREAM_PLAYER to the Preprocessor defines. You should do this for both Debug and Release project settings.
  5. Provide an include path to pcre for the sipXmediaLib projects by doing one of the following:
    1. Modify your base Visual Studio settings for include paths - add an include path to \resip\contrib\pcre
    2. Modify the Additional Include Directories settings of the sipXmediaAdapterLib, sipXmedaLib and sipXportLib projects to include: ";..\..\resip\contrib\pcre"
  6. Build solution.
Note:  If you are building under VS2005, and are getting missing symbols 
       in MpResamplerSpeex.  The file resampler.c may be missing from the 
       libspeex project file.  You can manaully add this file to the 
       project in order to get around these errors.

Running testUA on Windows

By default you will be able to run testUA from the VS debugger, but if you decide to run testUA.exe on another machine you will need the following:

  • codec_*.dll from sipXtapi/sipXmediaLib/bin directory
  • ca.pem file in working directory - contains acceptable root certificate authority (CA) certificates for TURN over TLS
  • VS 2003/2005 - C-runtime libaries present on the destination system

Building sipXtapi on Generic Linux

Note: sipXtackLib is no longer required with the addition of the DISABLE_STREAM_PLAYER define

  • Go to sipXtapi root
  • To build sipXportLib:
   cd sipXtapi/sipXportLib
   autoreconf -fi
   ./configure --prefix=/tmp/stage
   make
  • To build sipXsdpLib:
   cd sipXtapi/sipXsdpLib
   autoreconf -fi
   ./configure --prefix=/tmp/stage
   make
  • To build sipXmediaLib:
   cd sipXtapi/sipXmediaLib
   autoreconf -fi
   ./configure --prefix=/tmp/stage --enable-local-audio CXXFLAGS="-DDISABLE_STREAM_PLAYER"
   make
  • To build sipXmediaAdapterLib:
   cd sipXtapi/sipXmediaAdapterLib
   autoreconf -fi
   ./configure --prefix=/tmp/stage CXXFLAGS="-DDISABLE_DEFAULT_PHONE_MEDIA_INTERFACE_FACTORY -DENABLE_TOPOLOGY_FLOWGRAPH_INTERFACE_FACTORY -DDISABLE_STREAM_PLAYER"
   make


Building recon on Generic Linux

  • Ensure the build environment is setup as indicated above.
  • Build sipXtapi as described above first.
  • If you don't need to cross compile openssl - proceed to next step, otherwise:
   Go to resip/contrib/openssl
   ./Configure {place-target-platform-here} --openssldir=/usr enable-tlsext
   make depend
   make
  • Go to resip/
  • ./configure
   - answer 'yes' to prompt to build reCon - Conversation Manager
   - make sure you enter the path to the dtls-srtp version of OpenSSL when it asks
     (ie: ....resip/contrib/openssl)
  • make


Running testUA on Generic Linux

  • Go to resip/resip/recon/test
  • To run testUA ensure the codec plugins are in the same directory as the executable:
   cp ../../../../sipXtapi/sipXmediaLib/bin/*.so ./
  • ca.pem file in working directory - contains acceptable root certificate authority (CA) certificates for TURN over TLS
  • ./testUA