[Pkg-voip-commits] r6757 - in /opensips: ./ branches/ tags/ trunk/ trunk/debian/

jesusch-guest at alioth.debian.org jesusch-guest at alioth.debian.org
Wed Feb 11 13:42:56 UTC 2009


Author: jesusch-guest
Date: Wed Feb 11 13:42:55 2009
New Revision: 6757

URL: http://svn.debian.org/wsvn/pkg-voip/?sc=1&rev=6757
Log:
Added first OpenSIPS draft

Added:
    opensips/
    opensips/branches/
    opensips/build-area   (with props)
    opensips/tags/
    opensips/tarballs   (with props)
    opensips/trunk/
    opensips/trunk/debian/
    opensips/trunk/debian/changelog   (with props)
    opensips/trunk/debian/compat
    opensips/trunk/debian/control   (with props)
    opensips/trunk/debian/copyright   (with props)
    opensips/trunk/debian/opensips-osp-module.examples
    opensips/trunk/debian/opensips.README.Debian   (with props)
    opensips/trunk/debian/opensips.default   (with props)
    opensips/trunk/debian/opensips.dirs   (with props)
    opensips/trunk/debian/opensips.examples
    opensips/trunk/debian/opensips.init   (with props)
    opensips/trunk/debian/opensips.postinst   (with props)
    opensips/trunk/debian/rules   (with props)
    opensips/trunk/debian/watch   (with props)

Added: opensips/build-area
URL: http://svn.debian.org/wsvn/pkg-voip/opensips/build-area?rev=6757&op=file
==============================================================================
--- opensips/build-area (added)
+++ opensips/build-area Wed Feb 11 13:42:55 2009
@@ -1,0 +1,1 @@
+link ../build-area/

Propchange: opensips/build-area
------------------------------------------------------------------------------
    svn:special = *

Added: opensips/tarballs
URL: http://svn.debian.org/wsvn/pkg-voip/opensips/tarballs?rev=6757&op=file
==============================================================================
--- opensips/tarballs (added)
+++ opensips/tarballs Wed Feb 11 13:42:55 2009
@@ -1,0 +1,1 @@
+link ../tarballs/

Propchange: opensips/tarballs
------------------------------------------------------------------------------
    svn:special = *

Added: opensips/trunk/debian/changelog
URL: http://svn.debian.org/wsvn/pkg-voip/opensips/trunk/debian/changelog?rev=6757&op=file
==============================================================================
--- opensips/trunk/debian/changelog (added)
+++ opensips/trunk/debian/changelog Wed Feb 11 13:42:55 2009
@@ -1,0 +1,9 @@
+opensips (1.4.4-1) UNRELEASED; urgency=low
+
+  * NOT RELEASED YET
+
+  * Still not fully working due to svn-buildpackage weird stuff
+
+ -- Bjoern Boschman <bjoern at boschman.de>  Wed, 11 Feb 2009 14:40:45 +0200
+
+

Propchange: opensips/trunk/debian/changelog
------------------------------------------------------------------------------
    svn:executable = *

Added: opensips/trunk/debian/compat
URL: http://svn.debian.org/wsvn/pkg-voip/opensips/trunk/debian/compat?rev=6757&op=file
==============================================================================
--- opensips/trunk/debian/compat (added)
+++ opensips/trunk/debian/compat Wed Feb 11 13:42:55 2009
@@ -1,0 +1,1 @@
+5

