Required Software
====================

Non-SIPfoundry software:

  Apache 2 (tested with 2.0.49)
    http://httpd.apache.org/
    On RedHat Enterprise "up2date httpd httpd-devel" installs what is needed.

  Mod cplusplus 1.2 (also tested w/1.3)
    http://modcplusplus.sourceforge.net/

  Expat (tested w/1.95.7)
    http://www.libexpat.org/

  Cgicc (tested w/3.2.2)
    http://www.cgicc.org/

Other SIPfoundry software:

  sipXportLib 2.6.0
    http://www.sipfoundry.org/sipXportLib/

  sipXtackLib 2.6.0
    http://www.sipfoundry.org/sipXtackLib/

  sipXmediaLib 2.6.0
    http://www.sipfoundry.org/sipXmediaLib/

  sipXcallLib 2.6.0
    http://www.sipfoundry.org/sipXcallLib/

  sipXcommserverLib 2.6.0
    http://www.sipfoundry.org/sipXcommserverLib/

  sipXproxy 2.6.0
    http://www.sipfoundry.org/sipXproxy/

  sipXregistry 2.6.0
    http://www.sipfoundry.org/sipXregistry/

  sipXconfig 2.6.0
    http://www.sipfoundry.org/sipXconfig/

  sipXvxml 2.6.0
    http://www.sipfoundry.org/sipXvxml/


Special Software Installation Instructions
=============================================

+++ Choosing a user identity

    The sipX servers need to all run as the same user; we recommend
    creating a user account for this purpose.

      useradd sipxchange

    Right now, the default user is 'sipxchange', but that is a Pingtel
    trademark, so it will probably change soon.

    When you run 'configure', you can specify the user name using
    the SIPXPBXUSER variable:

      configure SIPXPBXUSER=yourpbxuser

+++ Installing Apache2

  a.) If building from source, be sure to enable SSL; sipX requires
      it for several things. If you don't enable SSL, the http server
      will *quietly* not listen on the https port, and those things
      won't work.

      ./configure --enable-ssl

  b.) Install SSL keys and certificates; see the instructions in
      the sipXcommserverLib/doc/INSTALL.ssl

      No - you cannot skip this, even for a quick test; sipx will not
           work without the security installed.

  NOTE:
    You should NOT use the apache startup script to start your
    http server; the sipxpbx startup script will do it in the
    proper sequence relative to the other pbx services.  While it
    may be possible to use the same server to also provide general
    web services, we do not recommend it, and you'll have to
    merge the configuration of your server with that provided with
    this project.

    The http server MUST be running as the SIPXPBXUSER; if it is not, then
    the cgi programs installed by sipX will either not use the right shared
    memory and fail, or take ownership of it as the wrong user and
    everything else in sipXpbx will fail.


+++ Installing mod_cplusplus
    This is an apache plugin that's needed to run modules written in C++.

  a.) Build in the distribution directory for mod_cplusplus as follows:

      ./autogen.sh --with-httpd=/usr/local/apache2
      gmake
      gmake install

  b.) The default install does not copy the shared library file to Apache's
      preferred modules directory nor does it install the header files so
      you should copy it as follows:

      cp src/.libs/libmod_cplusplus.so* /usr/local/apache2/modules/
      cp include/*.h /usr/local/apache2/include

 *On Gentoo use:
      ln -s /usr/include/apache2 /usr/lib/apache2/include
      ./autogen.sh --with-httpd=/usr/lib/apache2
      gmake
      cp src/.libs/libmod_cplusplus.so* /usr/lib/apache2-extramodules
      cp include/*.h /usr/include/apache2

   Also on Gentoo, If this bug is still unresolved, you'll have to
   make an edit to your httpd.conf file: 

      http://track.sipfoundry.org/browse/XPB-92


Installation
=====================

  As yourself, run:

      ./configure
      make

  As root or the SIPXPBXUSER run:

      make install

Making PBX run as a Redhat Service
==================================

  The file:

     ${prefix}/etc/init.d/sipxpbx

  is a sysV-style init script.

  To start all the components of sipXpbx under one service
  called sipxpbx, create a symbolic link as follows (as root):

    ln -s ${prefix}/etc/init.d/sipxpbx /etc/init.d/sipxpbx

  and run (as root):

    service sipxpbx start

  to make sipXpbx start automatically when the system boots:

    chkconfig sipxpbx on

  See README for operational instructions
