Setting up a development environment
From SIPfoundry sipx, The Open Source SIP PBX for Linux - Calivia
Contents |
Introduction
The following instructions apply to Fedora Core (FC5, FC6, F7 and F8) as well as Red Hat Enterprise Linux 5 (RHEL5) and CentOS 5.
For CentOS 4 and Red Hat Enterprise Linux 4 (RHEL4): Setting up a development environment for RHEL4 and CentOS4
NOTES
- If you simply want to install sipXecs GO HERE
- Very useful tips on building sipXecs Building Tips - worth reading!!!
- If you want to build RPMs, see Building RPMs and Building RPM tips
System Setup Prerequisites
Install Linux with SELinux and Firewall off (unless you know what you are doing). These instructions will assume you've installed the minimal package (e.g. No X libraries, compiler, etc). If you've installed more, that's ok, some of the dependencies you'll be asked to install will simply be ignored by the yum install command.
Disable Firewall
Using the Setup Agent run the firewall configuration tool and disable the Linux firewall. If you want to disable the firewall after the installation finished use this command: system-config-securitylevel-tui.
Disable SELinux
SELinux has to be disabled for sipXecs because there is currently no selinux policy file availabe. Fedora and CentOS by default enables SELinux.
| File: /etc/selinux/config |
SELINUX=disabled |
Install Build Tools and Dependencies
yum install gcc gcc-c++ autoconf automake libtool subversion doxygen rpm-build zip \ httpd-devel openssl-devel jpackage-utils which unzip \ pcre-devel expat-devel unixODBC-devel createrepo \ jakarta-commons-beanutils jakarta-commons-collections jakarta-commons-net \ ant log4j junit ant-commons-logging ant-junit ant-trax ant-nodeps \ mod_ssl postgresql-server libXp zlib-devel postgresql-devel ruby ruby-devel
To build dependencies under /lib you will also need:
yum install libpng-devel libart_lgpl-devel freetype freetype-devel oro wget ftp://mirror.switch.ch/pool/1/mirror/epel/5/x86_64/scons-0.98.1-1.el5.noarch.rpm rpm -i scons-0.98.1-1.el5.noarch.rpm
Note: On Fedora also install rpmdevtools. On CentOS install redhat-rpm-config.
yum install rpmdevtools redhat-rpm-config
Additional build dependencies to build the FreeSWITCH conferencing server
yum install alsa-lib-devel curl-devel gnutls-devel lzo-devel gdbm-devel \ mysql-devel ncurses-devel python-devel termcap
Installing Remaining Dependencies
Remaining dependencies are dependencies not available from a standard repository. For the most common platforms you can download pre-built dependencies from SIPfoundry. If you are building on a platform not available on SIPfoundry, see Building dependencies. Don't forget to install the gems once the dependencies are built and installed.
Fedora 6 or greater:
yum install rubygems rubygem-rake ruby-postgres w3c-libwww-devel cppunit-devel xerces-c-devel gem install file-tail (run this twice if it fails the first time)
Install dependencies not available in Fedora standard repositories. Alternatively you can build these yourself see Building dependencies
sh -c "wget -P /etc/yum.repos.d http://sipxecs.sipfoundry.org/temp/sipXecs/sipxecs-unstable-fc.repo" yum install cgicc-devel java-1.6.0-sun-devel ruby-dbi nsis sipx-jasperreports-deps
CentOS5/ RHEL5:
sh -c "wget -P /etc/yum.repos.d http://sipxecs.sipfoundry.org/temp/sipXecs/sipxecs-unstable-centos.repo" yum install cgicc-devel java-1.6.0-sun-devel ruby-dbi rubygems w3c-libwww-devel cppunit ruby-postgres xerces-c-devel \ jakarta-commons-net nsis gem install rake gem install file-tail
If you want to run unit tests you'll also need named (tests will be skipped if named is not found):
yum install bind