Added: opensips/trunk/debian/control
URL: http://svn.debian.org/wsvn/pkg-voip/opensips/trunk/debian/control?rev=6757&op=file
==============================================================================
--- opensips/trunk/debian/control (added)
+++ opensips/trunk/debian/control Wed Feb 11 13:42:55 2009
@@ -1,0 +1,210 @@
+Source: opensips
+Section: net
+Priority: optional
+Maintainer: Debian VoIP Team <pkg-voip-maintainers at lists.alioth.debian.org>
+Uploaders: Bjoern Boschman <bjoern at boschman.de>
+Build-Depends: debhelper (>= 5), dpatch, libmysqlclient15-dev, libexpat1-dev, libxml2-dev, libpq-dev, libradiusclient-ng-dev, flex, bison, zlib1g-dev, unixodbc-dev, libxmlrpc-c3-dev, libperl-dev, libsnmp-dev, dpkg-dev (>= 1.13.19), libdb-dev (>= 4.6.19), xsltproc, libconfuse-dev, libldap2-dev, libcurl4-gnutls-dev
+Standards-Version: 3.8.0
+Homepage: http://www.opensips.org/
+Vcs-Svn: svn://svn.debian.org/pkg-voip/opensips/trunk/
+Vcs-Browser: http://svn.debian.org/wsvn/pkg-voip/opensips/?op=log
+
+Package: opensips
+Architecture: any
+Depends: ${shlibs:Depends}, ${misc:Depends}, adduser
+Suggests: opensips-mysql-module, opensips-postgres-module, opensips-unixodbc-module, opensips-jabber-module, opensips-cpl-module, opensips-radius-modules, opensips-presence-modules, opensips-xmlrpc-module, opensips-perl-modules, opensips-snmpstats-module, opensips-xmpp-module, opensips-carrierroute-module, opensips-berkeley-module, opensips-ldap-modules
+Description: very fast and configurable SIP proxy
+ opensips is a very fast and flexible SIP (RFC3261)
+ proxy server. Written entirely in C, opensips can handle thousands calls
+ per second even on low-budget hardware.
+ .
+ C Shell-like scripting language provides full control over the server's
+ behaviour. Its modular architecture allows only required functionality to be
+ loaded.
+ .
+ Among others, the following modules are available: digest authentication, CPL
+ scripts, instant messaging, MySQL support, presence agent, RADIUS
+ authentication, record routing, SMS gateway, Jabber/XMPP gateway, transaction
+ module, registrar and user location, XML-RPC interface.
+ .
+ This package contains the main opensips binary along with the principal modules
+ and support binaries.
+
+Package: opensips-dbg
+Priority: extra
+Architecture: any
+Depends: opensips (= ${binary:Version})
+Description: very fast and configurable SIP proxy [debug symbols]
+ opensips is a very fast and flexible SIP (RFC3261)
+ proxy server. Written entirely in C, opensips can handle thousands calls
+ per second even on low-budget hardware.
+ .
+ This package contains the debugging symbols for the opensips binaries and
+ modules. You only need to install it if you need to debug opensips.
+
+Package: opensips-mysql-module
+Architecture: any
+Depends: ${shlibs:Depends}, opensips (= ${binary:Version}), mysql-client
+Description: MySQL database connectivity module for opensips
+ opensips is a very fast and flexible SIP (RFC3261)
+ proxy server. Written entirely in C, opensips can handle thousands calls
+ per second even on low-budget hardware.
+ .
+ This package provides the MySQL database driver for opensips.
+
+Package: opensips-postgres-module
+Architecture: any
+Depends: ${shlibs:Depends}, opensips (= ${binary:Version}), postgresql-client
+Description: PostgreSQL database connectivity module for opensips
+ opensips is a very fast and flexible SIP (RFC3261)
+ proxy server. Written entirely in C, opensips can handle thousands calls
+ per second even on low-budget hardware.
+ .
+ This package provides the PostgreSQL database driver for opensips.
+
+Package: opensips-jabber-module
+Architecture: any
+Depends: ${shlibs:Depends}, opensips (= ${binary:Version})
+Description: Jabber gateway module for opensips
+ opensips is a very fast and flexible SIP (RFC3261)
+ proxy server. Written entirely in C, opensips can handle thousands calls
+ per second even on low-budget hardware.
+ .
+ This package provides the SIP to Jabber translator module for opensips.
+
+Package: opensips-cpl-module
+Architecture: any
+Depends: ${shlibs:Depends}, opensips (= ${binary:Version})
+Description: CPL module (CPL interpreter engine) for opensips
+ opensips is a very fast and flexible SIP (RFC3261)
+ proxy server. Written entirely in C, opensips can handle thousands calls
+ per second even on low-budget hardware.
+ .
+ This package provides a CPL (Call Processing Language) interpreter for
+ opensips, turning opensips into a CPL server (storage and interpreter).
+
+Package: opensips-radius-modules
+Architecture: any
+Depends: ${shlibs:Depends}, opensips (= ${binary:Version})
+Description: RADIUS modules for opensips
+ opensips is a very fast and flexible SIP (RFC3261)
+ proxy server. Written entirely in C, opensips can handle thousands calls
+ per second even on low-budget hardware.
+ .
+ This package provides a set of RADIUS modules for opensips, for
+ authentication, group membership and messages URIs checking against a
+ RADIUS server.
+
+Package: opensips-unixodbc-module
+Architecture: any
+Depends: ${shlibs:Depends}, opensips (= ${binary:Version})
+Description: unixODBC database connectivity module for opensips
+ opensips is a very fast and flexible SIP (RFC3261)
+ proxy server. Written entirely in C, opensips can handle thousands calls
+ per second even on low-budget hardware.
+ .
+ This package provides the unixODBC database driver for opensips.
+
+Package: opensips-presence-modules
+Architecture: any
+Depends: ${shlibs:Depends}, opensips (= ${binary:Version})
+Description: SIMPLE presence modules for opensips
+ opensips is a very fast and flexible SIP (RFC3261)
+ proxy server. Written entirely in C, opensips can handle thousands calls
+ per second even on low-budget hardware.
+ .
+ This package provides several opensips modules for implementing presence
+ server and presence user agent for RICH presence, registrar-based presence,
+ external triggered presence and XCAP support.
+
+Package: opensips-xmlrpc-module
+Architecture: any
+Depends: ${shlibs:Depends}, opensips (= ${binary:Version})
+Description: XML-RPC support for opensips's Management Interface
+ opensips is a very fast and flexible SIP (RFC3261)
+ proxy server. Written entirely in C, opensips can handle thousands calls
+ per second even on low-budget hardware.
+ .
+ This package provides the XMLRPC transport implementation for opensips's
+ Management Interface.
+
+Package: opensips-perl-modules
+Architecture: any
+Depends: ${shlibs:Depends}, opensips (= ${binary:Version})
+Replaces: opensips-perl-module
+Conflicts: opensips-perl-module
+Description: Perl extensions and database driver for opensips
+ opensips is a very fast and flexible SIP (RFC3261)
+ proxy server. Written entirely in C, opensips can handle thousands calls
+ per second even on low-budget hardware.
+ .
+ This package provides an interface for opensips to write Perl extensions and
+ the perlvdb database driver for opensips.
+
+Package: opensips-snmpstats-module
+Architecture: any
+Depends: ${shlibs:Depends}, opensips (= ${binary:Version}), snmpd
+Description: SNMP AgentX subagent module for opensips
+ opensips is a very fast and flexible SIP (RFC3261)
+ proxy server. Written entirely in C, opensips can handle thousands calls
+ per second even on low-budget hardware.
+ .
+ This package provides the snmpstats module for opensips. This module acts
+ as an AgentX subagent which connects to a master agent.
+
+Package: opensips-xmpp-module
+Architecture: any
+Depends: ${shlibs:Depends}, opensips (= ${binary:Version})
+Description: XMPP gateway module for opensips
+ opensips is a very fast and flexible SIP (RFC3261)
+ proxy server. Written entirely in C, opensips can handle thousands calls
+ per second even on low-budget hardware.
+ .
+ This package provides the SIP to XMPP IM translator module for opensips.
+
+Package: opensips-carrierroute-module
+Architecture: any
+Depends: ${shlibs:Depends}, opensips (= ${binary:Version})
+Description: carrierroute module for opensips
+ opensips is a very fast and flexible SIP (RFC3261)
+ proxy server. Written entirely in C, opensips can handle thousands calls
+ per second even on low-budget hardware.
+ .
+ This package provides the carrierroute module for opensips, an integrated
+ solution for routing, balancing and blacklisting.
+
+Package: opensips-berkeley-module
+Architecture: any
+Depends: ${shlibs:Depends}, opensips (= ${binary:Version}), db4.6-util
+Description: Berkeley database module for opensips
+ opensips is a very fast and flexible SIP (RFC3261)
+ proxy server. Written entirely in C, opensips can handle thousands calls
+ per second even on low-budget hardware.
+ .
+ This package provides the Berkeley database module for opensips, a
+ high-performance embedded DB kernel. All database tables are stored
+ in files, no additional server is necessary.
+
+Package: opensips-ldap-modules
+Architecture: any
+Depends: ${shlibs:Depends}, opensips (= ${binary:Version})
+Description: LDAP modules for opensips
+ opensips is a very fast and flexible SIP (RFC3261)
+ proxy server. Written entirely in C, opensips can handle thousands calls
+ per second even on low-budget hardware.
+ .
+ This package provides the ldap and h350 modules for opensips, enabling LDAP
+ queries from the opensips config and storage of SIP account data in an LDAP
+ directory.
+
+Package: opensips-osp-module
+Architecture: any
+Depends: ${shlibs:Depends}, opensips (= ${binary:Version}), osptoolkit
+Description: Open Settlement Protocol (OSP) module for opensips
+ opensips is a very fast and flexible SIP (RFC3261)
+ proxy server. Written entirely in C, opensips can handle thousands calls
+ per second even on low-budget hardware.
+ .
+ This package contains the Open Settlement Protocol (OSP) module for opensips,
+ providing support for secure multi-lateral peering using the Open Settlement
+ Protocol.

Propchange: opensips/trunk/debian/control
------------------------------------------------------------------------------
    svn:executable = *

Added: opensips/trunk/debian/copyright
URL: http://svn.debian.org/wsvn/pkg-voip/opensips/trunk/debian/copyright?rev=6757&op=file
==============================================================================
--- opensips/trunk/debian/copyright (added)
+++ opensips/trunk/debian/copyright Wed Feb 11 13:42:55 2009
@@ -1,0 +1,26 @@
+This package was debianized by Bjoern Boschman 
+<bjoern at boschman.de> on Wed, 11 Feb 2009 10:58.03 +0100
+based on the old opensips packaing stuff.
+
+It was downloaded from: http://opensips.org
+
+Upstream Authors:
+       Andrei Pelinescu-Onciul <pelinescu-onciul at fokus.fraunhofer.de>
+       Bogdan-Andrei Iancu <bogdan at voice-system.ro>
+       Daniel-Constantin Mierla <daniel at voice-system.ro>
+       Jan Janak <jan at iptel.org>
+       Jiri Kuthan <jiri at iptel.org>
+       Juha Heinanen <jh at tutpro.com>
+       Ramona-Elena Modroiu <ramona at voice-system.ro>
+       Maxim Sobolev 
+       Miklos Tirpak
+       Nils Ohlmeier <nils at iptel.org>
+       and others ; see the AUTHORS file in the source code tree for details
+
+       Part of this software is Copyright (c) 2002-2003 by FhG Fokus
+
+You are free to distribute this software under the terms of
+the GNU General Public License.
+
+On Debian systems, the complete text of the GNU General Public
+License can be found in the file `/usr/share/common-licenses/GPL.

Propchange: opensips/trunk/debian/copyright
------------------------------------------------------------------------------
    svn:executable = *

Added: opensips/trunk/debian/opensips-osp-module.examples
URL: http://svn.debian.org/wsvn/pkg-voip/opensips/trunk/debian/opensips-osp-module.examples?rev=6757&op=file
==============================================================================
--- opensips/trunk/debian/opensips-osp-module.examples (added)
+++ opensips/trunk/debian/opensips-osp-module.examples Wed Feb 11 13:42:55 2009
@@ -1,0 +1,2 @@
+modules/osp/etc/*
+

Added: opensips/trunk/debian/opensips.README.Debian
URL: http://svn.debian.org/wsvn/pkg-voip/opensips/trunk/debian/opensips.README.Debian?rev=6757&op=file
==============================================================================
--- opensips/trunk/debian/opensips.README.Debian (added)
+++ opensips/trunk/debian/opensips.README.Debian Wed Feb 11 13:42:55 2009
@@ -1,0 +1,72 @@
+OpenSIPS for Debian
+------------------
+
+* TLS support
+-------------
+
+Due to a license incompatibility between the GPL and the OpenSSL license, we
+cannot ship OpenSIPS with TLS enabled.
+
+However, if you need OpenSIPS with TLS, it's easy to get it:
+ - apt-get build-dep opensips
+ - apt-get install libssl-dev fakeroot build-essential
+ - apt-get source opensips
+ - edit opensips-.../debian/rules and set TLS to 1
+ - run dpkg-buildpackage -rfakeroot
+
+The resulting OpenSIPS packages will have TLS enabled.
+
+
+* OSP module
+------------
+
+Due to the same license incompatibility, it's equally impossible to ship the
+OSP module.
+
+However, once again, if you need the OSP module, it's easy to get it:
+ - apt-get build-dep opensips
+ - apt-get install libosptk3-dev fakeroot build-essential
+ - apt-get source opensips
+ - edit opensips-.../debian/rules and set OSP to 1
+ - run dpkg-buildpackage -rfakeroot
+
+An opensips-osp-module package will be built alongside all the other OpenSIPS
+packages.
+
+
+* init script check for fork=no
+-------------------------------
+
+The OpenSIPS init script will not start OpenSIPS on boot if fork=no is
+specified in the config file. The check in the initscript will match
+any occurrence of fork=no in the file, even inside C-style comments.
+
+You can disable this check in the init script if you wish; just comment
+out the calls to the check_fork function in the script. Your changes to
+the init script will be preserved upon upgrade, as the file is tagged
+as a conffile.
+
+
+* OpenSIPS setup
+---------------
+
+To setup OpenSIPS, you need to:
+ - configure OpenSIPS properly to suit your needs
+ - edit /etc/default/opensips, adjust the MEMORY parameter and set
+   RUN_OPENSIPS to "yes"
+
+If you are building an HA cluster using heartbeat or similar, you'll want
+to disable the init script by running:
+
+  update-rc.d opensips remove
+
+so that OpenSIPS will not be launched at system startup. You still need
+to set RUN_OPENSIPS to "yes" if you want to use the /etc/init.d/opensips init
+script.
+
+Set the DUMP_CORE parameter in /etc/default/opensips to "yes" if you want to
+get a core dump in case OpenSIPS crashes. The debug symbols for OpenSIPS are
+provided by the opensips-dbg package.
+
+
+ -- Julien BLACHE <jblache at debian.org>, Tue, 06 May 2008 19:20:43 +0200

Propchange: opensips/trunk/debian/opensips.README.Debian
------------------------------------------------------------------------------
    svn:executable = *

Added: opensips/trunk/debian/opensips.default
URL: http://svn.debian.org/wsvn/pkg-voip/opensips/trunk/debian/opensips.default?rev=6757&op=file
==============================================================================
--- opensips/trunk/debian/opensips.default (added)
+++ opensips/trunk/debian/opensips.default Wed Feb 11 13:42:55 2009
@@ -1,0 +1,21 @@
+#
+# OpenSIPS startup options
+#
+
+# Set to yes to enable opensips, once configured properly.
+RUN_OPENSIPS=no
+
+# User to run as
+USER=opensips
+
+# Group to run as
+GROUP=opensips
+
+# Amount of memory to allocate for the running OpenSIPS server (in Mb)
+MEMORY=64
+
+# Enable the server to leave a core file when it crashes.
+# Set this to 'yes' to enable OpenSIPS to leave a core file when it crashes
+# or 'no' to disable this feature. This option is case sensitive and only
+# accepts 'yes' and 'no' and only in lowercase letters.
+DUMP_CORE=no

Propchange: opensips/trunk/debian/opensips.default
------------------------------------------------------------------------------
    svn:executable = *

Added: opensips/trunk/debian/opensips.dirs
URL: http://svn.debian.org/wsvn/pkg-voip/opensips/trunk/debian/opensips.dirs?rev=6757&op=file
==============================================================================
--- opensips/trunk/debian/opensips.dirs (added)
+++ opensips/trunk/debian/opensips.dirs Wed Feb 11 13:42:55 2009
@@ -1,0 +1,2 @@
+var/run/opensips
+

Propchange: opensips/trunk/debian/opensips.dirs
------------------------------------------------------------------------------
    svn:executable = *

Added: opensips/trunk/debian/opensips.examples
URL: http://svn.debian.org/wsvn/pkg-voip/opensips/trunk/debian/opensips.examples?rev=6757&op=file
==============================================================================
--- opensips/trunk/debian/opensips.examples (added)
+++ opensips/trunk/debian/opensips.examples Wed Feb 11 13:42:55 2009
@@ -1,0 +1,2 @@
+examples/*
+

Added: opensips/trunk/debian/opensips.init
URL: http://svn.debian.org/wsvn/pkg-voip/opensips/trunk/debian/opensips.init?rev=6757&op=file
==============================================================================
--- opensips/trunk/debian/opensips.init (added)
+++ opensips/trunk/debian/opensips.init Wed Feb 11 13:42:55 2009
@@ -1,0 +1,159 @@
+#! /bin/sh
+#
+### BEGIN INIT INFO
+# Provides:          opensips
+# Required-Start:    $syslog $network $local_fs $time
+# Should-Start:      $named slapd mysql postgresql snmpd radiusd
+# Should-Stop:       $named slapd mysql postgresql snmpd radiusd
+# Required-Stop:     $syslog $network $local_fs
+# Default-Start:     2 3 4 5
+# Default-Stop:      0 1 6
+# Short-Description: Start the OpenSIPS SIP proxy server
+# Description:       Start the OpenSIPS SIP proxy server
+### END INIT INFO
+
+PATH=/sbin:/bin:/usr/sbin:/usr/bin
+DAEMON=/usr/sbin/opensips
+NAME=opensips
+DESC=opensips
+HOMEDIR=/var/run/opensips
+PIDFILE=$HOMEDIR/$NAME.pid
+DEFAULTS=/etc/default/opensips
+RUN_OPENSIPS=no
+
+# Do not start opensips if fork=no is set in the config file
+# otherwise the boot process will just stop
+check_fork ()
+{
+    if grep -q "^[[:space:]]*fork[[:space:]]*=[[:space:]]*no.*" /etc/opensips/opensips.cfg; then
+	echo "Not starting $DESC: fork=no specified in config file; run /etc/init.d/opensips debug instead"
+	exit 0
+    fi
+}
+
+check_opensips_config ()
+{
+	# Check if opensips configuration is valid before starting the server
+	set +e
+	out=$($DAEMON -c 2>&1 > /dev/null)
+	retcode=$?
+	set -e
+	if [ "$retcode" != '0' ]; then
+	    echo "Not starting $DESC: invalid configuration file!"
+	    echo
+	    echo "$out"
+	    echo
+	    exit 1
+	fi
+}
+
+create_radius_seqfile ()
+{
+    # Create a radius sequence file to be used by the radius client if
+    # radius accounting is enabled. This is needed to avoid any issue
+    # with the file not being writable if opensips first starts as user
+    # root because DUMP_CORE is enabled and creates this file as user
+    # root and then later it switches back to user opensips and cannot
+    # write to the file. If the file exists before opensips starts, it
+    # won't change it's ownership and will be writable for both root
+    # and opensips, no matter what options are chosen at install time
+    RADIUS_SEQ_FILE=/var/run/opensips/opensips_radius.seq
+    if [ -d /var/run/opensips ]; then
+	chown ${USER}:${GROUP} /var/run/opensips
+
+	if [ ! -f $RADIUS_SEQ_FILE ]; then
+	    touch $RADIUS_SEQ_FILE
+	fi
+
+	chown ${USER}:${GROUP} $RADIUS_SEQ_FILE
+	chmod 660 $RADIUS_SEQ_FILE
+    fi
+}
+
+test -f $DAEMON || exit 0
+
+# Load startup options if available
+if [ -f $DEFAULTS ]; then
+   . $DEFAULTS || true
+fi
+
+if [ "$RUN_OPENSIPS" != "yes" ]; then
+    echo "OpenSIPS not yet configured. Edit /etc/default/opensips first."
+    exit 0
+fi
+
+set -e
+
+MEMORY=$((`echo $MEMORY | sed -e 's/[^0-9]//g'`))
+[ -z "$USER" ]  && USER=opensips
+[ -z "$GROUP" ] && GROUP=opensips
+[ $MEMORY -le 0 ] && MEMORY=32
+
+if test "$DUMP_CORE" = "yes" ; then
+    # set proper ulimit
+    ulimit -c unlimited
+fi
+
+# /var/run can be a tmpfs
+if [ ! -d $HOMEDIR ]; then
+    mkdir -p $HOMEDIR
+fi
+
+OPTIONS="-P $PIDFILE -m $MEMORY -u $USER -g $GROUP"
+
+case "$1" in
+  start|debug)
+	check_opensips_config
+	create_radius_seqfile
+
+	if [ "$1" != "debug" ]; then
+	    check_fork
+	fi
+
+	echo -n "Starting $DESC: $NAME"
+	start-stop-daemon --start --quiet --pidfile $PIDFILE \
+		--exec $DAEMON -- $OPTIONS || echo -n " already running"
+	echo "."
+	;;
+  stop)
+	echo -n "Stopping $DESC: $NAME"
+	start-stop-daemon --oknodo --stop --quiet --pidfile $PIDFILE \
+		--exec $DAEMON
+	echo "."
+	;;
+  restart|force-reload)
+	check_opensips_config
+	create_radius_seqfile
+
+	echo -n "Restarting $DESC: $NAME"
+	start-stop-daemon --oknodo --stop --quiet --pidfile \
+		$PIDFILE --exec $DAEMON
+	sleep 1
+	start-stop-daemon --start --quiet --pidfile \
+		$PIDFILE --exec $DAEMON  -- $OPTIONS
+	echo "."
+	;;
+  status)
+       echo -n "Status of $DESC: "
+
+       if [ ! -r "$PIDFILE" ]; then
+	   echo "$NAME is not running."
+	   exit 3
+       fi
+
+       if read pid < "$PIDFILE" && ps -p "$pid" > /dev/null 2>&1; then
+	   echo "$NAME is running."
+	   exit 0
+       else
+	   echo "$NAME is not running but $PIDFILE exists."
+	   exit 1
+       fi
+       ;;
+  *)
+	N=/etc/init.d/$NAME
+	echo "Usage: $N {start|stop|restart|force-reload|status|debug}" >&2
+	exit 1
+	;;
+esac
+
+exit 0

Propchange: opensips/trunk/debian/opensips.init
------------------------------------------------------------------------------
    svn:executable = *

Added: opensips/trunk/debian/opensips.postinst
URL: http://svn.debian.org/wsvn/pkg-voip/opensips/trunk/debian/opensips.postinst?rev=6757&op=file
==============================================================================
--- opensips/trunk/debian/opensips.postinst (added)
+++ opensips/trunk/debian/opensips.postinst Wed Feb 11 13:42:55 2009
@@ -1,0 +1,48 @@
+#! /bin/sh
+#
+# $Id: opensips.postinst,v 1.1.2.4 2006/02/03 18:28:19 dan_pascu Exp $
+
+PKG=opensips
+DEFAULTS=/etc/default/opensips
+HOMEDIR=/var/run/opensips
+
+set -e
+
+# summary of how this script can be called:
+#        * <postinst> `configure' <most-recently-configured-version>
+#        * <old-postinst> `abort-upgrade' <new version>
+#        * <conflictor's-postinst> `abort-remove' `in-favour' <package>
+#          <new-version>
+#        * <deconfigured's-postinst> `abort-deconfigure' `in-favour'
+#          <failed-install-package> <version> `removing'
+#          <conflicting-package> <version>
+# for details, see http://www.debian.org/doc/debian-policy/ or
+# the debian-policy package
+#
+# quoting from the policy:
+#     Any necessary prompting should almost always be confined to the
+#     post-installation script, and should be protected with a conditional
+#     so that unnecessary prompting doesn't happen if a package's
+#     installation fails and the `postinst' is called with `abort-upgrade',
+#     `abort-remove' or `abort-deconfigure'.
+
+case "$1" in
+    configure)
+        adduser --quiet --system --group --disabled-password \
+                --shell /bin/false --gecos "OpenSIPS" \
+                --home $HOMEDIR opensips || true
+
+        ;;
+
+    abort-upgrade|abort-remove|abort-deconfigure)
+
+        ;;
+
+    *)
+        echo "postinst called with unknown argument \`$1'" >&2
+        exit 1
+        ;;
+esac
+
+#DEBHELPER#
+

Propchange: opensips/trunk/debian/opensips.postinst
------------------------------------------------------------------------------
    svn:executable = *

Added: opensips/trunk/debian/rules
URL: http://svn.debian.org/wsvn/pkg-voip/opensips/trunk/debian/rules?rev=6757&op=file
==============================================================================
--- opensips/trunk/debian/rules (added)
+++ opensips/trunk/debian/rules Wed Feb 11 13:42:55 2009
@@ -1,0 +1,355 @@
+#!/usr/bin/make -f
+# Sample debian/rules that uses debhelper.
+# GNU copyright 1997 to 1999 by Joey Hess.
+
+DEB_HOST_ARCH ?= $(shell dpkg-architecture -qDEB_HOST_ARCH)
+
+ALL_PACKAGES = opensips opensips-mysql-module opensips-postgres-module \
+	opensips-jabber-module opensips-cpl-module opensips-radius-modules \
+	opensips-unixodbc-module opensips-presence-modules opensips-xmlrpc-module \
+	opensips-perl-modules opensips-snmpstats-module opensips-xmpp-module \
+	opensips-carrierroute-module opensips-berkeley-module opensips-ldap-modules
+
+DEBVERSION:=$(shell head -n 1 debian/changelog \
+                    | sed -e 's/^[^(]*(\([^)]*\)).*/\1/')
+UPVERSION:=$(shell echo $(DEBVERSION) | sed -e 's/^.*://' -e 's/-[0-9.]*$$//' -e 's/.dfsg$$//')
+
+FILENAME := opensips_$(UPVERSION).orig.tar.gz
+UPFILENAME := opensips-$(UPVERSION)-tls_src.tar.gz
+URL := http://opensips.org/pub/opensips/$(UPVERSION)/src/opensips-$(UPVERSION)-tls_src.tar.gz
+
+# Uncomment this to turn on verbose mode.
+# export DH_VERBOSE=1
+
+# Include dpatch rules
+include /usr/share/dpatch/dpatch.make
+
+
+# Do we want the TLS version ?
+# Disabled by default due to license issues, set to non-void to enable
+TLS=
+
+# Do we want to build the OSP module ?
+# Disabled by default due to license issues, set to non-void to enable
+OSP=
+
+ifeq (,$(OSP))
+	DH_OPTIONS = -Nopensips-osp-module
+else
+	ALL_PACKAGES += opensips-osp-module
+endif
+
+export DH_OPTIONS
+
+# modules depending on mysql
+MYSQL_MODULES = db_mysql
+# modules depending on postgres
+POSTGRES_MODULES = db_postgres
+# modules depending on unixODBC
+UNIXODBC_MODULES=db_unixodbc
+# jabber module
+JABBER_MODULES = jabber
+# cpl related modules
+CPL_MODULES = cpl-c
+# module depending on radiusclient
+RADIUS_MODULES = avp_radius auth_radius group_radius uri_radius
+# presence related modules
+PRESENCE_MODULES = presence presence_xml presence_mwi pua pua_bla pua_mi pua_usrloc pua_xmpp xcap_client
+# XMLRPC module
+XMLRPC_MODULES = mi_xmlrpc
+# Perl module
+PERL_MODULES = perl perlvdb
+# SNMPstats module
+SNMPSTATS_MODULES = snmpstats
+# XMPP module
+XMPP_MODULES = xmpp
+# Carrierroute module
+CROUTE_MODULES = carrierroute
+# Berkeley DB module
+BERKELEY_MODULES = db_berkeley
+# LDAP modules
+LDAP_MODULES = ldap h350
+# OSP module
+OSP_MODULES = osp
+
+ALL_MODULES = $(MYSQL_MODULES) $(POSTGRES_MODULES) $(UNIXODBC_MODULES) $(JABBER_MODULES) $(CPL_MODULES) $(RADIUS_MODULES) $(PRESENCE_MODULES) $(XMLRPC_MODULES) $(PERL_MODULES) $(SNMPSTATS_MODULES) $(XMPP_MODULES) $(CROUTE_MODULES) $(BERKELEY_MODULES) $(LDAP_MODULES) $(OSP_MODULES)
+
+# modules not in the "main" package or unstable modules
+EXCLUDED_MODULES = $(ALL_MODULES) pa
+
+# the same but with path prepended (needed for modules="...")
+MYSQL_MOD_PATH=$(addprefix modules/, $(MYSQL_MODULES))
+POSTGRES_MOD_PATH=$(addprefix modules/, $(POSTGRES_MODULES))
+UNIXODBC_MOD_PATH=$(addprefix modules/, $(UNIXODBC_MODULES))
+JABBER_MOD_PATH=$(addprefix modules/, $(JABBER_MODULES))
+CPL_MOD_PATH=$(addprefix modules/, $(CPL_MODULES))
+RADIUS_MOD_PATH=$(addprefix modules/, $(RADIUS_MODULES))
+PRESENCE_MOD_PATH=$(addprefix modules/, $(PRESENCE_MODULES))
+XMLRPC_MOD_PATH=$(addprefix modules/, $(XMLRPC_MODULES))
+PERL_MOD_PATH=$(addprefix modules/, $(PERL_MODULES))
+SNMPSTATS_MOD_PATH=$(addprefix modules/, $(SNMPSTATS_MODULES))
+XMPP_MOD_PATH=$(addprefix modules/, $(XMPP_MODULES))
+CROUTE_MOD_PATH=$(addprefix modules/, $(CROUTE_MODULES))
+BERKELEY_MOD_PATH=$(addprefix modules/, $(BERKELEY_MODULES))
+LDAP_MOD_PATH=$(addprefix modules/, $(LDAP_MODULES))
+OSP_MOD_PATH=$(addprefix modules/, $(OSP_MODULES))
+
+ifeq (cc, $(CC))
+	CC = gcc
+endif
+
+CFLAGS = -Wall -g
+
+ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS)))
+        CFLAGS += -O0
+else
+	CFLAGS += -O2
+endif
+
+ifeq (,$(findstring nostrip,$(DEB_BUILD_OPTIONS)))
+	INSTALL_PROGRAM += -s
+endif
+
+configure: configure-stamp
+configure-stamp:
+	dh_testdir
+	# Add here commands to configure the package.
+
+	touch configure-stamp
+
+
+build: build-stamp
+build-stamp: patch-stamp configure-stamp
+	dh_testdir
+
+	# Add here commands to compile the package.
+	CC="$(CC)" CFLAGS="$(CFLAGS)" TLS=$(TLS) $(MAKE) all skip_modules="$(EXCLUDED_MODULES)" cfg-target=/etc/opensips/
+	CC="$(CC)" CFLAGS="$(CFLAGS)" TLS=$(TLS) $(MAKE) modules modules="$(MYSQL_MOD_PATH)" cfg-target=/etc/opensips/
+	CC="$(CC)" CFLAGS="$(CFLAGS)" TLS=$(TLS) $(MAKE) modules modules="$(POSTGRES_MOD_PATH)" cfg-target=/etc/opensips/
+	CC="$(CC)" CFLAGS="$(CFLAGS)" TLS=$(TLS) $(MAKE) modules modules="$(UNIXODBC_MOD_PATH)" cfg-target=/etc/opensips/
+	CC="$(CC)" CFLAGS="$(CFLAGS)" TLS=$(TLS) $(MAKE) modules modules="$(JABBER_MOD_PATH)" cfg-target=/etc/opensips/
+	CC="$(CC)" CFLAGS="$(CFLAGS)" TLS=$(TLS) $(MAKE) modules modules="$(CPL_MOD_PATH)" cfg-target=/etc/opensips/
+	CC="$(CC)" CFLAGS="$(CFLAGS)" TLS=$(TLS) $(MAKE) modules modules="$(RADIUS_MOD_PATH)" cfg-target=/etc/opensips/
+	CC="$(CC)" CFLAGS="$(CFLAGS)" TLS=$(TLS) $(MAKE) modules modules="$(PRESENCE_MOD_PATH)" cfg-target=/etc/opensips/
+	CC="$(CC)" CFLAGS="$(CFLAGS)" TLS=$(TLS) $(MAKE) modules modules="$(XMLRPC_MOD_PATH)" cfg-target=/etc/opensips/
+	CC="$(CC)" CFLAGS="$(CFLAGS)" TLS=$(TLS) $(MAKE) modules modules="$(PERL_MOD_PATH)" cfg-target=/etc/opensips/
+	CC="$(CC)" CFLAGS="$(CFLAGS)" TLS=$(TLS) $(MAKE) modules modules="$(SNMPSTATS_MOD_PATH)" cfg-target=/etc/opensips/
+	CC="$(CC)" CFLAGS="$(CFLAGS)" TLS=$(TLS) $(MAKE) modules modules="$(XMPP_MOD_PATH)" cfg-target=/etc/opensips/
+	CC="$(CC)" CFLAGS="$(CFLAGS)" TLS=$(TLS) $(MAKE) modules modules="$(CROUTE_MOD_PATH)" cfg-target=/etc/opensips/
+	CC="$(CC)" CFLAGS="$(CFLAGS)" TLS=$(TLS) $(MAKE) modules modules="$(BERKELEY_MOD_PATH)" cfg-target=/etc/opensips/
+	CC="$(CC)" CFLAGS="$(CFLAGS)" TLS=$(TLS) $(MAKE) modules modules="$(LDAP_MOD_PATH)" cfg-target=/etc/opensips/
+ifneq (,$(OSP))
+	CC="$(CC)" CFLAGS="$(CFLAGS)" TLS=$(TLS) $(MAKE) modules modules="$(OSP_MOD_PATH)" cfg-target=/etc/opensips/
+endif
+
+	# generate the db schemas
+	$(MAKE) dbschema
+
+	# generate the utils db_berkeley
+	CC="$(CC)" CFLAGS="$(CFLAGS)" TLS=$(TLS) $(MAKE) utils include_modules="db_berkeley"
+
+	touch build-stamp
+
+clean: real-clean unpatch
+real-clean:
+	dh_testdir
+	dh_testroot
+	rm -f build-stamp configure-stamp
+
+	# Add here commands to clean up after the build process.
+	$(MAKE) TLS=$(TLS) include_modules="$(ALL_MODULES)" clean
+	rm -f cfg.tab.h
+	rm -f utils/opensipsunix/opensipsunix.o utils/opensipsunix/opensipsunix
+	rm -f utils/db_berkeley/bdb_recover.o utils/db_berkeley/bdb_recover
+
+	dh_clean
+
+install: build
+	dh_testdir
+	dh_testroot
+	dh_clean -k
+	dh_installdirs
+
+	# Add here commands to install the package into debian/opensips
+	# opensips base package
+	CC="$(CC)" CFLAGS="$(CFLAGS)" TLS=$(TLS) $(MAKE) install skip_modules="$(EXCLUDED_MODULES)" \
+		basedir=$(CURDIR)/debian/opensips \
+		prefix=/usr \
+		cfg-prefix=$(CURDIR)/debian/opensips \
+		cfg-target=/etc/opensips/ \
+		doc-dir=share/doc/opensips
+
+	find $(CURDIR)/debian/opensips/etc/opensips -type f -exec chmod -x {} \;
+	sed -i -e "s/^PATH.*//" $(CURDIR)/debian/opensips/usr/sbin/opensipsctl
+
+	# install only the mysql module
+	CC="$(CC)" CFLAGS="$(CFLAGS)" TLS=$(TLS) $(MAKE) install-modules-all modules="$(MYSQL_MOD_PATH)"  \
+		basedir=$(CURDIR)/debian/opensips-mysql-module \
+		prefix=/usr \
+		cfg-prefix=$(CURDIR)/debian/opensips-mysql-module \
+		cfg-target=/etc/opensips/ \
+		doc-dir=share/doc/opensips-mysql-module
+
+	# install only the postgres module
+	CC="$(CC)" CFLAGS="$(CFLAGS)" TLS=$(TLS) $(MAKE) install-modules-all modules="$(POSTGRES_MOD_PATH)"  \
+		basedir=$(CURDIR)/debian/opensips-postgres-module \
+		prefix=/usr \
+		cfg-prefix=$(CURDIR)/debian/opensips-postgres-module \
+		cfg-target=/etc/opensips/ \
+		doc-dir=share/doc/opensips-postgres-module
+
+	# install only the unixodbc module
+	CC="$(CC)" CFLAGS="$(CFLAGS)" TLS=$(TLS) $(MAKE) install-modules-all modules="$(UNIXODBC_MOD_PATH)"  \
+		basedir=$(CURDIR)/debian/opensips-unixodbc-module \
+		prefix=/usr \
+		cfg-prefix=$(CURDIR)/debian/opensips-unixodbc-module \
+		cfg-target=/etc/opensips/ \
+		doc-dir=share/doc/opensips-unixodbc-module
+
+	# install only the jabber module
+	CC="$(CC)" CFLAGS="$(CFLAGS)" TLS=$(TLS) $(MAKE) install-modules-all modules="$(JABBER_MOD_PATH)"  \
+		basedir=$(CURDIR)/debian/opensips-jabber-module \
+		prefix=/usr \
+		cfg-prefix=$(CURDIR)/debian/opensips-jabber-module \
+		cfg-target=/etc/opensips/ \
+		doc-dir=share/doc/opensips-jabber-module
+
+	# install only the cpl module
+	CC="$(CC)" CFLAGS="$(CFLAGS)" TLS=$(TLS) $(MAKE) install-modules-all modules="$(CPL_MOD_PATH)"  \
+		basedir=$(CURDIR)/debian/opensips-cpl-module \
+		prefix=/usr \
+		cfg-prefix=$(CURDIR)/debian/opensips-cpl-module \
+		cfg-target=/etc/opensips/ \
+		doc-dir=share/doc/opensips-cpl-module
+
+	# install only the radius modules
+	CC="$(CC)" CFLAGS="$(CFLAGS)" TLS=$(TLS) $(MAKE) install-modules-all modules="$(RADIUS_MOD_PATH)"  \
+		basedir=$(CURDIR)/debian/opensips-radius-modules \
+		prefix=/usr \
+		cfg-prefix=$(CURDIR)/debian/opensips-radius-modules \
+		cfg-target=/etc/opensips/ \
+		doc-dir=share/doc/opensips-radius-modules
+
+	mkdir -p $(CURDIR)/debian/opensips-radius-modules/etc/opensips/
+	# mv $(CURDIR)/debian/opensips/etc/opensips/dictionary.radius $(CURDIR)/debian/opensips-radius-modules/etc/opensips/
+
+	# install only the presence modules
+	CC="$(CC)" CFLAGS="$(CFLAGS)" TLS=$(TLS) $(MAKE) install-modules-all modules="$(PRESENCE_MOD_PATH)"  \
+		basedir=$(CURDIR)/debian/opensips-presence-modules \
+		prefix=/usr \
+		cfg-prefix=$(CURDIR)/debian/opensips-presence-modules \
+		cfg-target=/etc/opensips/ \
+		doc-dir=share/doc/opensips-presence-modules
+
+	# install only the xmlrpc module
+	CC="$(CC)" CFLAGS="$(CFLAGS)" TLS=$(TLS) $(MAKE) install-modules-all modules="$(XMLRPC_MOD_PATH)"  \
+		basedir=$(CURDIR)/debian/opensips-xmlrpc-module \
+		prefix=/usr \
+		cfg-prefix=$(CURDIR)/debian/opensips-xmlrpc-module \
+		cfg-target=/etc/opensips/ \
+		doc-dir=share/doc/opensips-xmlrpc-module
+
+	# install only the perl modules
+	CC="$(CC)" CFLAGS="$(CFLAGS)" TLS=$(TLS) $(MAKE) install-modules-all modules="$(PERL_MOD_PATH)"  \
+		basedir=$(CURDIR)/debian/opensips-perl-modules \
+		prefix=/usr \
+		cfg-prefix=$(CURDIR)/debian/opensips-perl-modules \
+		cfg-target=/etc/opensips/ \
+		doc-dir=share/doc/opensips-perl-modules
+
+	# install only the snmpstats module
+	CC="$(CC)" CFLAGS="$(CFLAGS)" TLS=$(TLS) $(MAKE) install-modules-all modules="$(SNMPSTATS_MOD_PATH)"  \
+		basedir=$(CURDIR)/debian/opensips-snmpstats-module \
+		prefix=/usr \
+		cfg-prefix=$(CURDIR)/debian/opensips-snmpstats-module \
+		cfg-target=/etc/opensips/ \
+		doc-dir=share/doc/opensips-snmpstats-module
+
+	# install only the xmpp module
+	CC="$(CC)" CFLAGS="$(CFLAGS)" TLS=$(TLS) $(MAKE) install-modules-all modules="$(XMPP_MOD_PATH)"  \
+		basedir=$(CURDIR)/debian/opensips-xmpp-module \
+		prefix=/usr \
+		cfg-prefix=$(CURDIR)/debian/opensips-xmpp-module \
+		cfg-target=/etc/opensips/ \
+		doc-dir=share/doc/opensips-xmpp-module
+
+	# install only the carrierroute module
+	CC="$(CC)" CFLAGS="$(CFLAGS)" TLS=$(TLS) $(MAKE) install-modules-all modules="$(CROUTE_MOD_PATH)"  \
+		basedir=$(CURDIR)/debian/opensips-carrierroute-module \
+		prefix=/usr \
+		cfg-prefix=$(CURDIR)/debian/opensips-carrierroute-module \
+		cfg-target=/etc/opensips/ \
+		doc-dir=share/doc/opensips-carrierroute-module
+
+	# install only the db_berkeley module
+	CC="$(CC)" CFLAGS="$(CFLAGS)" TLS=$(TLS) $(MAKE) install-modules-all modules="$(BERKELEY_MOD_PATH)"  \
+		basedir=$(CURDIR)/debian/opensips-berkeley-module \
+		prefix=/usr \
+		cfg-prefix=$(CURDIR)/debian/opensips-berkeley-module \
+		cfg-target=/etc/opensips/ \
+		doc-dir=share/doc/opensips-berkeley-module
+
+	# install only the ldap modules
+	CC="$(CC)" CFLAGS="$(CFLAGS)" TLS=$(TLS) $(MAKE) install-modules-all modules="$(LDAP_MOD_PATH)"  \
+		basedir=$(CURDIR)/debian/opensips-ldap-modules \
+		prefix=/usr \
+		cfg-prefix=$(CURDIR)/debian/opensips-ldap-modules \
+		cfg-target=/etc/opensips/ \
+		doc-dir=share/doc/opensips-ldap-modules
+
+ifneq (,$(OSP))
+	# install only the OSP module
+	CC="$(CC)" CFLAGS="$(CFLAGS)" TLS=$(TLS) $(MAKE) install-modules-all modules="$(OSP_MOD_PATH)"  \
+		basedir=$(CURDIR)/debian/opensips-osp-module \
+		prefix=/usr \
+		cfg-prefix=$(CURDIR)/debian/opensips-osp-module \
+		cfg-target=/etc/opensips/ \
+		doc-dir=share/doc/opensips-osp-module
+endif
+
+	# the modules packages all ship an empty /usr/sbin directory, let's clean that up
+	for p in $(ALL_PACKAGES); \
+		do rmdir --ignore-fail-on-non-empty $(CURDIR)/debian/$$p/usr/sbin; done
+
+# This single target is used to build all the packages, all at once, or
+# one at a time. So keep in mind: any options passed to commands here will
+# affect _all_ packages. Anything you want to only affect one package
+# should be put in another target, such as the install target.
+binary-arch: build install
+	dh_testdir
+	dh_testroot
+	dh_installdocs
+	dh_installexamples
+#	dh_installlogrotate
+	dh_installinit -popensips -- defaults 23
+	dh_installcron
+	dh_installman
+	dh_installinfo
+	dh_installchangelogs
+	dh_link
+	dh_strip --dbg-package=opensips-dbg
+	dh_compress
+	dh_fixperms
+	dh_installdeb
+	dh_shlibdeps
+	dh_gencontrol
+	dh_md5sums
+	dh_builddeb
+
+# Build architecture-independent packages using the common target
+binary-indep: build install
+# We have nothing to do by default.
+
+binary: binary-indep binary-arch
+
+print-version:
+	@@echo "Debian version:          $(DEBVERSION)"
+	@@echo "Upstream version:        $(UPVERSION)"
+
+get-orig-source:
+	@@dh_testdir
+	@@[ -d ../tarballs/. ]||mkdir -p ../tarballs
+	@@echo Downloading $(FILENAME) from $(URL) ...
+	@@wget -nv -T10 -t3 -O ../tarballs/$(FILENAME) $(URL)
+
+.PHONY: build clean binary-indep binary-arch binary install configure patch unpatch real-clean

Propchange: opensips/trunk/debian/rules
------------------------------------------------------------------------------
    svn:executable = *

Added: opensips/trunk/debian/watch
URL: http://svn.debian.org/wsvn/pkg-voip/opensips/trunk/debian/watch?rev=6757&op=file
==============================================================================
--- opensips/trunk/debian/watch (added)
+++ opensips/trunk/debian/watch Wed Feb 11 13:42:55 2009
@@ -1,0 +1,2 @@
+version=3
+http://opensips.org/pub/opensips/([\d.]+)/src/opensips-([\d.]+)-tls_src\.tar\.gz

Propchange: opensips/trunk/debian/watch
------------------------------------------------------------------------------
    svn:executable = *




More information about the Pkg-voip-commits mailing list