summaryrefslogtreecommitdiffstats
path: root/net/asterisk-devel
diff options
context:
space:
mode:
authorluigi <luigi@FreeBSD.org>2006-02-14 10:30:37 +0000
committerluigi <luigi@FreeBSD.org>2006-02-14 10:30:37 +0000
commit72de37167a54cc8f11b2650fd3a6aa5731e11f4b (patch)
treeee2f989c1f56d99004c7bc9fe84079b224523b94 /net/asterisk-devel
parent1a5f057c9d508ae271bb51257b9313c507bb4a26 (diff)
downloadFreeBSD-ports-72de37167a54cc8f11b2650fd3a6aa5731e11f4b.zip
FreeBSD-ports-72de37167a54cc8f11b2650fd3a6aa5731e11f4b.tar.gz
update asterisk-devel after repo-copy
Diffstat (limited to 'net/asterisk-devel')
-rw-r--r--net/asterisk-devel/Makefile207
-rw-r--r--net/asterisk-devel/distinfo6
-rw-r--r--net/asterisk-devel/files/asterisk.sh.in25
-rw-r--r--net/asterisk-devel/files/patch-Makefile515
-rw-r--r--net/asterisk-devel/files/patch-agi::Makefile28
-rw-r--r--net/asterisk-devel/files/patch-apps::Makefile79
-rw-r--r--net/asterisk-devel/files/patch-apps::app_rxfax.c379
-rw-r--r--net/asterisk-devel/files/patch-apps::app_txfax.c301
-rw-r--r--net/asterisk-devel/files/patch-cdr::Makefile70
-rw-r--r--net/asterisk-devel/files/patch-channels::Makefile85
-rw-r--r--net/asterisk-devel/files/patch-channels::chan_sip.c131
-rw-r--r--net/asterisk-devel/files/patch-channels::chan_zap.c80
-rw-r--r--net/asterisk-devel/files/patch-channels::h323::ast_h323.cpp16
-rw-r--r--net/asterisk-devel/files/patch-channels::h323::ast_h323.h16
-rw-r--r--net/asterisk-devel/files/patch-codecs::Makefile53
-rw-r--r--net/asterisk-devel/files/patch-codecs::gsm::Makefile16
-rw-r--r--net/asterisk-devel/files/patch-codecs::ilbc::Makefile12
-rw-r--r--net/asterisk-devel/files/patch-configs::musiconhold.conf.sample14
-rw-r--r--net/asterisk-devel/files/patch-db.c21
-rw-r--r--net/asterisk-devel/files/patch-editline::configure14
-rw-r--r--net/asterisk-devel/files/patch-editline::makelist14
-rw-r--r--net/asterisk-devel/files/patch-formats::Makefile23
-rw-r--r--net/asterisk-devel/files/patch-formats::format_g723_1.c354
-rw-r--r--net/asterisk-devel/files/patch-formats::format_g729.c47
-rw-r--r--net/asterisk-devel/files/patch-frame.c14
-rw-r--r--net/asterisk-devel/files/patch-funcs::Makefile14
-rw-r--r--net/asterisk-devel/files/patch-include::asterisk::utils.h13
-rw-r--r--net/asterisk-devel/files/patch-pbx::Makefile25
-rw-r--r--net/asterisk-devel/files/patch-res::Makefile35
-rw-r--r--net/asterisk-devel/files/patch-rtp.c17
-rw-r--r--net/asterisk-devel/files/patch-utils::Makefile34
-rw-r--r--net/asterisk-devel/pkg-descr8
-rw-r--r--net/asterisk-devel/pkg-plist755
33 files changed, 139 insertions, 3282 deletions
diff --git a/net/asterisk-devel/Makefile b/net/asterisk-devel/Makefile
index da02855..4f65d3b 100644
--- a/net/asterisk-devel/Makefile
+++ b/net/asterisk-devel/Makefile
@@ -1,99 +1,160 @@
-# New ports collection makefile for: asterisk
-# Date created: 17 October 2003
-# Whom: Maxim Sobolev <sobomax@portaone.com>
+# New ports collection makefile for: asterisk-current
+# Date created: 15 January 2006
+# Whom: Luigi Rizzo
#
# $FreeBSD$
#
-PORTNAME= asterisk
-PORTVERSION= 1.2.3
+PORTNAME= asterisk-devel
+PORTVERSION= 1.4 # the head branch
CATEGORIES= net
-MASTER_SITES= http://ftp.digium.com/pub/asterisk/ \
- http://ftp.digium.com/pub/asterisk/old-releases/ \
- ftp://ftp.asterisk.org/pub/telephony/asterisk/ \
- ftp://ftp.asterisk.org/pub/telephony/asterisk/old-releases/
+MASTER_SITES= # none, we fetch directly from svn (or cvs)
+DISTFILES= # none
-MAINTAINER= sobomax@FreeBSD.org
-COMMENT= An Open Source PBX and telephony toolkit
+MAINTAINER= luigi@FreeBSD.org
+COMMENT= An Open Source PBX and telephony toolkit - head branch
-PATCHFILES= asterisk122_codec_negotiation-20060125.diff.gz
-PATCH_SITES= http://www.portaone.com/~bamby/public/
+# --- BUILD OPTIONS ---
+#
+# If you run "make -DPLAIN" you will only run the svn distribution
+# without any local change. Otherwise, you will use whatever
+# patch-* and src*.tgz that is in the files directory.
+# If you run "make -DNO_FETCH" you will not update the sources from
+# the latest version in the svn repository.
+#
+# Other options are available with "make config", below.
+#
+# In general, the original asterisk code has some tests in the Makefiles
+# to check whether certain packages are installed, and use them in case,
+# without giving the user a chance to override the decision.
+# Only in a limited number of cases (zaptel, libpri...) there are
+# WITHOUT_FOO Makefile variables to disable the use of a given package.
+# The options below are designed with the above in mind.
+#
+# DEVELBSD use the bsd-specific modifications that are not
+# integrated yet in the trunk.
+# If unset, use trunk, but it is not guaranteed to
+# compile cleanly on FreeBSD
+#
+# ZAPTEL support for the ZAPTEL drivers. Strictly speaking,
+# you would need that only with analog or ISDN telephony
+# cards, but a lot of functionality in asterisk relies on
+# this driver, so you might have a hard time without it.
+#
+# PRI support for ISDN PRI channels. Not necessary unless you
+# have this cards.
+#
+# NEWT make sure newt is installed, if you want to compile astman.
+#
+# SPEEX make sure it has speex, additional codec.
+#
+# H323 make sure the openh323 packages are installed.
+# this is not tested, at the moment.
+#
+# Database support at the moment includes odbc, pgsql, sqlite and tds
+# but there is no option to configure them.
+
+OPTIONS= \
+ DEVELBSD "BSD development version" off \
+ ZAPTEL "Zaptel (you probably want it)" on \
+ PRI "PRI support (normally off)" off \
+ H323 "OpenH323 support (default off)" off \
+ NEWT "newt library, required for astman" off \
+ SPEEX "speex library, optional codec" off \
+
+# Do not try on other architectures, no idea how it works.
+ONLY_FOR_ARCHS= i386 # maybe more but it is untested.
-BUILD_DEPENDS= mpg123:${PORTSDIR}/audio/mpg123
-LIB_DEPENDS= speex.3:${PORTSDIR}/audio/speex \
- newt.51:${PORTSDIR}/devel/newt \
- curl.3:${PORTSDIR}/ftp/curl
-RUN_DEPENDS= mpg123:${PORTSDIR}/audio/mpg123
+# We are working against -current, so it is not meant to be
+# installed or packaged automatically.
-ONLY_FOR_ARCHS= i386 sparc64 amd64
+RESTRICTED= experimental version
+NO_INSTALL= "not meant to install"
+NO_PACKAGE= not meant to build a package
-GNU_CONFIGURE= yes
-CONFIGURE_WRKSRC= ${WRKSRC}/editline
+EXTRA_SOUNDS = \
+ ftp://213.156.62.146/pub/linux/asterisk/sounds/it/it_mm_sounds_20041110.tar.gz
+
+# local components
+# The code uses gmake and flex/bison.
USE_GMAKE= yes
USE_BISON= yes
-USE_RC_SUBR= asterisk.sh
-USE_REINPLACE= yes
-MAKE_ENV= PTHREAD_CFLAGS="${PTHREAD_CFLAGS}" \
- PTHREAD_LIBS="${PTHREAD_LIBS}" \
- MKDIR="${MKDIR}" \
- PWLIBDIR=${PWLIBDIR} \
- OPENH323DIR=${OPENH323DIR} \
- OSVERSION=${OSVERSION} \
- CXX="${CXX}"
-
-MAN8= asterisk.8 astgenkey.8 autosupport.8 safe_asterisk.8
-
-.include <bsd.port.pre.mk>
-
-PWLIBDIR!= cd ${PORTSDIR}/devel/pwlib; make -V WRKSRC
-OPENH323DIR!= cd ${PORTSDIR}/net/openh323; make -V WRKSRC
-
-.if ${ARCH} != "i386"
-WITHOUT_H323= 1
-WITHOUT_ZAPTEL= 1
-.endif
-.if defined(WITHOUT_H323)
-PLIST_SUB+= WITH_H323="@comment "
+# Editline use autoconf, but the configure is there already,
+# so these are just reminders.
+# GNU_CONFIGURE= yes
+# CONFIGURE_WRKSRC= ${WRKSRC}/editline
+
+.include <bsd.port.pre.mk> # need to include this before testing options.
+
+# Targets for the fetch command.
+
+FETCH_DEPENDS+= svn:${PORTSDIR}/devel/subversion
+.if defined(WITH_DEVELBSD)
+# use the FreeBSD-specific version
+LOCAL_REPO= ${PORTSDIR}/distfiles/ast-svn/bsd
+REMOTE_REPO= http://svn.digium.com/svn/asterisk/team/rizzo/base
.else
-BUILD_DEPENDS+= ${NONEXISTENT}:${PORTSDIR}/devel/pwlib:build \
- ${NONEXISTENT}:${PORTSDIR}/net/openh323:build
-PLIST_SUB+= WITH_H323=""
-MAKE_ENV+= WITH_H323=1
+# use the main version.
+LOCAL_REPO= ${PORTSDIR}/distfiles/ast-svn/asterisk
+REMOTE_REPO= http://svn.digium.com/svn/asterisk/trunk/asterisk
+.endif
+REPO_CMD= \
+ if [ -f asterisk ] ; then \
+ svn update ${REMOTE_REPO} . ; else \
+ svn checkout ${REMOTE_REPO} . ; fi
+
+do-fetch:
+ ${MKDIR} ${LOCAL_REPO}
+ [ "x${NO_FETCH}" != "x" ] || (cd ${LOCAL_REPO}; ${REPO_CMD} )
+
+.if defined(PLAIN) # disable any local patches
+do-patch:
+ @echo "Local patches disabled, to check the FreeBSD compliance"
+ @echo "of the standard asterisk distribution."
.endif
-.if defined(WITHOUT_ZAPTEL)
-PLIST_SUB+= WITH_ZAPTEL="@comment "
-MAKE_ENV+= WITHOUT_ZAPTEL=1
+do-extract:
+ ${MKDIR} ${WRKDIR}
+ @echo "Copying main repository"
+ ${CP} -Rp ${LOCAL_REPO} ${WRKSRC}
+.if defined(PLAIN)
+ @echo "Not extracting local distributions"
.else
-BUILD_DEPENDS+= libpri>=1.2.0:${PORTSDIR}/misc/libpri \
- ${LOCALBASE}/include/zaptel.h:${PORTSDIR}/misc/zaptel
-LIB_DEPENDS+= pri.1:${PORTSDIR}/misc/libpri
-RUN_DEPENDS+= ${LOCALBASE}/include/zaptel.h:${PORTSDIR}/misc/zaptel
-PLIST_SUB+= WITH_ZAPTEL=""
-MAKE_ENV+= WITH_ZAPTEL=1
+ @echo "Extracting local distributions"
+ (cd ${WRKSRC}; \
+ for fn in ${FILESDIR}/src*.tgz ; do [ ! -f $${fn} ] || tar xvzf $${fn} ; done )
.endif
-#
-# WITH_FREETDS, WITH_PGSQL and WITH_SQLITE can also be added to MAKE_ENV
-# similarly
-.if defined(WITHOUT_ODBC)
-PLIST_SUB+= WITH_ODBC="@comment "
-.else
-LIB_DEPENDS+= odbc.1:${PORTSDIR}/databases/unixODBC
-PLIST_SUB+= WITH_ODBC=""
-MAKE_ENV+= WITH_ODBC=1
+.if defined(WITH_H323)
+# this is untested.
+# put in the prerequisites
+BUILD_DEPENDS+= ${NONEXISTENT}:${PORTSDIR}/devel/pwlib152:build \
+ ${NONEXISTENT}:${PORTSDIR}/net/openh323-112:build
.endif
-.if defined(WITHOUT_FAX)
-PLIST_SUB+= WITH_FAX="@comment "
+.if defined(WITH_ZAPTEL)
+# first, put in the prerequisites.
+BUILD_DEPENDS+= ${LOCALBASE}/include/zaptel.h:${PORTSDIR}/misc/zaptel
+RUN_DEPENDS+= ${LOCALBASE}/include/zaptel.h:${PORTSDIR}/misc/zaptel
+# now look at pri (no pri if no zaptel)
+.if defined(WITH_PRI)
+LIB_DEPENDS+= pri.1:${PORTSDIR}/misc/libpri
+.else
+MAKE_ENV+= WITHOUT_PRI=1
+.endif
.else
-MAKE_ENV+= WITH_FAX=1
-LIB_DEPENDS+= spandsp.0:${PORTSDIR}/comms/spandsp
-PLIST_SUB+= WITH_FAX=""
+MAKE_ENV+= WITHOUT_ZAPTEL=1
.endif
-post-patch:
- ${REINPLACE_CMD} -e 's|/var/lib|${PREFIX}/share|g' ${WRKSRC}/configs/musiconhold.conf.sample
+.if defined(WITH_NEWT)
+# newt is required for astmon
+LIB_DEPENDS+= newt.51:${PORTSDIR}/devel/newt
+.endif
+
+.if defined(WITH_SPEEX)
+# support for additional codecs
+LIB_DEPENDS+= speex.3:${PORTSDIR}/audio/speex
+.endif
.include <bsd.port.post.mk>
diff --git a/net/asterisk-devel/distinfo b/net/asterisk-devel/distinfo
deleted file mode 100644
index 0fc809b..0000000
--- a/net/asterisk-devel/distinfo
+++ /dev/null
@@ -1,6 +0,0 @@
-MD5 (asterisk-1.2.3.tar.gz) = 89d90096f6c7acf7d3dfe5457a2e3dbe
-SHA256 (asterisk-1.2.3.tar.gz) = e305c1dd3e875f22626913812851a344dd89699af545626aa5553bc4f1e1b943
-SIZE (asterisk-1.2.3.tar.gz) = 10533725
-MD5 (asterisk122_codec_negotiation-20060125.diff.gz) = 165ca0d6eb9dc1205f24778d830e9713
-SHA256 (asterisk122_codec_negotiation-20060125.diff.gz) = 8a337b84d0ec75130ae2f39660f4a1a9a762277ab6929fe4b7be22e675fd0ae1
-SIZE (asterisk122_codec_negotiation-20060125.diff.gz) = 27944
diff --git a/net/asterisk-devel/files/asterisk.sh.in b/net/asterisk-devel/files/asterisk.sh.in
deleted file mode 100644
index 10f0c42..0000000
--- a/net/asterisk-devel/files/asterisk.sh.in
+++ /dev/null
@@ -1,25 +0,0 @@
-#!/bin/sh
-
-# PROVIDE asterisk
-# REQUIRE: NETWORKING SERVERS
-# BEFORE: DAEMON
-# KEYWORD: FreeBSD shutdown
-
-#
-# Add the following lines to /etc/rc.conf to enable asterisk:
-#
-# asterisk_enable="YES"
-#
-
-. %%RC_SUBR%%
-
-name=asterisk
-rcvar=`set_rcvar`
-
-command=%%PREFIX%%/sbin/asterisk
-pidfile=/var/run/asterisk.pid
-
-asterisk_enable=${asterisk_enable:-"NO"}
-
-load_rc_config $name
-run_rc_command "$1"
diff --git a/net/asterisk-devel/files/patch-Makefile b/net/asterisk-devel/files/patch-Makefile
deleted file mode 100644
index 708a356..0000000
--- a/net/asterisk-devel/files/patch-Makefile
+++ /dev/null
@@ -1,515 +0,0 @@
-
-$FreeBSD$
-
---- Makefile.orig
-+++ Makefile
-@@ -19,8 +19,8 @@
- # CROSS_COMPILE=/opt/montavista/pro/devkit/arm/xscale_be/bin/xscale_be-
- # CROSS_COMPILE_BIN=/opt/montavista/pro/devkit/arm/xscale_be/bin/
- # CROSS_COMPILE_TARGET=/opt/montavista/pro/devkit/arm/xscale_be/target
--CC=$(CROSS_COMPILE)gcc
--HOST_CC=gcc
-+CC?=$(CROSS_COMPILE)gcc
-+HOST_CC=${CC}
- # CROSS_ARCH=Linux
- # CROSS_PROC=arm
- # SUB_PROC=xscale # or maverick
-@@ -44,14 +44,14 @@
- #K6OPT = -DK6OPT
-
- #Tell gcc to optimize the code
--OPTIMIZE+=-O6
-+#OPTIMIZE+=-O6
- endif
-
- #Overwite config files on "make samples"
--OVERWRITE=y
-+OVERWRITE=n
-
- #Include debug and macro symbols in the executables (-g) and profiling info (-pg)
--DEBUG=-g3 #-pg
-+#DEBUG=-g3 #-pg
-
- #Set NOCRYPTO to yes if you do not want to have crypto support or
- #dependencies
-@@ -83,7 +83,7 @@
-
- # Where to install asterisk after compiling
- # Default -> leave empty
--INSTALL_PREFIX?=
-+INSTALL_PREFIX=$(PREFIX)
-
- # Staging directory
- # Files are copied here temporarily during the install process
-@@ -106,17 +106,17 @@
- BUSYDETECT+= #-DBUSYDETECT_COMPARE_TONE_AND_SILENCE
-
- ifneq ($(OSARCH),SunOS)
-- ASTLIBDIR=$(INSTALL_PREFIX)/usr/lib/asterisk
-- ASTVARLIBDIR=$(INSTALL_PREFIX)/var/lib/asterisk
-+ ASTLIBDIR=$(INSTALL_PREFIX)/lib/asterisk
-+ ASTVARLIBDIR=$(INSTALL_PREFIX)/share/asterisk
- ASTETCDIR=$(INSTALL_PREFIX)/etc/asterisk
-- ASTSPOOLDIR=$(INSTALL_PREFIX)/var/spool/asterisk
-- ASTLOGDIR=$(INSTALL_PREFIX)/var/log/asterisk
-- ASTHEADERDIR=$(INSTALL_PREFIX)/usr/include/asterisk
-+ ASTSPOOLDIR=/var/spool/asterisk
-+ ASTLOGDIR=/var/log/asterisk
-+ ASTHEADERDIR=$(INSTALL_PREFIX)/include/asterisk
- ASTCONFPATH=$(ASTETCDIR)/asterisk.conf
-- ASTBINDIR=$(INSTALL_PREFIX)/usr/bin
-- ASTSBINDIR=$(INSTALL_PREFIX)/usr/sbin
-- ASTVARRUNDIR=$(INSTALL_PREFIX)/var/run
-- ASTMANDIR=$(INSTALL_PREFIX)/usr/share/man
-+ ASTBINDIR=$(INSTALL_PREFIX)/bin
-+ ASTSBINDIR=$(INSTALL_PREFIX)/sbin
-+ ASTVARRUNDIR=/var/run
-+ ASTMANDIR=$(INSTALL_PREFIX)/man
- MODULES_DIR=$(ASTLIBDIR)/modules
- AGI_DIR=$(ASTVARLIBDIR)/agi-bin
- else
-@@ -218,25 +218,25 @@
- endif
-
- INCLUDE+=-Iinclude -I../include
--ASTCFLAGS+=-pipe -Wall -Wstrict-prototypes -Wmissing-prototypes -Wmissing-declarations $(DEBUG) $(INCLUDE) -D_REENTRANT -D_GNU_SOURCE #-DMAKE_VALGRIND_HAPPY
--ASTCFLAGS+=$(OPTIMIZE)
-+ASTCFLAGS+=-Wall -Wstrict-prototypes -Wmissing-prototypes -Wmissing-declarations $(DEBUG) $(INCLUDE) -D_REENTRANT -D_GNU_SOURCE #-DMAKE_VALGRIND_HAPPY
-+#ASTCFLAGS+=$(OPTIMIZE)
- ASTOBJ=-o asterisk
-
- ifeq ($(findstring BSD,$(OSARCH)),BSD)
- PROC=$(shell uname -m)
-- ASTCFLAGS+=-I$(CROSS_COMPILE_TARGET)/usr/local/include -L$(CROSS_COMPILE_TARGET)/usr/local/lib
-+ ASTCFLAGS+=-I$(CROSS_COMPILE_TARGET)$(LOCALBASE)/include -L$(CROSS_COMPILE_TARGET)$(LOCALBASE)/lib
- endif
-
- ifneq ($(PROC),ultrasparc)
-- ASTCFLAGS+=$(shell if $(CC) -march=$(PROC) -S -o /dev/null -xc /dev/null >/dev/null 2>&1; then echo "-march=$(PROC)"; fi)
-+# ASTCFLAGS+=$(shell if $(CC) -march=$(PROC) -S -o /dev/null -xc /dev/null >/dev/null 2>&1; then echo "-march=$(PROC)"; fi)
- endif
-
- ifeq ($(PROC),ppc)
- ASTCFLAGS+=-fsigned-char
- endif
-
--ifneq ($(wildcard $(CROSS_COMPILE_TARGET)/usr/local/include/osp/osp.h),)
-- ASTCFLAGS+=-DOSP_SUPPORT -I$(CROSS_COMPILE_TARGET)/usr/local/include/osp
-+ifneq ($(wildcard $(CROSS_COMPILE_TARGET)$(LOCALBASE)/include/osp/osp.h),)
-+ ASTCFLAGS+=-DOSP_SUPPORT -I$(CROSS_COMPILE_TARGET)$(LOCALBASE)/include/osp
- else
- ifneq ($(wildcard $(CROSS_COMPILE_TARGET)/usr/include/osp/osp.h),)
- ASTCFLAGS+=-DOSP_SUPPORT -I$(CROSS_COMPILE_TARGET)/usr/include/osp
-@@ -245,27 +245,24 @@
-
- ifeq ($(OSARCH),FreeBSD)
- BSDVERSION=$(shell make -V OSVERSION -f $(CROSS_COMPILE_TARGET)/usr/share/mk/bsd.port.subdir.mk)
-- ASTCFLAGS+=$(shell if test $(BSDVERSION) -lt 500016 ; then echo "-D_THREAD_SAFE"; fi)
-- LIBS+=$(shell if test $(BSDVERSION) -lt 502102 ; then echo "-lc_r"; else echo "-pthread"; fi)
-- ifneq ($(wildcard $(CROSS_COMPILE_TARGET)/usr/local/include/spandsp),)
-- ASTCFLAGS+=-I$(CROSS_COMPILE_TARGET)/usr/local/include/spandsp
-+ ASTCFLAGS+=$(PTHREAD_CFLAGS)
-+ LIBS+=$(PTHREAD_LIBS)
-+ ifneq ($(wildcard $(CROSS_COMPILE_TARGET)$(LOCALBASE)/include/spandsp),)
-+ ASTCFLAGS+=-I$(CROSS_COMPILE_TARGET)$(LOCALBASE)/include/spandsp
- endif
- MPG123TARG=freebsd
-
-- # XXX FreeBSD paths
-- PREFIX?=/usr/local
-- ASTLIBDIR=$(INSTALL_PREFIX)$(PREFIX)/lib/asterisk
-- ASTVARLIBDIR=$(INSTALL_PREFIX)$(PREFIX)/share/asterisk
-- ASTETCDIR=$(INSTALL_PREFIX)$(PREFIX)/etc/asterisk
-- ASTSPOOLDIR=$(INSTALL_PREFIX)/var/spool/asterisk
-- ASTLOGDIR=$(INSTALL_PREFIX)/var/log/asterisk
-- ASTHEADERDIR=$(INSTALL_PREFIX)$(PREFIX)/include/asterisk
-+ ASTLIBDIR=$(INSTALL_PREFIX)/lib/asterisk
-+ ASTVARLIBDIR=$(INSTALL_PREFIX)/share/asterisk
-+ ASTETCDIR=$(INSTALL_PREFIX)/etc/asterisk
-+ ASTSPOOLDIR=/var/spool/asterisk
-+ ASTLOGDIR=/var/log/asterisk
-+ ASTHEADERDIR=$(INSTALL_PREFIX)/include/asterisk
- ASTCONFPATH=$(ASTETCDIR)/asterisk.conf
-- ASTBINDIR=$(INSTALL_PREFIX)$(PREFIX)/bin
-- ASTSBINDIR=$(INSTALL_PREFIX)$(PREFIX)/sbin
-- ASTVARRUNDIR=$(INSTALL_PREFIX)/var/run
-- ASTMANDIR=$(INSTALL_PREFIX)$(PREFIX)/man
-- # XXX end FreeBSD paths
-+ ASTBINDIR=$(INSTALL_PREFIX)/bin
-+ ASTSBINDIR=$(INSTALL_PREFIX)/sbin
-+ ASTVARRUNDIR=/var/run
-+ ASTMANDIR=$(INSTALL_PREFIX)/man
-
- endif # FreeBSD
-
-@@ -281,7 +278,7 @@
-
- ifeq ($(OSARCH),SunOS)
- ASTCFLAGS+=-Wcast-align -DSOLARIS
-- INCLUDE+=-Iinclude/solaris-compat -I$(CROSS_COMPILE_TARGET)/usr/local/ssl/include
-+ INCLUDE+=-Iinclude/solaris-compat -I$(CROSS_COMPILE_TARGET)$(LOCALBASE)/ssl/include
- endif
-
- ifeq ($(findstring CYGWIN,$(OSARCH)),CYGWIN)
-@@ -296,7 +293,7 @@
-
- ifndef WITHOUT_ZAPTEL
-
--ifneq ($(wildcard $(CROSS_COMPILE_TARGET)/usr/include/linux/zaptel.h)$(wildcard $(CROSS_COMPILE_TARGET)/usr/local/include/zaptel.h)$(wildcard $(CROSS_COMPILE_TARGET)/usr/pkg/include/zaptel.h),)
-+ifneq ($(wildcard $(CROSS_COMPILE_TARGET)/usr/include/linux/zaptel.h)$(wildcard $(CROSS_COMPILE_TARGET)$(LOCALBASE)/include/zaptel.h)$(wildcard $(CROSS_COMPILE_TARGET)/usr/pkg/include/zaptel.h),)
- ASTCFLAGS+=-DZAPTEL_OPTIMIZATIONS
- endif
-
-@@ -323,7 +320,7 @@
- ASTERISKVERSIONNUM=999999
- ASTERISKVERSION=SVN-$(shell build_tools/make_svn_branch_name)
- else
-- ASTERISKVERSIONNUM=000000
-+ ASTERISKVERSIONNUM?=000000
- endif
- endif
-
-@@ -388,10 +385,10 @@
- endif
-
- ifeq ($(OSARCH),SunOS)
-- LIBS+=-lpthread -ldl -lnsl -lsocket -lresolv -L$(CROSS_COMPILE_TARGET)/usr/local/ssl/lib
-+ LIBS+=-lpthread -ldl -lnsl -lsocket -lresolv -L$(CROSS_COMPILE_TARGET)$(LOCALBASE)/ssl/lib
- OBJS+=strcompat.o
- ASTLINK=
-- SOLINK=-shared -fpic -L$(CROSS_COMPILE_TARGET)/usr/local/ssl/lib
-+ SOLINK=-shared -fpic -L$(CROSS_COMPILE_TARGET)$(LOCALBASE)/ssl/lib
- endif
-
- ifeq ($(MAKETOPLEVEL),$(MAKELEVEL))
-@@ -399,7 +396,7 @@
- endif
-
- # This is used when generating the doxygen documentation
--ifneq ($(wildcard /usr/local/bin/dot)$(wildcard /usr/bin/dot),)
-+ifneq ($(wildcard $(LOCALBASE)/bin/dot)$(wildcard /usr/bin/dot),)
- HAVEDOT=yes
- else
- HAVEDOT=no
-@@ -418,7 +415,7 @@
- @echo " + $(MAKE) install +"
- @echo " +-------------------------------------------+"
-
--all: cleantest depend asterisk subdirs
-+all: cleantest depend asterisk subdirs manpage
-
- #ifneq ($(wildcard tags),)
- ctags: tags
-@@ -437,13 +434,13 @@
- cd editline && unset CFLAGS LIBS && test -f config.h || ./configure
- $(MAKE) -C editline libedit.a
-
--db1-ast/libdb1.a: FORCE
-- @if [ -d db1-ast ]; then \
-- $(MAKE) -C db1-ast libdb1.a ; \
-- else \
-- echo "You need to do a cvs update -d not just cvs update"; \
-- exit 1; \
-- fi
-+#db1-ast/libdb1.a: FORCE
-+# @if [ -d db1-ast ]; then \
-+# $(MAKE) -C db1-ast libdb1.a ; \
-+# else \
-+# echo "You need to do a cvs update -d not just cvs update"; \
-+# exit 1; \
-+# fi
-
- ifneq ($(wildcard .depend),)
- include .depend
-@@ -510,14 +507,14 @@
- cygwin_a:
- $(MAKE) -C cygwin all
-
--asterisk: $(CYGLOADER) editline/libedit.a db1-ast/libdb1.a stdtime/libtime.a $(OBJS)
-+asterisk: $(CYGLOADER) editline/libedit.a stdtime/libtime.a $(OBJS)
- build_tools/make_build_h > include/asterisk/build.h.tmp
- if cmp -s include/asterisk/build.h.tmp include/asterisk/build.h ; then echo ; else \
- mv include/asterisk/build.h.tmp include/asterisk/build.h ; \
- fi
- rm -f include/asterisk/build.h.tmp
- $(CC) -c -o buildinfo.o $(CFLAGS) buildinfo.c
-- $(CC) $(DEBUG) $(ASTOBJ) $(ASTLINK) $(OBJS) buildinfo.o $(LIBEDIT) db1-ast/libdb1.a stdtime/libtime.a $(LIBS)
-+ $(CC) $(DEBUG) $(ASTOBJ) $(ASTLINK) $(OBJS) buildinfo.o $(LIBEDIT) stdtime/libtime.a $(LIBS)
-
- muted: muted.o
- $(CC) $(AUDIO_LIBS) -o muted muted.o
-@@ -539,38 +536,38 @@
-
- datafiles: all
- if [ x`whoami` = xroot ]; then sh mkpkgconfig $(DESTDIR)/usr/lib/pkgconfig; fi
-- mkdir -p $(DESTDIR)$(ASTVARLIBDIR)/sounds/digits
-- mkdir -p $(DESTDIR)$(ASTVARLIBDIR)/sounds/priv-callerintros
-+ $(MKDIR) $(DESTDIR)$(ASTVARLIBDIR)/sounds/digits
-+ $(MKDIR) $(DESTDIR)$(ASTVARLIBDIR)/sounds/priv-callerintros
- for x in sounds/digits/*.gsm; do \
- if $(GREP) -q "^%`basename $$x`%" sounds.txt; then \
-- $(INSTALL) -m 644 $$x $(DESTDIR)$(ASTVARLIBDIR)/sounds/digits ; \
-+ $(BSD_INSTALL_DATA) $$x $(DESTDIR)$(ASTVARLIBDIR)/sounds/digits ; \
- else \
- echo "No description for $$x"; \
- exit 1; \
- fi; \
- done
-- mkdir -p $(DESTDIR)$(ASTVARLIBDIR)/sounds/dictate
-+ $(MKDIR) $(DESTDIR)$(ASTVARLIBDIR)/sounds/dictate
- for x in sounds/dictate/*.gsm; do \
- if $(GREP) -q "^%`basename $$x`%" sounds.txt; then \
-- $(INSTALL) -m 644 $$x $(DESTDIR)$(ASTVARLIBDIR)/sounds/dictate ; \
-+ $(BSD_INSTALL_DATA) $$x $(DESTDIR)$(ASTVARLIBDIR)/sounds/dictate ; \
- else \
- echo "No description for $$x"; \
- exit 1; \
- fi; \
- done
-- mkdir -p $(DESTDIR)$(ASTVARLIBDIR)/sounds/letters
-+ $(MKDIR) $(DESTDIR)$(ASTVARLIBDIR)/sounds/letters
- for x in sounds/letters/*.gsm; do \
- if $(GREP) -q "^%`basename $$x`%" sounds.txt; then \
-- $(INSTALL) -m 644 $$x $(DESTDIR)$(ASTVARLIBDIR)/sounds/letters ; \
-+ $(BSD_INSTALL_DATA) $$x $(DESTDIR)$(ASTVARLIBDIR)/sounds/letters ; \
- else \
- echo "No description for $$x"; \
- exit 1; \
- fi; \
- done
-- mkdir -p $(DESTDIR)$(ASTVARLIBDIR)/sounds/phonetic
-+ $(MKDIR) $(DESTDIR)$(ASTVARLIBDIR)/sounds/phonetic
- for x in sounds/phonetic/*.gsm; do \
- if $(GREP) -q "^%`basename $$x`%" sounds.txt; then \
-- $(INSTALL) -m 644 $$x $(DESTDIR)$(ASTVARLIBDIR)/sounds/phonetic ; \
-+ $(BSD_INSTALL_DATA) $$x $(DESTDIR)$(ASTVARLIBDIR)/sounds/phonetic ; \
- else \
- echo "No description for $$x"; \
- exit 1; \
-@@ -578,18 +575,18 @@
- done
- for x in sounds/demo-* sounds/vm-* sounds/transfer* sounds/pbx-* sounds/ss-* sounds/beep* sounds/dir-* sounds/conf-* sounds/agent-* sounds/invalid* sounds/tt-* sounds/auth-* sounds/privacy-* sounds/queue-* sounds/spy-* sounds/priv-* sounds/screen-* sounds/hello-*; do \
- if $(GREP) -q "^%`basename $$x`%" sounds.txt; then \
-- $(INSTALL) -m 644 $$x $(DESTDIR)$(ASTVARLIBDIR)/sounds ; \
-+ $(BSD_INSTALL_DATA) $$x $(DESTDIR)$(ASTVARLIBDIR)/sounds ; \
- else \
- echo "No description for $$x"; \
- exit 1; \
- fi; \
- done
-- mkdir -p $(DESTDIR)$(ASTVARLIBDIR)/mohmp3
-- mkdir -p $(DESTDIR)$(ASTVARLIBDIR)/images
-+ $(MKDIR) $(DESTDIR)$(ASTVARLIBDIR)/mohmp3
-+ $(MKDIR) $(DESTDIR)$(ASTVARLIBDIR)/images
- for x in images/*.jpg; do \
-- $(INSTALL) -m 644 $$x $(DESTDIR)$(ASTVARLIBDIR)/images ; \
-+ $(BSD_INSTALL_DATA) $$x $(DESTDIR)$(ASTVARLIBDIR)/images ; \
- done
-- mkdir -p $(DESTDIR)$(AGI_DIR)
-+ $(MKDIR) $(DESTDIR)$(AGI_DIR)
-
- update:
- @if [ -d .svn ]; then \
-@@ -618,75 +615,53 @@
- OLDHEADERS=$(filter-out $(NEWHEADERS),$(notdir $(wildcard $(DESTDIR)$(ASTHEADERDIR)/*.h)))
-
- bininstall: all
-- mkdir -p $(DESTDIR)$(MODULES_DIR)
-- mkdir -p $(DESTDIR)$(ASTSBINDIR)
-- mkdir -p $(DESTDIR)$(ASTETCDIR)
-- mkdir -p $(DESTDIR)$(ASTBINDIR)
-- mkdir -p $(DESTDIR)$(ASTVARRUNDIR)
-- mkdir -p $(DESTDIR)$(ASTSPOOLDIR)/voicemail
-- mkdir -p $(DESTDIR)$(ASTSPOOLDIR)/dictate
-- mkdir -p $(DESTDIR)$(ASTSPOOLDIR)/system
-- mkdir -p $(DESTDIR)$(ASTSPOOLDIR)/tmp
-- mkdir -p $(DESTDIR)$(ASTSPOOLDIR)/meetme
-- mkdir -p $(DESTDIR)$(ASTSPOOLDIR)/monitor
-- if [ -f asterisk ]; then $(INSTALL) -m 755 asterisk $(DESTDIR)$(ASTSBINDIR)/; fi
-- if [ -f cygwin/asterisk.exe ]; then $(INSTALL) -m 755 cygwin/asterisk.exe $(DESTDIR)$(ASTSBINDIR)/; fi
-- if [ -f asterisk.dll ]; then $(INSTALL) -m 755 asterisk.dll $(DESTDIR)$(ASTSBINDIR)/; fi
-+ $(MKDIR) $(DESTDIR)$(MODULES_DIR)
-+ $(MKDIR) $(DESTDIR)$(ASTSBINDIR)
-+ $(MKDIR) $(DESTDIR)$(ASTETCDIR)
-+ $(MKDIR) $(DESTDIR)$(ASTBINDIR)
-+ $(MKDIR) $(DESTDIR)$(ASTVARRUNDIR)
-+ $(MKDIR) $(DESTDIR)$(ASTSPOOLDIR)/voicemail
-+ $(MKDIR) $(DESTDIR)$(ASTSPOOLDIR)/dictate
-+ $(MKDIR) $(DESTDIR)$(ASTSPOOLDIR)/system
-+ $(MKDIR) $(DESTDIR)$(ASTSPOOLDIR)/tmp
-+ $(MKDIR) $(DESTDIR)$(ASTSPOOLDIR)/meetme
-+ $(MKDIR) $(DESTDIR)$(ASTSPOOLDIR)/monitor
-+ if [ -f asterisk ]; then $(BSD_INSTALL_PROGRAM) asterisk $(DESTDIR)$(ASTSBINDIR)/; fi
-+ if [ -f cygwin/asterisk.exe ]; then $(BSD_INSTALL_PROGRAM) cygwin/asterisk.exe $(DESTDIR)$(ASTSBINDIR)/; fi
-+ if [ -f asterisk.dll ]; then $(BSD_INSTALL_PROGRAM) asterisk.dll $(DESTDIR)$(ASTSBINDIR)/; fi
- ln -sf asterisk $(DESTDIR)$(ASTSBINDIR)/rasterisk
-- $(INSTALL) -m 755 contrib/scripts/astgenkey $(DESTDIR)$(ASTSBINDIR)/
-- $(INSTALL) -m 755 contrib/scripts/autosupport $(DESTDIR)$(ASTSBINDIR)/
-+ $(BSD_INSTALL_SCRIPT) contrib/scripts/astgenkey $(DESTDIR)$(ASTSBINDIR)/
-+ $(BSD_INSTALL_SCRIPT) contrib/scripts/autosupport $(DESTDIR)$(ASTSBINDIR)/
- if [ ! -f $(DESTDIR)$(ASTSBINDIR)/safe_asterisk ]; then \
- cat contrib/scripts/safe_asterisk | sed 's|__ASTERISK_SBIN_DIR__|$(ASTSBINDIR)|;' > $(DESTDIR)$(ASTSBINDIR)/safe_asterisk ;\
- chmod 755 $(DESTDIR)$(ASTSBINDIR)/safe_asterisk;\
- fi
- for x in $(SUBDIRS); do $(MAKE) -C $$x install || exit 1 ; done
-- $(INSTALL) -d $(DESTDIR)$(ASTHEADERDIR)
-- $(INSTALL) -m 644 include/asterisk/*.h $(DESTDIR)$(ASTHEADERDIR)
-+ $(MKDIR) $(DESTDIR)$(ASTHEADERDIR)
-+ $(BSD_INSTALL_DATA) include/asterisk/*.h $(DESTDIR)$(ASTHEADERDIR)
- if [ -n "$(OLDHEADERS)" ]; then \
- rm -f $(addprefix $(DESTDIR)$(ASTHEADERDIR)/,$(OLDHEADERS)) ;\
- fi
- rm -f $(DESTDIR)$(ASTVARLIBDIR)/sounds/voicemail
-- mkdir -p $(DESTDIR)$(ASTVARLIBDIR)/sounds
-- mkdir -p $(DESTDIR)$(ASTLOGDIR)/cdr-csv
-- mkdir -p $(DESTDIR)$(ASTLOGDIR)/cdr-custom
-- mkdir -p $(DESTDIR)$(ASTVARLIBDIR)/keys
-- mkdir -p $(DESTDIR)$(ASTVARLIBDIR)/firmware
-- mkdir -p $(DESTDIR)$(ASTVARLIBDIR)/firmware/iax
-- mkdir -p $(DESTDIR)$(ASTMANDIR)/man8
-- $(INSTALL) -m 644 keys/iaxtel.pub $(DESTDIR)$(ASTVARLIBDIR)/keys
-- $(INSTALL) -m 644 keys/freeworlddialup.pub $(DESTDIR)$(ASTVARLIBDIR)/keys
-- $(INSTALL) -m 644 asterisk.8 $(DESTDIR)$(ASTMANDIR)/man8
-- $(INSTALL) -m 644 contrib/scripts/astgenkey.8 $(DESTDIR)$(ASTMANDIR)/man8
-- $(INSTALL) -m 644 contrib/scripts/autosupport.8 $(DESTDIR)$(ASTMANDIR)/man8
-- $(INSTALL) -m 644 contrib/scripts/safe_asterisk.8 $(DESTDIR)$(ASTMANDIR)/man8
-+ $(MKDIR) $(DESTDIR)$(ASTVARLIBDIR)/sounds
-+ $(MKDIR) $(DESTDIR)$(ASTLOGDIR)/cdr-csv
-+ $(MKDIR) $(DESTDIR)$(ASTLOGDIR)/cdr-custom
-+ $(MKDIR) $(DESTDIR)$(ASTVARLIBDIR)/keys
-+ $(MKDIR) $(DESTDIR)$(ASTVARLIBDIR)/firmware
-+ $(MKDIR) $(DESTDIR)$(ASTVARLIBDIR)/firmware/iax
-+ $(MKDIR) $(DESTDIR)$(ASTMANDIR)/man8
-+ $(BSD_INSTALL_DATA) keys/iaxtel.pub $(DESTDIR)$(ASTVARLIBDIR)/keys
-+ $(BSD_INSTALL_DATA) keys/freeworlddialup.pub $(DESTDIR)$(ASTVARLIBDIR)/keys
-+ $(BSD_INSTALL_DATA) asterisk.8 $(DESTDIR)$(ASTMANDIR)/man8
-+ $(BSD_INSTALL_DATA) contrib/scripts/astgenkey.8 $(DESTDIR)$(ASTMANDIR)/man8
-+ $(BSD_INSTALL_DATA) contrib/scripts/autosupport.8 $(DESTDIR)$(ASTMANDIR)/man8
-+ $(BSD_INSTALL_DATA) contrib/scripts/safe_asterisk.8 $(DESTDIR)$(ASTMANDIR)/man8
- if [ -d contrib/firmware/iax ]; then \
-- $(INSTALL) -m 644 contrib/firmware/iax/iaxy.bin $(DESTDIR)$(ASTVARLIBDIR)/firmware/iax/iaxy.bin; \
-+ $(BSD_INSTALL_DATA) contrib/firmware/iax/iaxy.bin $(DESTDIR)$(ASTVARLIBDIR)/firmware/iax/iaxy.bin; \
- else \
- echo "You need to do cvs update -d not just cvs update" ; \
- fi
- ( cd $(DESTDIR)$(ASTVARLIBDIR)/sounds ; ln -s $(ASTSPOOLDIR)/voicemail . )
-- if [ -f mpg123-0.59r/mpg123 ]; then $(MAKE) -C mpg123-0.59r install; fi
-- @echo " +---- Asterisk Installation Complete -------+"
-- @echo " + +"
-- @echo " + YOU MUST READ THE SECURITY DOCUMENT +"
-- @echo " + +"
-- @echo " + Asterisk has successfully been installed. +"
-- @echo " + If you would like to install the sample +"
-- @echo " + configuration files (overwriting any +"
-- @echo " + existing config files), run: +"
-- @echo " + +"
-- @echo " + $(MAKE) samples +"
-- @echo " + +"
-- @echo " +----------------- or ---------------------+"
-- @echo " + +"
-- @echo " + You can go ahead and install the asterisk +"
-- @echo " + program documentation now or later run: +"
-- @echo " + +"
-- @echo " + $(MAKE) progdocs +"
-- @echo " + +"
-- @echo " + **Note** This requires that you have +"
-- @echo " + doxygen installed on your local system +"
-- @echo " +-------------------------------------------+"
- @$(MAKE) -s oldmodcheck
-
- NEWMODS=$(notdir $(wildcard */*.so))
-@@ -710,7 +685,7 @@
- echo " WARNING WARNING WARNING" ;\
- fi
-
--install: all datafiles bininstall
-+install: all datafiles bininstall samples
- @if [ -x /usr/sbin/asterisk-post-install ]; then \
- /usr/sbin/asterisk-post-install $(DESTDIR) . ; \
- fi
-@@ -718,16 +693,19 @@
- upgrade: all bininstall
-
- adsi:
-- mkdir -p $(DESTDIR)$(ASTETCDIR)
-+ $(MKDIR) $(DESTDIR)$(ASTETCDIR)
- for x in configs/*.adsi; do \
-+ $(BSD_INSTALL_DATA) $$x $(DESTDIR)$(ASTETCDIR)/`basename $$x`-dist; \
- if [ ! -f $(DESTDIR)$(ASTETCDIRX)/$$x ]; then \
-- $(INSTALL) -m 644 $$x $(DESTDIR)$(ASTETCDIR)/`basename $$x` ; \
-+ $(BSD_INSTALL_DATA) $$x $(DESTDIR)$(ASTETCDIR)/`basename $$x` ; \
- fi ; \
- done
-
- samples: adsi
-- mkdir -p $(DESTDIR)$(ASTETCDIR)
-+ echo ADSI INSTALL $(BSD_INSTALL_DATA)
-+ $(MKDIR) $(DESTDIR)$(ASTETCDIR)
- for x in configs/*.sample; do \
-+ $(BSD_INSTALL_DATA) $$x $(DESTDIR)$(ASTETCDIR)/`basename $$x .sample`-dist;\
- if [ -f $(DESTDIR)$(ASTETCDIR)/`basename $$x .sample` ]; then \
- if [ "$(OVERWRITE)" = "y" ]; then \
- if cmp -s $(DESTDIR)$(ASTETCDIR)/`basename $$x .sample` $$x ; then \
-@@ -740,7 +718,7 @@
- continue; \
- fi ;\
- fi ; \
-- $(INSTALL) -m 644 $$x $(DESTDIR)$(ASTETCDIR)/`basename $$x .sample` ;\
-+ $(BSD_INSTALL_DATA) $$x $(DESTDIR)$(ASTETCDIR)/`basename $$x .sample` ;\
- done
- if [ "$(OVERWRITE)" = "y" ] || [ ! -f $(DESTDIR)$(ASTCONFPATH) ]; then \
- ( \
-@@ -800,25 +778,25 @@
- echo "; Default: strict"; \
- echo ";"; \
- echo ";translation_algorithm = strict"; \
-- ) > $(DESTDIR)$(ASTCONFPATH) ; \
-+ ) > $(DESTDIR)$(ASTCONFPATH)-dist ; \
- else \
- echo "Skipping asterisk.conf creation"; \
- fi
-- mkdir -p $(DESTDIR)$(ASTVARLIBDIR)/sounds ; \
-+ $(MKDIR) $(DESTDIR)$(ASTVARLIBDIR)/sounds ; \
- for x in sounds/demo-*; do \
- if $(GREP) -q "^%`basename $$x`%" sounds.txt; then \
-- $(INSTALL) -m 644 $$x $(DESTDIR)$(ASTVARLIBDIR)/sounds ; \
-+ $(BSD_INSTALL_DATA) $$x $(DESTDIR)$(ASTVARLIBDIR)/sounds ; \
- else \
- echo "No description for $$x"; \
- exit 1; \
- fi; \
- done
-- mkdir -p $(DESTDIR)$(ASTVARLIBDIR)/mohmp3 ; \
-+ $(MKDIR) $(DESTDIR)$(ASTVARLIBDIR)/mohmp3 ; \
- for x in sounds/*.mp3; do \
-- $(INSTALL) -m 644 $$x $(DESTDIR)$(ASTVARLIBDIR)/mohmp3 ; \
-+ $(BSD_INSTALL_DATA) $$x $(DESTDIR)$(ASTVARLIBDIR)/mohmp3 ; \
- done
- rm -f $(DESTDIR)$(ASTVARLIBDIR)/mohmp3/sample-hold.mp3
-- mkdir -p $(DESTDIR)$(ASTSPOOLDIR)/voicemail/default/1234/INBOX
-+ $(MKDIR) $(DESTDIR)$(ASTSPOOLDIR)/voicemail/default/1234/INBOX
- :> $(DESTDIR)$(ASTSPOOLDIR)/voicemail/default/1234/unavail.gsm
- for x in vm-theperson digits/1 digits/2 digits/3 digits/4 vm-isunavail; do \
- cat $(DESTDIR)$(ASTVARLIBDIR)/sounds/$$x.gsm >> $(DESTDIR)$(ASTSPOOLDIR)/voicemail/default/1234/unavail.gsm ; \
-@@ -832,7 +810,7 @@
- @[ -d $(DESTDIR)$(HTTP_DOCSDIR)/ ] || ( printf "http docs directory not found.\nUpdate assignment of variable HTTP_DOCSDIR in Makefile!\n" && exit 1 )
- @[ -d $(DESTDIR)$(HTTP_CGIDIR) ] || ( printf "cgi-bin directory not found.\nUpdate assignment of variable HTTP_CGIDIR in Makefile!\n" && exit 1 )
- $(INSTALL) -m 4755 -o root -g root contrib/scripts/vmail.cgi $(DESTDIR)$(HTTP_CGIDIR)/vmail.cgi
-- mkdir -p $(DESTDIR)$(HTTP_DOCSDIR)/_asterisk
-+ $(MKDIR) $(DESTDIR)$(HTTP_DOCSDIR)/_asterisk
- for x in images/*.gif; do \
- $(INSTALL) -m 644 $$x $(DESTDIR)$(HTTP_DOCSDIR)/_asterisk/; \
- done
-@@ -861,10 +839,10 @@
-
- __rpm: include/asterisk/version.h spec
- rm -rf /tmp/asterisk ; \
-- mkdir -p /tmp/asterisk/redhat/RPMS/i386 ; \
-+ $(MKDIR) /tmp/asterisk/redhat/RPMS/i386 ; \
- $(MAKE) DESTDIR=/tmp/asterisk install ; \
- $(MAKE) DESTDIR=/tmp/asterisk samples ; \
-- mkdir -p /tmp/asterisk/etc/rc.d/init.d ; \
-+ $(MKDIR) /tmp/asterisk/etc/rc.d/init.d ; \
- cp -f contrib/init.d/rc.redhat.asterisk /tmp/asterisk/etc/rc.d/init.d/asterisk ; \
- rpmbuild --rcfile /usr/lib/rpm/rpmrc:redhat/rpmrc -bb asterisk.spec
-
diff --git a/net/asterisk-devel/files/patch-agi::Makefile b/net/asterisk-devel/files/patch-agi::Makefile
deleted file mode 100644
index b359765..0000000
--- a/net/asterisk-devel/files/patch-agi::Makefile
+++ /dev/null
@@ -1,28 +0,0 @@
-
-$FreeBSD$
-
---- agi/Makefile.orig Thu Jan 12 15:42:07 2006
-+++ agi/Makefile Thu Jan 12 15:44:39 2006
-@@ -11,7 +11,9 @@
- # the GNU General Public License
- #
-
--AGIS=agi-test.agi eagi-test eagi-sphinx-test
-+AGIS_BIN=eagi-test eagi-sphinx-test
-+AGIS_SCR=agi-test.agi
-+AGIS=$(AGIS_SCR) $(AGIS_BIN)
-
- CFLAGS+=
-
-@@ -27,8 +29,9 @@
- all: depend $(AGIS)
-
- install: all
-- mkdir -p $(DESTDIR)$(AGI_DIR)
-- for x in $(AGIS); do $(INSTALL) -m 755 $$x $(DESTDIR)$(AGI_DIR) ; done
-+ $(MKDIR) -p $(DESTDIR)$(AGI_DIR)
-+ for x in $(AGIS_BIN); do $(BSD_INSTALL_PROGRAM) $$x $(DESTDIR)$(AGI_DIR) ; done
-+ for x in $(AGIS_SCR); do $(BSD_INSTALL_SCRIPT) $$x $(DESTDIR)$(AGI_DIR) ; done
-
- eagi-test: eagi-test.o
- $(CC) $(CFLAGS) -o eagi-test eagi-test.o $(LIBS)
diff --git a/net/asterisk-devel/files/patch-apps::Makefile b/net/asterisk-devel/files/patch-apps::Makefile
deleted file mode 100644
index ee7d560..0000000
--- a/net/asterisk-devel/files/patch-apps::Makefile
+++ /dev/null
@@ -1,79 +0,0 @@
-
-$FreeBSD$
-
---- apps/Makefile.orig
-+++ apps/Makefile
-@@ -45,25 +45,27 @@
- #APPS+=app_rpt.so
-
- ifndef WITHOUT_ZAPTEL
--ifneq ($(wildcard $(CROSS_COMPILE_TARGET)/usr/include/linux/zaptel.h)$(wildcard $(CROSS_COMPILE_TARGET)/usr/local/include/zaptel.h),)
-+ifneq ($(wildcard $(CROSS_COMPILE_TARGET)/usr/include/linux/zaptel.h)$(wildcard $(CROSS_COMPILE_TARGET)$(LOCALBASE)/include/zaptel.h),)
- APPS+=app_zapras.so app_meetme.so app_flash.so app_zapbarge.so app_zapscan.so app_page.so
- endif
- endif # WITHOUT_ZAPTEL
-
--ifneq ($(wildcard $(CROSS_COMPILE_TARGET)/usr/local/include/osp/osp.h $(CROSS_COMPILE_TARGET)/usr/include/osp/osp.h),)
-+ifdef WITH_FAX
-+ifneq ($(wildcard $(CROSS_COMPILE_TARGET)$(LOCALBASE)/include/spandsp.h),)
-+APPS+=app_rxfax.so app_txfax.so
-+endif
-+endif
-+
-+ifneq ($(wildcard $(CROSS_COMPILE_TARGET)$(LOCALBASE)/include/osp/osp.h $(CROSS_COMPILE_TARGET)/usr/include/osp/osp.h),)
- APPS+=app_osplookup.so
- endif
-
- ifeq ($(findstring BSD,${OSARCH}),BSD)
--CFLAGS+=-I$(CROSS_COMPILE_TARGET)/usr/local/include -L$(CROSS_COMPILE_TARGET)/usr/local/lib
-+CFLAGS+=-I$(CROSS_COMPILE_TARGET)$(LOCALBASE)/include -L$(CROSS_COMPILE_TARGET)$(LOCALBASE)/lib
- endif
-
--CURLLIBS=$(shell $(CROSS_COMPILE_BIN)curl-config --libs)
--ifneq ($(shell if [[ 0x`$(CROSS_COMPILE_BIN)curl-config --vernum` -ge 0x70907 ]]; then echo "OK" ; fi),)
-- ifneq (${CURLLIBS},)
-- APPS+=app_curl.so
-- endif
--endif
-+CURLLIBS=$(shell $(CROSS_COMPILE_BIN)$(LOCALBASE)/bin/curl-config --libs)
-+APPS+=app_curl.so
-
- ifeq (${OSARCH},CYGWIN)
- CYGSOLINK=-Wl,--out-implib=lib$@.a -Wl,--export-all-symbols
-@@ -95,24 +97,32 @@
- $(CC) $(SOLINK) -o $@ ${CYGSOLINK} $< ${CYGSOLIB} -ltonezone
-
- install: all
-- for x in $(APPS); do $(INSTALL) -m 755 $$x $(DESTDIR)$(MODULES_DIR) ; done
-+ for x in $(APPS); do $(BSD_INSTALL_PROGRAM) $$x $(DESTDIR)$(MODULES_DIR) ; done
- rm -f $(DESTDIR)$(MODULES_DIR)/app_datetime.so
- rm -f $(DESTDIR)$(MODULES_DIR)/app_qcall.so
-
- app_curl.so: app_curl.o
- $(CC) $(SOLINK) -o $@ ${CYGSOLINK} $< ${CYGSOLIB} $(CURLLIBS)
-
-+ifdef WITH_FAX
-+app_rxfax.so : app_rxfax.o
-+ $(CC) $(SOLINK) -o $@ $< -L$(LOCALBASE)/lib -lspandsp -ltiff
-+
-+app_txfax.so : app_txfax.o
-+ $(CC) $(SOLINK) -o $@ $< -L$(LOCALBASE)/lib -lspandsp -ltiff
-+endif
-+
- app_sql_postgres.o: app_sql_postgres.c
-- $(CC) -pipe -I/usr/local/pgsql/include $(CFLAGS) -c -o app_sql_postgres.o app_sql_postgres.c
-+ $(CC) -I$(LOCALBASE)/include/pgsql $(CFLAGS) -c -o app_sql_postgres.o app_sql_postgres.c
-
- app_sql_postgres.so: app_sql_postgres.o
-- $(CC) $(SOLINK) -o $@ ${CYGSOLINK} $< ${CYGSOLIB} -L/usr/local/pgsql/lib -lpq
-+ $(CC) $(SOLINK) -o $@ ${CYGSOLINK} $< ${CYGSOLIB} -L$(LOCALBASE)/lib -lpq
-
- app_sql_odbc.so: app_sql_odbc.o
- $(CC) $(SOLINK) -o $@ ${CYGSOLINK} $< ${CYGSOLIB} -lodbc
-
- look: look.c
-- $(CC) -pipe -O6 -g look.c -o look -lncurses
-+ $(CC) look.c -o look -lncurses
-
- ifeq (SunOS,$(shell uname))
- app_chanspy.so: app_chanspy.o
diff --git a/net/asterisk-devel/files/patch-apps::app_rxfax.c b/net/asterisk-devel/files/patch-apps::app_rxfax.c
deleted file mode 100644
index 820208e..0000000
--- a/net/asterisk-devel/files/patch-apps::app_rxfax.c
+++ /dev/null
@@ -1,379 +0,0 @@
-
-$FreeBSD$
-
---- /dev/null Thu Jan 12 17:44:40 2006
-+++ apps/app_rxfax.c Thu Jan 12 17:41:53 2006
-@@ -0,0 +1,373 @@
-+/*
-+ * Asterisk -- A telephony toolkit for Linux.
-+ *
-+ * Trivial application to receive a TIFF FAX file
-+ *
-+ * Copyright (C) 2003, Steve Underwood
-+ *
-+ * Steve Underwood <steveu@coppice.org>
-+ *
-+ * This program is free software, distributed under the terms of
-+ * the GNU General Public License
-+ */
-+
-+#include <stdio.h>
-+#include <asterisk/lock.h>
-+#include <asterisk/file.h>
-+#include <asterisk/logger.h>
-+#include <asterisk/channel.h>
-+#include <asterisk/pbx.h>
-+#include <asterisk/module.h>
-+#include <asterisk/translate.h>
-+#include <asterisk/dsp.h>
-+#include <asterisk/manager.h>
-+#include <asterisk/version.h>
-+#include <string.h>
-+#include <stdlib.h>
-+#if defined(__FreeBSD__) && __FreeBSD_version < 500028
-+#include <inttypes.h>
-+#else
-+#include <stdint.h>
-+#endif
-+#include <pthread.h>
-+#include <errno.h>
-+#include <math.h>
-+#include <tiffio.h>
-+
-+#include <spandsp.h>
-+
-+static char *tdesc = "Trivial FAX Receive Application";
-+
-+static char *app = "RxFAX";
-+
-+static char *synopsis = "Receive a FAX to a file";
-+
-+static char *descrip =
-+" RxFAX(filename[|caller][|debug]): Receives a FAX from the channel into the\n"
-+"given filename. If the file exists it will be overwritten. The file\n"
-+"should be in TIFF/F format.\n"
-+"The \"caller\" option makes the application behave as a calling machine,\n"
-+"rather than the answering machine. The default behaviour is to behave as\n"
-+"an answering machine.\n"
-+"Uses LOCALSTATIONID to identify itself to the remote end.\n"
-+" LOCALHEADERINFO to generate a header line on each page.\n"
-+"Sets REMOTESTATIONID to the sender CSID.\n"
-+" FAXPAGES to the number of pages received.\n"
-+" FAXBITRATE to the transmition rate.\n"
-+" FAXRESOLUTION to the resolution.\n"
-+"Returns -1 when the user hangs up.\n"
-+"Returns 0 otherwise.\n";
-+
-+STANDARD_LOCAL_USER;
-+
-+LOCAL_USER_DECL;
-+
-+#define MAX_BLOCK_SIZE 240
-+
-+static void t30_flush(t30_state_t *s, int which)
-+{
-+ //TODO:
-+}
-+/*- End of function --------------------------------------------------------*/
-+
-+static void phase_e_handler(t30_state_t *s, void *user_data, int result)
-+{
-+ struct ast_channel *chan;
-+ t30_stats_t t;
-+ char local_ident[21];
-+ char far_ident[21];
-+ char buf[11];
-+
-+ chan = (struct ast_channel *) user_data;
-+ if (result)
-+ {
-+ fax_get_transfer_statistics(s, &t);
-+ fax_get_far_ident(s, far_ident);
-+ fax_get_local_ident(s, local_ident);
-+ ast_log(LOG_DEBUG, "==============================================================================\n");
-+ ast_log(LOG_DEBUG, "Fax successfully received.\n");
-+ ast_log(LOG_DEBUG, "Remote station id: %s\n", far_ident);
-+ ast_log(LOG_DEBUG, "Local station id: %s\n", local_ident);
-+ ast_log(LOG_DEBUG, "Pages transferred: %i\n", t.pages_transferred);
-+ ast_log(LOG_DEBUG, "Image resolution: %i x %i\n", t.column_resolution, t.row_resolution);
-+ ast_log(LOG_DEBUG, "Transfer Rate: %i\n", t.bit_rate);
-+ ast_log(LOG_DEBUG, "==============================================================================\n");
-+ manager_event(EVENT_FLAG_CALL,
-+ "FaxReceived", "Channel: %s\nExten: %s\nCallerID: %s\nRemoteStationID: %s\nLocalStationID: %s\nPagesTransferred: %i\nResolution: %i\nTransferRate: %i\nFileName: %s\n",
-+ chan->name,
-+ chan->exten,
-+#if ASTERISK_VERSION_NUM <= 010010
-+ chan->callerid,
-+#else
-+ (chan->cid.cid_num) ? chan->cid.cid_num : "",
-+#endif
-+ far_ident,
-+ local_ident,
-+ t.pages_transferred,
-+ t.row_resolution,
-+ t.bit_rate,
-+ s->rx_file);
-+ pbx_builtin_setvar_helper(chan, "REMOTESTATIONID", far_ident);
-+ snprintf(buf, sizeof(buf), "%i", t.pages_transferred);
-+ pbx_builtin_setvar_helper(chan, "FAXPAGES", buf);
-+ snprintf(buf, sizeof(buf), "%i", t.row_resolution);
-+ pbx_builtin_setvar_helper(chan, "FAXRESOLUTION", buf);
-+ snprintf(buf, sizeof(buf), "%i", t.bit_rate);
-+ pbx_builtin_setvar_helper(chan, "FAXBITRATE", buf);
-+ }
-+ else
-+ {
-+ ast_log(LOG_DEBUG, "==============================================================================\n");
-+ ast_log(LOG_DEBUG, "Fax receive not successful.\n");
-+ ast_log(LOG_DEBUG, "==============================================================================\n");
-+ }
-+}
-+/*- End of function --------------------------------------------------------*/
-+
-+static void phase_d_handler(t30_state_t *s, void *user_data, int result)
-+{
-+ struct ast_channel *chan;
-+ t30_stats_t t;
-+
-+ chan = (struct ast_channel *) user_data;
-+ if (result)
-+ {
-+ fax_get_transfer_statistics(s, &t);
-+ ast_log(LOG_DEBUG, "==============================================================================\n");
-+ ast_log(LOG_DEBUG, "Pages transferred: %i\n", t.pages_transferred);
-+ ast_log(LOG_DEBUG, "Image size: %i x %i\n", t.columns, t.rows);
-+ ast_log(LOG_DEBUG, "Image resolution %i x %i\n", t.column_resolution, t.row_resolution);
-+ ast_log(LOG_DEBUG, "Transfer Rate: %i\n", t.bit_rate);
-+ ast_log(LOG_DEBUG, "Bad rows %i\n", t.bad_rows);
-+ ast_log(LOG_DEBUG, "Longest bad row run %i\n", t.longest_bad_row_run);
-+ ast_log(LOG_DEBUG, "Compression type %i\n", t.encoding);
-+ ast_log(LOG_DEBUG, "Image size (bytes) %i\n", t.image_size);
-+ ast_log(LOG_DEBUG, "==============================================================================\n");
-+ }
-+}
-+/*- End of function --------------------------------------------------------*/
-+
-+static int rxfax_exec(struct ast_channel *chan, void *data)
-+{
-+ int res = 0;
-+ char template_file[256];
-+ char target_file[256];
-+ char *s;
-+ char *t;
-+ char *v;
-+ char *x;
-+ int option;
-+ int len;
-+ int i;
-+ t30_state_t fax;
-+ int calling_party;
-+ int verbose;
-+ int samples;
-+
-+ struct localuser *u;
-+ struct ast_frame *inf = NULL;
-+ struct ast_frame outf;
-+
-+ int original_read_fmt;
-+ int original_write_fmt;
-+
-+ uint8_t __buf[sizeof(uint16_t)*MAX_BLOCK_SIZE + 2*AST_FRIENDLY_OFFSET];
-+ uint8_t *buf = __buf + AST_FRIENDLY_OFFSET;
-+
-+ if (chan == NULL)
-+ {
-+ ast_log(LOG_WARNING, "Fax receive channel is NULL. Giving up.\n");
-+ return -1;
-+ }
-+
-+ /* The next few lines of code parse out the filename and header from the input string */
-+ if (data == NULL)
-+ {
-+ /* No data implies no filename or anything is present */
-+ ast_log(LOG_WARNING, "Rxfax requires an argument (filename)\n");
-+ return -1;
-+ }
-+
-+ calling_party = FALSE;
-+ verbose = FALSE;
-+ target_file[0] = '\0';
-+
-+ for (option = 0, v = s = data; v; option++, s++)
-+ {
-+ t = s;
-+ v = strchr(s, '|');
-+ s = (v) ? v : s + strlen(s);
-+ strncpy(buf, t, s - t);
-+ buf[s - t] = '\0';
-+ if (option == 0)
-+ {
-+ /* The first option is always the file name */
-+ len = s - t;
-+ if (len > 255)
-+ len = 255;
-+ strncpy(target_file, t, len);
-+ target_file[len] = '\0';
-+ /* Allow the use of %d in the file name for a wild card of sorts, to
-+ create a new file with the specified name scheme */
-+ if ((x = strchr(target_file, '%')) && x[1] == 'd')
-+ {
-+ strcpy(template_file, target_file);
-+ i = 0;
-+ do
-+ {
-+ snprintf(target_file, 256, template_file, 1);
-+ i++;
-+ }
-+ while (ast_fileexists(target_file, "", chan->language) != -1);
-+ }
-+ }
-+ else if (strncmp("caller", t, s - t) == 0)
-+ {
-+ calling_party = TRUE;
-+ }
-+ else if (strncmp("debug", t, s - t) == 0)
-+ {
-+ verbose = TRUE;
-+ }
-+ }
-+
-+ /* Done parsing */
-+
-+ LOCAL_USER_ADD(u);
-+
-+ if (chan->_state != AST_STATE_UP)
-+ {
-+ /* Shouldn't need this, but checking to see if channel is already answered
-+ * Theoretically asterisk should already have answered before running the app */
-+ res = ast_answer(chan);
-+ }
-+
-+ if (!res)
-+ {
-+ original_read_fmt = chan->readformat;
-+ if (original_read_fmt != AST_FORMAT_SLINEAR)
-+ {
-+ res = ast_set_read_format(chan, AST_FORMAT_SLINEAR);
-+ if (res < 0)
-+ {
-+ ast_log(LOG_WARNING, "Unable to set to linear read mode, giving up\n");
-+ return -1;
-+ }
-+ }
-+ original_write_fmt = chan->writeformat;
-+ if (original_write_fmt != AST_FORMAT_SLINEAR)
-+ {
-+ res = ast_set_write_format(chan, AST_FORMAT_SLINEAR);
-+ if (res < 0)
-+ {
-+ ast_log(LOG_WARNING, "Unable to set to linear write mode, giving up\n");
-+ res = ast_set_read_format(chan, original_read_fmt);
-+ if (res)
-+ ast_log(LOG_WARNING, "Unable to restore read format on '%s'\n", chan->name);
-+ return -1;
-+ }
-+ }
-+ fax_init(&fax, calling_party, NULL);
-+ fax.verbose = verbose;
-+ x = pbx_builtin_getvar_helper(chan, "LOCALSTATIONID");
-+ if (x && x[0])
-+ fax_set_local_ident(&fax, x);
-+ x = pbx_builtin_getvar_helper(chan, "LOCALHEADERINFO");
-+ if (x && x[0])
-+ fax_set_header_info(&fax, x);
-+ fax_set_rx_file(&fax, target_file);
-+ //fax_set_phase_b_handler(&fax, phase_b_handler, chan);
-+ fax_set_phase_d_handler(&fax, phase_d_handler, chan);
-+ fax_set_phase_e_handler(&fax, phase_e_handler, chan);
-+ while (ast_waitfor(chan, -1) > -1)
-+ {
-+ inf = ast_read(chan);
-+ if (inf == NULL)
-+ {
-+ res = -1;
-+ break;
-+ }
-+ if (inf->frametype == AST_FRAME_VOICE)
-+ {
-+ if (fax_rx_process(&fax, inf->data, inf->samples))
-+ break;
-+ samples = (inf->samples <= MAX_BLOCK_SIZE) ? inf->samples : MAX_BLOCK_SIZE;
-+ len = fax_tx_process(&fax, (int16_t *) &buf[AST_FRIENDLY_OFFSET], samples);
-+ if (len)
-+ {
-+ memset(&outf, 0, sizeof(outf));
-+ outf.frametype = AST_FRAME_VOICE;
-+ outf.subclass = AST_FORMAT_SLINEAR;
-+ outf.datalen = len*sizeof(int16_t);
-+ outf.samples = len;
-+ outf.data = &buf[AST_FRIENDLY_OFFSET];
-+ outf.offset = AST_FRIENDLY_OFFSET;
-+ outf.src = "RxFAX";
-+ if (ast_write(chan, &outf) < 0)
-+ {
-+ ast_log(LOG_WARNING, "Unable to write frame to channel; %s\n", strerror(errno));
-+ break;
-+ }
-+ }
-+ }
-+ ast_frfree(inf);
-+ }
-+ if (inf == NULL)
-+ {
-+ ast_log(LOG_DEBUG, "Got hangup\n");
-+ res = -1;
-+ }
-+ if (original_read_fmt != AST_FORMAT_SLINEAR)
-+ {
-+ res = ast_set_read_format(chan, original_read_fmt);
-+ if (res)
-+ ast_log(LOG_WARNING, "Unable to restore read format on '%s'\n", chan->name);
-+ }
-+ if (original_write_fmt != AST_FORMAT_SLINEAR)
-+ {
-+ res = ast_set_write_format(chan, original_write_fmt);
-+ if (res)
-+ ast_log(LOG_WARNING, "Unable to restore write format on '%s'\n", chan->name);
-+ }
-+ }
-+ else
-+ {
-+ ast_log(LOG_WARNING, "Could not answer channel '%s'\n", chan->name);
-+ }
-+ LOCAL_USER_REMOVE(u);
-+ return res;
-+}
-+/*- End of function --------------------------------------------------------*/
-+
-+int unload_module(void)
-+{
-+ STANDARD_HANGUP_LOCALUSERS;
-+ return ast_unregister_application(app);
-+}
-+/*- End of function --------------------------------------------------------*/
-+
-+int load_module(void)
-+{
-+ return ast_register_application(app, rxfax_exec, synopsis, descrip);
-+}
-+
-+char *description(void)
-+{
-+ return tdesc;
-+}
-+/*- End of function --------------------------------------------------------*/
-+
-+int usecount(void)
-+{
-+ int res;
-+ STANDARD_USECOUNT(res);
-+ return res;
-+}
-+/*- End of function --------------------------------------------------------*/
-+
-+char *key(void)
-+{
-+ return ASTERISK_GPL_KEY;
-+}
-+/*- End of function --------------------------------------------------------*/
-+/*- End of file ------------------------------------------------------------*/
diff --git a/net/asterisk-devel/files/patch-apps::app_txfax.c b/net/asterisk-devel/files/patch-apps::app_txfax.c
deleted file mode 100644
index 15ad667..0000000
--- a/net/asterisk-devel/files/patch-apps::app_txfax.c
+++ /dev/null
@@ -1,301 +0,0 @@
-
-$FreeBSD$
-
---- /dev/null Thu Jan 12 17:48:54 2006
-+++ apps/app_txfax.c Thu Jan 12 17:48:36 2006
-@@ -0,0 +1,295 @@
-+/*
-+ * Asterisk -- A telephony toolkit for Linux.
-+ *
-+ * Trivial application to send a TIFF file as a FAX
-+ *
-+ * Copyright (C) 2003, Steve Underwood
-+ *
-+ * Steve Underwood <steveu@coppice.org>
-+ *
-+ * This program is free software, distributed under the terms of
-+ * the GNU General Public License
-+ */
-+
-+#include <stdio.h>
-+#include <asterisk/lock.h>
-+#include <asterisk/file.h>
-+#include <asterisk/logger.h>
-+#include <asterisk/channel.h>
-+#include <asterisk/pbx.h>
-+#include <asterisk/module.h>
-+#include <asterisk/translate.h>
-+#include <string.h>
-+#include <stdlib.h>
-+#include <math.h>
-+#if defined(__FreeBSD__) && __FreeBSD_version < 500028
-+#include <inttypes.h>
-+#else
-+#include <stdint.h>
-+#endif
-+#include <pthread.h>
-+#include <errno.h>
-+#include <tiffio.h>
-+
-+#include <spandsp.h>
-+
-+static char *tdesc = "Trivial FAX Transmit Application";
-+
-+static char *app = "TxFAX";
-+
-+static char *synopsis = "Send a FAX file";
-+
-+static char *descrip =
-+" TxFAX(filename[|caller][|debug]): Send a given TIFF file to the channel as a FAX.\n"
-+"The \"caller\" option makes the application behave as a calling machine,\n"
-+"rather than the answering machine. The default behaviour is to behave as\n"
-+"an answering machine.\n"
-+"Uses LOCALSTATIONID to identify itself to the remote end.\n"
-+" LOCALHEADERINFO to generate a header line on each page.\n"
-+"Sets REMOTESTATIONID to the receiver CSID.\n"
-+"Returns -1 when the user hangs up, or if the file does not exist.\n"
-+"Returns 0 otherwise.\n";
-+
-+STANDARD_LOCAL_USER;
-+
-+LOCAL_USER_DECL;
-+
-+#define MAX_BLOCK_SIZE 240
-+
-+static void t30_flush(t30_state_t *s, int which)
-+{
-+ //TODO:
-+}
-+/*- End of function --------------------------------------------------------*/
-+
-+static void phase_e_handler(t30_state_t *s, void *user_data, int result)
-+{
-+ struct ast_channel *chan;
-+ char far_ident[21];
-+
-+ chan = (struct ast_channel *) user_data;
-+ if (result)
-+ {
-+ fax_get_far_ident(s, far_ident);
-+ pbx_builtin_setvar_helper(chan, "REMOTESTATIONID", far_ident);
-+ }
-+ else
-+ {
-+ ast_log(LOG_DEBUG, "==============================================================================\n");
-+ ast_log(LOG_DEBUG, "Fax send not successful.\n");
-+ ast_log(LOG_DEBUG, "==============================================================================\n");
-+ }
-+}
-+/*- End of function --------------------------------------------------------*/
-+
-+static int txfax_exec(struct ast_channel *chan, void *data)
-+{
-+ int res = 0;
-+ char source_file[256];
-+ char *x;
-+ char *s;
-+ char *t;
-+ char *v;
-+ int option;
-+ int len;
-+ t30_state_t fax;
-+ int calling_party;
-+ int verbose;
-+ int samples;
-+
-+ struct localuser *u;
-+ struct ast_frame *inf = NULL;
-+ struct ast_frame outf;
-+
-+ int original_read_fmt;
-+ int original_write_fmt;
-+
-+ uint8_t __buf[sizeof(uint16_t)*MAX_BLOCK_SIZE + 2*AST_FRIENDLY_OFFSET];
-+ uint8_t *buf = __buf + AST_FRIENDLY_OFFSET;
-+
-+ if (chan == NULL)
-+ {
-+ ast_log(LOG_WARNING, "Fax transmit channel is NULL. Giving up.\n");
-+ return -1;
-+ }
-+
-+ /* The next few lines of code parse out the filename and header from the input string */
-+ if (data == NULL)
-+ {
-+ /* No data implies no filename or anything is present */
-+ ast_log(LOG_WARNING, "Txfax requires an argument (filename)\n");
-+ return -1;
-+ }
-+
-+ calling_party = FALSE;
-+ verbose = FALSE;
-+ source_file[0] = '\0';
-+
-+ for (option = 0, v = s = data; v; option++, s++)
-+ {
-+ t = s;
-+ v = strchr(s, '|');
-+ s = (v) ? v : s + strlen(s);
-+ strncpy(buf, t, s - t);
-+ buf[s - t] = '\0';
-+ if (option == 0)
-+ {
-+ /* The first option is always the file name */
-+ len = s - t;
-+ if (len > 255)
-+ len = 255;
-+ strncpy(source_file, t, len);
-+ source_file[len] = '\0';
-+ }
-+ else if (strncmp("caller", t, s - t) == 0)
-+ {
-+ calling_party = TRUE;
-+ }
-+ else if (strncmp("debug", t, s - t) == 0)
-+ {
-+ verbose = TRUE;
-+ }
-+ }
-+
-+ /* Done parsing */
-+
-+ LOCAL_USER_ADD(u);
-+
-+ if (chan->_state != AST_STATE_UP)
-+ {
-+ /* Shouldn't need this, but checking to see if channel is already answered
-+ * Theoretically asterisk should already have answered before running the app */
-+ res = ast_answer(chan);
-+ }
-+
-+ if (!res)
-+ {
-+ original_read_fmt = chan->readformat;
-+ if (original_read_fmt != AST_FORMAT_SLINEAR)
-+ {
-+ res = ast_set_read_format(chan, AST_FORMAT_SLINEAR);
-+ if (res < 0)
-+ {
-+ ast_log(LOG_WARNING, "Unable to set to linear read mode, giving up\n");
-+ return -1;
-+ }
-+ }
-+ original_write_fmt = chan->writeformat;
-+ if (original_write_fmt != AST_FORMAT_SLINEAR)
-+ {
-+ res = ast_set_write_format(chan, AST_FORMAT_SLINEAR);
-+ if (res < 0)
-+ {
-+ ast_log(LOG_WARNING, "Unable to set to linear write mode, giving up\n");
-+ res = ast_set_read_format(chan, original_read_fmt);
-+ if (res)
-+ ast_log(LOG_WARNING, "Unable to restore read format on '%s'\n", chan->name);
-+ return -1;
-+ }
-+ }
-+ fax_init(&fax, calling_party, NULL);
-+ fax.verbose = verbose;
-+
-+ x = pbx_builtin_getvar_helper(chan, "LOCALSTATIONID");
-+ if (x && x[0])
-+ fax_set_local_ident(&fax, x);
-+ x = pbx_builtin_getvar_helper(chan, "LOCALHEADERINFO");
-+ if (x && x[0])
-+ fax_set_header_info(&fax, x);
-+ fax_set_tx_file(&fax, source_file);
-+ //fax_set_phase_b_handler(&fax, phase_b_handler, chan);
-+ //fax_set_phase_d_handler(&fax, phase_d_handler, chan);
-+ fax_set_phase_e_handler(&fax, phase_e_handler, chan);
-+ while (ast_waitfor(chan, -1) > -1)
-+ {
-+ inf = ast_read(chan);
-+ if (inf == NULL)
-+ {
-+ res = -1;
-+ break;
-+ }
-+ if (inf->frametype == AST_FRAME_VOICE)
-+ {
-+ if (fax_rx_process(&fax, inf->data, inf->samples))
-+ break;
-+ samples = (inf->samples <= MAX_BLOCK_SIZE) ? inf->samples : MAX_BLOCK_SIZE;
-+ len = fax_tx_process(&fax, (int16_t *) &buf[AST_FRIENDLY_OFFSET], samples);
-+ if (len)
-+ {
-+ memset(&outf, 0, sizeof(outf));
-+ outf.frametype = AST_FRAME_VOICE;
-+ outf.subclass = AST_FORMAT_SLINEAR;
-+ outf.datalen = len*sizeof(int16_t);
-+ outf.samples = len;
-+ outf.data = &buf[AST_FRIENDLY_OFFSET];
-+ outf.offset = AST_FRIENDLY_OFFSET;
-+ if (ast_write(chan, &outf) < 0)
-+ {
-+ ast_log(LOG_WARNING, "Unable to write frame to channel; %s\n", strerror(errno));
-+ break;
-+ }
-+ }
-+ }
-+ ast_frfree(inf);
-+ }
-+ if (inf == NULL)
-+ {
-+ ast_log(LOG_DEBUG, "Got hangup\n");
-+ res = -1;
-+ }
-+ if (original_read_fmt != AST_FORMAT_SLINEAR)
-+ {
-+ res = ast_set_read_format(chan, original_read_fmt);
-+ if (res)
-+ ast_log(LOG_WARNING, "Unable to restore read format on '%s'\n", chan->name);
-+ }
-+ if (original_write_fmt != AST_FORMAT_SLINEAR)
-+ {
-+ res = ast_set_write_format(chan, original_write_fmt);
-+ if (res)
-+ ast_log(LOG_WARNING, "Unable to restore write format on '%s'\n", chan->name);
-+ }
-+ }
-+ else
-+ {
-+ ast_log(LOG_WARNING, "Could not answer channel '%s'\n", chan->name);
-+ }
-+ LOCAL_USER_REMOVE(u);
-+ return res;
-+}
-+/*- End of function --------------------------------------------------------*/
-+
-+int unload_module(void)
-+{
-+ STANDARD_HANGUP_LOCALUSERS;
-+ return ast_unregister_application(app);
-+}
-+/*- End of function --------------------------------------------------------*/
-+
-+int load_module(void)
-+{
-+ return ast_register_application(app, txfax_exec, synopsis, descrip);
-+}
-+/*- End of function --------------------------------------------------------*/
-+
-+char *description(void)
-+{
-+ return tdesc;
-+}
-+/*- End of function --------------------------------------------------------*/
-+
-+int usecount(void)
-+{
-+ int res;
-+
-+ STANDARD_USECOUNT(res);
-+ return res;
-+}
-+/*- End of function --------------------------------------------------------*/
-+
-+char *key(void)
-+{
-+ return ASTERISK_GPL_KEY;
-+}
-+/*- End of function --------------------------------------------------------*/
-+/*- End of file ------------------------------------------------------------*/
diff --git a/net/asterisk-devel/files/patch-cdr::Makefile b/net/asterisk-devel/files/patch-cdr::Makefile
deleted file mode 100644
index da16b60..0000000
--- a/net/asterisk-devel/files/patch-cdr::Makefile
+++ /dev/null
@@ -1,70 +0,0 @@
-
-$FreeBSD$
-
---- cdr/Makefile.orig Tue Nov 29 20:24:39 2005
-+++ cdr/Makefile Thu Jan 12 17:56:23 2006
-@@ -21,8 +21,8 @@
- endif
-
- ifeq ($(findstring BSD,${OSARCH}),BSD)
-- CFLAGS+=-I$(CROSS_COMPILE_TARGET)/usr/local/include
-- SOLINK+=-L$(CROSS_COMPILE_TARGET)/usr/local/lib
-+ CFLAGS+=-I$(CROSS_COMPILE_TARGET)$(LOCALBASE)/include
-+ SOLINK+=-L$(CROSS_COMPILE_TARGET)$(LOCALBASE)/lib
- endif
-
- #The problem with sparc is the best stuff is in newer versions of gcc (post 3.0) only.
-@@ -38,18 +38,18 @@
- #
- # unixODBC stuff...
- #
--ifneq ($(wildcard $(CROSS_COMPILE_TARGET)/usr/include/odbcinst.h)$(wildcard $(CROSS_COMPILE_TARGET)/usr/local/include/odbcinst.h),)
-+ifneq ($(wildcard $(CROSS_COMPILE_TARGET)/usr/include/odbcinst.h)$(wildcard $(CROSS_COMPILE_TARGET)$(LOCALBASE)/include/odbcinst.h),)
- MODS+=cdr_odbc.so
- endif
-
- #
- # FreeTDS stuff...
- #
--ifneq ($(wildcard $(CROSS_COMPILE_TARGET)/usr/include/tds.h)$(wildcard $(CROSS_COMPILE_TARGET)/usr/local/include/tds.h),)
-- ifeq ($(shell grep -s TDS_VERSION_NO $(CROSS_COMPILE_TARGET)/usr/include/tdsver.h $(CROSS_COMPILE_TARGET)/usr/local/include/tdsver.h | grep -c 0.63),1)
-+ifneq ($(wildcard $(CROSS_COMPILE_TARGET)/usr/include/tds.h)$(wildcard $(CROSS_COMPILE_TARGET)$(LOCALBASE)/include/tds.h),)
-+ ifeq ($(shell grep -s TDS_VERSION_NO $(CROSS_COMPILE_TARGET)/usr/include/tdsver.h $(CROSS_COMPILE_TARGET)$(LOCALBASE)/include/tdsver.h | grep -c 0.63),1)
- CFLAGS += -DFREETDS_0_63
- else
-- ifeq ($(shell grep -s TDS_VERSION_NO $(CROSS_COMPILE_TARGET)/usr/include/tdsver.h $(CROSS_COMPILE_TARGET)/usr/local/include/tdsver.h | grep -c 0.62),1)
-+ ifeq ($(shell grep -s TDS_VERSION_NO $(CROSS_COMPILE_TARGET)/usr/include/tdsver.h $(CROSS_COMPILE_TARGET)$(LOCALBASE)/include/tdsver.h | grep -c 0.62),1)
- CFLAGS += -DFREETDS_0_62
- else
- CFLAGS += -DFREETDS_PRE_0_62
-@@ -61,7 +61,7 @@
- #
- # PGSQL stuff... Autoconf anyone??
- #
--ifneq ($(wildcard $(CROSS_COMPILE_TARGET)/usr/include/postgresql)$(wildcard $(CROSS_COMPILE_TARGET)/usr/local/pgsql/include)$(wildcard $(CROSS_COMPILE_TARGET)/usr/include/pgsql)$(wildcard $(CROSS_COMPILE_TARGET)/usr/local/include/pgsql)$(wildcard $(CROSS_COMPILE_TARGET)/opt/pgsql/include)$(wildcard $(CROSS_COMPILE_TARGET)/usr/include/libpq-fe.h),)
-+ifneq ($(wildcard $(CROSS_COMPILE_TARGET)/usr/include/postgresql)$(wildcard $(CROSS_COMPILE_TARGET)/usr/local/pgsql/include)$(wildcard $(CROSS_COMPILE_TARGET)/usr/include/pgsql)$(wildcard $(CROSS_COMPILE_TARGET)$(LOCALBASE)/include/pgsql)$(wildcard $(CROSS_COMPILE_TARGET)/opt/pgsql/include)$(wildcard $(CROSS_COMPILE_TARGET)/usr/include/libpq-fe.h),)
- MODS+=cdr_pgsql.so
- endif
-
-@@ -82,9 +82,9 @@
- MLFLAGS+=-L$(CROSS_COMPILE_TARGET)/usr/lib/pgsql
- endif
-
--ifneq ($(wildcard $(CROSS_COMPILE_TARGET)/usr/local/include/pgsql),)
-- CFLAGS+=-I$(CROSS_COMPILE_TARGET)/usr/local/include/pgsql
-- MLFLAGS+=-L$(CROSS_COMPILE_TARGET)/usr/local/lib/pgsql
-+ifneq ($(wildcard $(CROSS_COMPILE_TARGET)$(LOCALBASE)/include/pgsql),)
-+ CFLAGS+=-I$(CROSS_COMPILE_TARGET)$(LOCALBASE)/include/pgsql
-+ MLFLAGS+=-L$(CROSS_COMPILE_TARGET)$(LOCALBASE)/lib/pgsql
- endif
-
- ifneq ($(wildcard $(CROSS_COMPILE_TARGET)/opt/pgsql/include),)
-@@ -110,7 +110,7 @@
- all: depend $(MODS)
-
- install: all
-- for x in $(MODS); do $(INSTALL) -m 755 $$x $(DESTDIR)$(MODULES_DIR) ; done
-+ for x in $(MODS); do $(BSD_INSTALL_PROGRAM) $$x $(DESTDIR)$(MODULES_DIR) ; done
-
- clean:
- rm -f *.so *.o .depend
diff --git a/net/asterisk-devel/files/patch-channels::Makefile b/net/asterisk-devel/files/patch-channels::Makefile
deleted file mode 100644
index edca9b1..0000000
--- a/net/asterisk-devel/files/patch-channels::Makefile
+++ /dev/null
@@ -1,85 +0,0 @@
-
-$FreeBSD$
-
---- channels/Makefile.orig
-+++ channels/Makefile
-@@ -48,9 +48,9 @@
- endif
-
- ifeq (${OSARCH},FreeBSD)
-- PTLIB=-lpt_FreeBSD_x86_r
-- H323LIB=-lh323_FreeBSD_x86_r
-- CHANH323LIB=-pthread
-+ PTLIB=-lpt_FreeBSD_x86_r_s
-+ H323LIB=-lh323_FreeBSD_x86_r_s
-+ CHANH323LIB=
- endif
-
- ifeq (${OSARCH},NetBSD)
-@@ -73,11 +73,11 @@
- SOLINK+=-lrt
- endif
-
--ifneq ($(wildcard $(CROSS_COMPILE_TARGET)/usr/include/linux/ixjuser.h)$(wildcard $(CROSS_COMPILE_TARGET)/usr/local/include/ixjuser.h),)
-+ifneq ($(wildcard $(CROSS_COMPILE_TARGET)/usr/include/linux/ixjuser.h)$(wildcard $(CROSS_COMPILE_TARGET)$(LOCALBASE)/include/ixjuser.h),)
- CHANNEL_LIBS+=chan_phone.so
- endif
-
--ifneq ($(wildcard h323/libchanh323.a),)
-+ifdef WITH_H323
- CHANNEL_LIBS+=chan_h323.so
- endif
-
-@@ -91,12 +91,12 @@
- CHANNEL_LIBS+=chan_alsa.so
- endif
-
--ifneq ($(wildcard $(CROSS_COMPILE_TARGET)/usr/lib/libpri.so.1)$(wildcard $(CROSS_COMPILE_TARGET)/usr/local/lib/libpri.so.1),)
-+ifneq ($(wildcard $(CROSS_COMPILE_TARGET)/usr/lib/libpri.so.1)$(wildcard $(CROSS_COMPILE_TARGET)$(LOCALBASE)/lib/libpri.so.1),)
- CFLAGS+=-DZAPATA_PRI
- ZAPPRI=-lpri
- endif
-
--ifneq ($(wildcard $(CROSS_COMPILE_TARGET)/usr/lib/libmfcr2.so.1)$(wildcard $(CROSS_COMPILE_TARGET)/usr/local/lib/libmfcr2.so.1),)
-+ifneq ($(wildcard $(CROSS_COMPILE_TARGET)/usr/lib/libmfcr2.so.1)$(wildcard $(CROSS_COMPILE_TARGET)$(LOCALBASE)/lib/libmfcr2.so.1),)
- CFLAGS+=-DZAPATA_R2
- ZAPR2=-lmfcr2
- endif
-@@ -109,12 +109,12 @@
- endif
-
- ifndef WITHOUT_ZAPTEL
--ifneq ($(wildcard $(CROSS_COMPILE_TARGET)/usr/include/linux/zaptel.h)$(wildcard $(CROSS_COMPILE_TARGET)/usr/local/include/zaptel.h)$(wildcard $(CROSS_COMPILE_TARGET)/usr/pkg/include/zaptel.h),)
-+ifneq ($(wildcard $(CROSS_COMPILE_TARGET)/usr/include/linux/zaptel.h)$(wildcard $(CROSS_COMPILE_TARGET)$(LOCALBASE)/include/zaptel.h)$(wildcard $(CROSS_COMPILE_TARGET)/usr/pkg/include/zaptel.h),)
- ifeq (${OSARCH},NetBSD)
- SOLINK+=-L$(CROSS_COMPILE_TARGET)/usr/pkg/lib
- endif
- ifeq (${OSARCH},FreeBSD)
-- SOLINK+=-L$(CROSS_COMPILE_TARGET)/usr/local/lib
-+ SOLINK+=-L$(CROSS_COMPILE_TARGET)$(LOCALBASE)/lib
- endif
- CFLAGS+=-DIAX_TRUNKING
- CHANNEL_LIBS+=chan_zap.so
-@@ -229,8 +229,10 @@
- chan_h323.so: chan_h323.o h323/libchanh323.a h323/Makefile.ast
- $(CC) $(SOLINK) $(H323LDFLAGS) -o $@ $< h323/libchanh323.a $(H323LDLIBS) -lstdc++
- else
--chan_h323.so: chan_h323.o h323/libchanh323.a
-- $(CC) $(SOLINK) -o $@ $< h323/libchanh323.a $(CHANH323LIB) -L$(PWLIBDIR)/lib $(PTLIB) -L$(OPENH323DIR)/lib $(H323LIB) -L/usr/lib -lcrypto -lssl -lexpat
-+chan_h323.so: chan_h323.o h323/ast_h323.o
-+ $(CXX) $(SOLINK) -o $@ $< h323/ast_h323.o $(CHANH323LIB) -L$(OPENH323DIR)/lib $(H323LIB) -L$(PWLIBDIR)/lib $(PTLIB) -L/usr/lib -lcrypto -lssl -lexpat -L$(LOCALBASE)/lib -llber -lldap -lldap_r
-+h323/ast_h323.o:
-+ $(MAKE) -C h323 ast_h323.o
- endif
-
- chan_misdn.so: chan_misdn.o chan_misdn_config.o misdn/chan_misdn_lib.a
-@@ -244,8 +246,7 @@
- # $(CC) -rdynamic -shared -Xlinker -x -o $@ $<
-
- install: all
-- for x in $(CHANNEL_LIBS); do $(INSTALL) -m 755 $$x $(DESTDIR)$(MODULES_DIR) ; done
-- if ! [ -f chan_iax.so ]; then rm -f $(DESTDIR)$(MODULES_DIR)/chan_iax.so ; fi
-+ for x in $(CHANNEL_LIBS); do $(BSD_INSTALL_PROGRAM) $$x $(DESTDIR)$(MODULES_DIR) ; done
-
- depend: .depend
-
diff --git a/net/asterisk-devel/files/patch-channels::chan_sip.c b/net/asterisk-devel/files/patch-channels::chan_sip.c
deleted file mode 100644
index 2b2fae7..0000000
--- a/net/asterisk-devel/files/patch-channels::chan_sip.c
+++ /dev/null
@@ -1,131 +0,0 @@
-
-$FreeBSD$
-
---- channels/chan_sip.c.orig Tue Jan 24 16:25:53 2006
-+++ channels/chan_sip.c Tue Jan 24 16:30:44 2006
-@@ -337,7 +337,7 @@ static char global_vmexten[AST_MAX_EXTEN
-
- static char default_language[MAX_LANGUAGE] = "";
-
--#define DEFAULT_CALLERID "asterisk"
-+#define DEFAULT_CALLERID "Unknown"
- static char default_callerid[AST_MAX_EXTENSION] = DEFAULT_CALLERID;
-
- static char default_fromdomain[AST_MAX_EXTENSION] = "";
-@@ -475,6 +475,7 @@ struct sip_invite_param {
-
- struct sip_route {
- struct sip_route *next;
-+ int lr;
- char hop[0];
- };
-
-@@ -6015,6 +6016,7 @@ static void build_route(struct sip_pvt *
- /* Make a struct route */
- thishop = malloc(sizeof(*thishop) + len);
- if (thishop) {
-+ thishop->lr = (strnstr(rr, ";lr", len) != NULL ? 1 : 0);
- ast_copy_string(thishop->hop, rr, len);
- ast_log(LOG_DEBUG, "build_route: Record-Route hop: <%s>\n", thishop->hop);
- /* Link in */
-@@ -6040,31 +6042,41 @@ static void build_route(struct sip_pvt *
-
- /* Only append the contact if we are dealing with a strict router */
- if (!head || (!ast_strlen_zero(head->hop) && strstr(head->hop,";lr") == NULL) ) {
-- /* 2nd append the Contact: if there is one */
-- /* Can be multiple Contact headers, comma separated values - we just take the first */
-- contact = get_header(req, "Contact");
-- if (!ast_strlen_zero(contact)) {
-- ast_log(LOG_DEBUG, "build_route: Contact hop: %s\n", contact);
-- /* Look for <: delimited address */
-- c = strchr(contact, '<');
-- if (c) {
-- /* Take to > */
-- ++c;
-- len = strcspn(c, ">") + 1;
-- } else {
-- /* No <> - just take the lot */
-- c = contact;
-- len = strlen(contact) + 1;
-- }
-- thishop = malloc(sizeof(*thishop) + len);
-+ /* Duplicate first route from the list */
-+ if (head && head->lr) {
-+ thishop = (struct sip_route *)malloc(sizeof(struct sip_route)+strlen(head->hop)+1);
- if (thishop) {
-- ast_copy_string(thishop->hop, c, len);
-- thishop->next = NULL;
-- /* Goes at the end */
-- if (tail)
-- tail->next = thishop;
-- else
-- head = thishop;
-+ memcpy(thishop, head, sizeof(struct sip_route)+strlen(head->hop)+1);
-+ thishop->next = head;
-+ head = thishop;
-+ }
-+ } else {
-+ /* Append the Contact: if there is one and first route is w/o `lr' param */
-+ /* Can be multiple Contact headers, comma separated values - we just take the first */
-+ contact = get_header(req, "Contact");
-+ if (!ast_strlen_zero(contact)) {
-+ ast_log(LOG_DEBUG, "build_route: Contact hop: %s\n", contact);
-+ /* Look for <: delimited address */
-+ c = strchr(contact, '<');
-+ if (c) {
-+ /* Take to > */
-+ ++c;
-+ len = strcspn(c, ">") + 1;
-+ } else {
-+ /* No <> - just take the lot */
-+ c = contact;
-+ len = strlen(contact) + 1;
-+ }
-+ thishop = malloc(sizeof(*thishop) + len);
-+ if (thishop) {
-+ ast_copy_string(thishop->hop, c, len);
-+ thishop->next = NULL;
-+ /* Goes at the end */
-+ if (tail)
-+ tail->next = thishop;
-+ else
-+ head = thishop;
-+ }
- }
- }
- }
-@@ -10352,7 +10364,11 @@ static int handle_request_invite(struct
- gotdest = get_destination(p, NULL);
-
- get_rdnis(p, NULL);
-- extract_uri(p, req);
-+ build_route(p, req, 0);
-+ if (!p->route->lr)
-+ strncpy(p->uri, p->route->hop, sizeof(p->uri) - 1);
-+ else
-+ extract_uri(p, req);
- build_contact(p);
-
- if (gotdest) {
-@@ -10380,7 +10396,6 @@ static int handle_request_invite(struct
- c = sip_new(p, AST_STATE_DOWN, ast_strlen_zero(p->username) ? NULL : p->username );
- *recount = 1;
- /* Save Record-Route for any later requests we make on this dialogue */
-- build_route(p, req, 0);
- if (c) {
- /* Pre-lock the call */
- ast_mutex_lock(&c->lock);
-@@ -10466,7 +10481,12 @@ static int handle_request_invite(struct
- transmit_response(p, "180 Ringing", req);
- break;
- case AST_STATE_UP:
-- /* Here we have reINVITE request - try to renegotiate codecs with */
-+ /* Assuming this to be reinvite, process new SDP portion */
-+ if (!ast_strlen_zero(get_header(req, "Content-Type"))) {
-+ process_sdp(p, req);
-+ } else {
-+ ast_log(LOG_DEBUG, "Hm.... No sdp for the moment\n");
-+ }
- transmit_response_with_sdp(p, "200 OK", req, 1);
- break;
- default:
diff --git a/net/asterisk-devel/files/patch-channels::chan_zap.c b/net/asterisk-devel/files/patch-channels::chan_zap.c
deleted file mode 100644
index ab02c02..0000000
--- a/net/asterisk-devel/files/patch-channels::chan_zap.c
+++ /dev/null
@@ -1,80 +0,0 @@
-
-$FreeBSD$
-
---- channels/chan_zap.c.orig Tue Nov 29 20:24:39 2005
-+++ channels/chan_zap.c Fri Jan 13 13:28:33 2006
-@@ -638,6 +638,7 @@ static struct zt_pvt {
- int cidlen;
- int ringt;
- int ringt_base;
-+ int waitnorings;
- int stripmsd;
- int callwaitcas;
- int callwaitrings;
-@@ -2308,6 +2309,19 @@ static int zt_hangup(struct ast_channel
- }
-
- ast_mutex_lock(&p->lock);
-+ switch (p->sig) {
-+ case SIG_FXSGS:
-+ case SIG_FXSKS:
-+ case SIG_FXSLS:
-+ if((ast->_state == AST_STATE_RING) && (p->ringt > 1))
-+ {
-+ p->waitnorings = 1;
-+ }
-+ break;
-+ default:
-+ break;
-+ };
-+
-
- index = zt_get_index(ast, p, 1);
-
-@@ -6129,7 +6143,37 @@ static void *ss_thread(void *data)
- ast_setstate(chan, AST_STATE_RING);
- chan->rings = 1;
- p->ringt = p->ringt_base;
-+ p->waitnorings = 0;
- res = ast_pbx_run(chan);
-+
-+ if(p->waitnorings)
-+ {
-+ p->ringt = p->ringt_base;
-+ for(;;)
-+ {
-+ int i,j=0;
-+ i = ZT_IOMUX_SIGEVENT | ZT_IOMUX_NOWAIT;
-+ if (ioctl(p->subs[index].zfd, ZT_IOMUX, &i) == -1)
-+ break;
-+
-+ if (ioctl(p->subs[index].zfd, ZT_GETEVENT, &j) == -1)
-+ break;
-+
-+ if(j == ZT_EVENT_RINGOFFHOOK)
-+ p->ringt = p->ringt_base;
-+
-+ usleep(20000);
-+
-+ if (p->ringt <= 0)
-+ break;
-+
-+ else if (p->ringt > 0)
-+ p->ringt--;
-+ }
-+ p->ringt = 0;
-+ p->waitnorings = 0;
-+ }
-+
- if (res) {
- ast_hangup(chan);
- ast_log(LOG_WARNING, "PBX exited non-zero\n");
-@@ -6431,7 +6475,7 @@ static void *do_monitor(void *data)
- i = iflist;
- while(i) {
- if ((i->subs[SUB_REAL].zfd > -1) && i->sig && (!i->radio)) {
-- if (!i->owner && !i->subs[SUB_REAL].owner) {
-+ if (!i->owner && !i->subs[SUB_REAL].owner && !i->waitnorings) {
- /* This needs to be watched, as it lacks an owner */
- pfds[count].fd = i->subs[SUB_REAL].zfd;
- pfds[count].events = POLLPRI;
diff --git a/net/asterisk-devel/files/patch-channels::h323::ast_h323.cpp b/net/asterisk-devel/files/patch-channels::h323::ast_h323.cpp
deleted file mode 100644
index feb79e5..0000000
--- a/net/asterisk-devel/files/patch-channels::h323::ast_h323.cpp
+++ /dev/null
@@ -1,16 +0,0 @@
-
-$FreeBSD$
-
---- channels/h323/ast_h323.cpp.orig Thu Jan 12 18:16:08 2006
-+++ channels/h323/ast_h323.cpp Thu Jan 12 18:16:35 2006
-@@ -953,8 +953,8 @@ BOOL MyH323Connection::OnReceivedCapabil
- H323Channel * MyH323Connection::CreateRealTimeLogicalChannel(const H323Capability & capability,
- H323Channel::Directions dir,
- unsigned sessionID,
-- const H245_H2250LogicalChannelParameters * /*param*/,
-- RTP_QOS * /*param*/ )
-+ const H245_H2250LogicalChannelParameters * /*param*/ /*,
-+ RTP_QOS * */ /*param*/ )
- {
- return new MyH323_ExternalRTPChannel(*this, capability, dir, sessionID);
- }
diff --git a/net/asterisk-devel/files/patch-channels::h323::ast_h323.h b/net/asterisk-devel/files/patch-channels::h323::ast_h323.h
deleted file mode 100644
index 606bb01..0000000
--- a/net/asterisk-devel/files/patch-channels::h323::ast_h323.h
+++ /dev/null
@@ -1,16 +0,0 @@
-
-$FreeBSD$
-
---- channels/h323/ast_h323.h.orig Thu Jan 12 18:14:49 2006
-+++ channels/h323/ast_h323.h Thu Jan 12 18:15:02 2006
-@@ -155,8 +155,8 @@ class MyH323Connection : public H323Conn
- H323Channel * CreateRealTimeLogicalChannel(const H323Capability &,
- H323Channel::Directions,
- unsigned,
-- const H245_H2250LogicalChannelParameters *,
-- RTP_QOS *);
-+ const H245_H2250LogicalChannelParameters * /* ,
-+ RTP_QOS * */);
- H323Connection::AnswerCallResponse OnAnswerCall(const PString &,
- const H323SignalPDU &,
- H323SignalPDU &);
diff --git a/net/asterisk-devel/files/patch-codecs::Makefile b/net/asterisk-devel/files/patch-codecs::Makefile
deleted file mode 100644
index ab5cbc4..0000000
--- a/net/asterisk-devel/files/patch-codecs::Makefile
+++ /dev/null
@@ -1,53 +0,0 @@
-
-$FreeBSD$
-
---- codecs/Makefile.orig Tue Nov 29 20:24:39 2005
-+++ codecs/Makefile Fri Jan 13 10:33:21 2006
-@@ -30,8 +30,8 @@
-
- UI_SPEEX=$(wildcard $(CROSS_COMPILE_TARGET)/usr/include/speex.h)
- UIS_SPEEX=$(wildcard $(CROSS_COMPILE_TARGET)/usr/include/speex/speex.h)
--ULI_SPEEX=$(wildcard $(CROSS_COMPILE_TARGET)/usr/local/include/speex.h)
--ULIS_SPEEX=$(wildcard $(CROSS_COMPILE_TARGET)/usr/local/include/speex/speex.h)
-+ULI_SPEEX=$(wildcard $(CROSS_COMPILE_TARGET)$(LOCALBASE)/include/speex.h)
-+ULIS_SPEEX=$(wildcard $(CROSS_COMPILE_TARGET)$(LOCALBASE)/include/speex/speex.h)
- ifneq (${UI_SPEEX},)
- MODSPEEX=codec_speex.so
- LIBSPEEX+=-lspeex -lm
-@@ -43,14 +43,14 @@
- endif
- ifneq (${ULI_SPEEX},)
- MODSPEEX=codec_speex.so
-- CFLAGS+=-I$(CROSS_COMPILE_TARGET)/usr/local/include
-- LIBSPEEX=-L$(CROSS_COMPILE_TARGET)/usr/local/lib
-+ CFLAGS+=-I$(CROSS_COMPILE_TARGET)$(LOCALBASE)/include
-+ LIBSPEEX=-L$(CROSS_COMPILE_TARGET)$(LOCALBASE)/lib
- LIBSPEEX+=-lspeex -lm
- endif
- ifneq (${ULIS_SPEEX},)
- MODSPEEX=codec_speex.so
-- CFLAGS+=-I$(CROSS_COMPILE_TARGET)/usr/local/include/speex
-- LIBSPEEX=-L$(CROSS_COMPILE_TARGET)/usr/local/lib
-+ CFLAGS+=-I$(CROSS_COMPILE_TARGET)$(LOCALBASE)/include/speex
-+ LIBSPEEX=-L$(CROSS_COMPILE_TARGET)$(LOCALBASE)/lib
- LIBSPEEX+=-lspeex -lm
- endif
-
-@@ -65,7 +65,7 @@
- LIBLPC10=lpc10/liblpc10.a
-
- ifeq ($(findstring BSD,${OSARCH}),BSD)
-- CFLAGS+=-I$(CROSS_COMPILE_TARGET)/usr/local/include -L$(CROSS_COMPILE_TARGET)/usr/local/lib
-+ CFLAGS+=-I$(CROSS_COMPILE_TARGET)$(LOCALBASE)/include -L$(CROSS_COMPILE_TARGET)$(LOCALBASE)/lib
- endif
-
- CODECS+=$(MODG723) $(MODSPEEX) $(MODILBC) codec_gsm.so codec_lpc10.so \
-@@ -126,7 +126,7 @@
- endif
-
- install: all
-- for x in $(CODECS); do $(INSTALL) -m 755 $$x $(DESTDIR)$(MODULES_DIR) ; done
-+ for x in $(CODECS); do $(BSD_INSTALL_PROGRAM) $$x $(DESTDIR)$(MODULES_DIR) ; done
-
- depend: .depend
-
diff --git a/net/asterisk-devel/files/patch-codecs::gsm::Makefile b/net/asterisk-devel/files/patch-codecs::gsm::Makefile
deleted file mode 100644
index 7256eea..0000000
--- a/net/asterisk-devel/files/patch-codecs::gsm::Makefile
+++ /dev/null
@@ -1,16 +0,0 @@
-
-$FreeBSD$
-
---- codecs/gsm/Makefile.orig
-+++ codecs/gsm/Makefile
-@@ -49,7 +49,9 @@
- ifneq (${PROC},arm)
- ifneq (${PROC},ppc)
- ifneq (${PROC},ppc64)
--OPTIMIZE+=-march=$(PROC)
-+ifneq (${PROC},amd64)
-+#OPTIMIZE+=-march=$(PROC)
-+endif
- endif
- endif
- endif
diff --git a/net/asterisk-devel/files/patch-codecs::ilbc::Makefile b/net/asterisk-devel/files/patch-codecs::ilbc::Makefile
deleted file mode 100644
index 26a2f20..0000000
--- a/net/asterisk-devel/files/patch-codecs::ilbc::Makefile
+++ /dev/null
@@ -1,12 +0,0 @@
-
-$FreeBSD$
-
---- codecs/ilbc/Makefile.orig Fri Jan 13 11:01:07 2006
-+++ codecs/ilbc/Makefile Fri Jan 13 11:01:51 2006
-@@ -1,5 +1,5 @@
- ARCH=$(PROC)
--CFLAGS+=-Wall -O3 -funroll-loops
-+CFLAGS+=-Wall -funroll-loops
- ifneq (${OSARCH},CYGWIN)
- CFLAGS += -fPIC
- endif
diff --git a/net/asterisk-devel/files/patch-configs::musiconhold.conf.sample b/net/asterisk-devel/files/patch-configs::musiconhold.conf.sample
deleted file mode 100644
index ff63cc9..0000000
--- a/net/asterisk-devel/files/patch-configs::musiconhold.conf.sample
+++ /dev/null
@@ -1,14 +0,0 @@
-
-$FreeBSD$
-
---- configs/musiconhold.conf.sample.orig Tue Nov 29 20:24:39 2005
-+++ configs/musiconhold.conf.sample Fri Jan 13 11:38:39 2006
-@@ -4,7 +4,7 @@
-
- [default]
- mode=quietmp3
--directory=/var/lib/asterisk/mohmp3
-+directory=/usr/local/share/asterisk/mohmp3
-
- ; valid mode options:
- ; quietmp3 -- default
diff --git a/net/asterisk-devel/files/patch-db.c b/net/asterisk-devel/files/patch-db.c
deleted file mode 100644
index ba7f3f2..0000000
--- a/net/asterisk-devel/files/patch-db.c
+++ /dev/null
@@ -1,21 +0,0 @@
-
-$FreeBSD$
-
---- db.c.orig Fri Jan 13 11:05:32 2006
-+++ db.c Fri Jan 13 11:06:55 2006
-@@ -35,6 +35,7 @@
- #include <errno.h>
- #include <unistd.h>
- #include <dirent.h>
-+#include <db.h>
-
- #include "asterisk.h"
-
-@@ -51,7 +52,6 @@ ASTERISK_FILE_VERSION(__FILE__, "$Revisi
- #include "asterisk/utils.h"
- #include "asterisk/lock.h"
- #include "asterisk/manager.h"
--#include "db1-ast/include/db.h"
-
- #ifdef __CYGWIN__
- #define dbopen __dbopen
diff --git a/net/asterisk-devel/files/patch-editline::configure b/net/asterisk-devel/files/patch-editline::configure
deleted file mode 100644
index f6b9c5b..0000000
--- a/net/asterisk-devel/files/patch-editline::configure
+++ /dev/null
@@ -1,14 +0,0 @@
-
-$FreeBSD$
-
---- editline/configure.orig Sun Apr 27 21:13:11 2003
-+++ editline/configure Fri Jan 30 01:47:34 2004
-@@ -1906,7 +1906,7 @@
- CPPFLAGS="$CPPFLAGS -DDEBUG_TTY -DDEBUG_KEY -DDEBUG_READ -DDEBUG"
- CPPFLAGS="$CPPFLAGS -DDEBUG_REFRESH -DDEBUG_PASTE"
- else
-- CFLAGS="$CFLAGS -O"
-+ CFLAGS="$CFLAGS"
- fi
-
-
diff --git a/net/asterisk-devel/files/patch-editline::makelist b/net/asterisk-devel/files/patch-editline::makelist
deleted file mode 100644
index cff9b3a..0000000
--- a/net/asterisk-devel/files/patch-editline::makelist
+++ /dev/null
@@ -1,14 +0,0 @@
-
-$FreeBSD$
-
---- editline/makelist
-+++ editline/makelist
-@@ -145,7 +145,7 @@
- #
- -fh)
- cat $FILES | $AWK '/el_action_t/ { print $3 }' | \
-- sort | tr '[a-z]' '[A-Z]' | $AWK '
-+ sort | tr '[:lower:]' '[:upper:]' | $AWK '
- BEGIN {
- printf("/* Automatically generated file, do not edit */\n");
- printf("#ifndef _h_fcns_c\n#define _h_fcns_c\n");
diff --git a/net/asterisk-devel/files/patch-formats::Makefile b/net/asterisk-devel/files/patch-formats::Makefile
deleted file mode 100644
index b2b1db5..0000000
--- a/net/asterisk-devel/files/patch-formats::Makefile
+++ /dev/null
@@ -1,23 +0,0 @@
-
-$FreeBSD$
-
---- formats/Makefile.orig Fri Jan 13 11:16:07 2006
-+++ formats/Makefile Fri Jan 13 11:47:25 2006
-@@ -20,7 +20,7 @@
- #
- # G723 simple frame is deprecated
- #
--FORMAT_LIBS+=format_g723.so
-+FORMAT_LIBS+=format_g723_1.so
-
- #
- # OGG/Vorbis format
-@@ -60,7 +60,7 @@
- $(CC) $(SOLINK) -o $@ ${CYGSOLINK} $< ${CYGSOLIB} -logg -lvorbis -lvorbisenc -lm
-
- install: all
-- for x in $(FORMAT_LIBS); do $(INSTALL) -m 755 $$x $(DESTDIR)$(MODULES_DIR) ; done
-+ for x in $(FORMAT_LIBS); do $(BSD_INSTALL_PROGRAM) $$x $(DESTDIR)$(MODULES_DIR) ; done
-
- depend: .depend
-
diff --git a/net/asterisk-devel/files/patch-formats::format_g723_1.c b/net/asterisk-devel/files/patch-formats::format_g723_1.c
deleted file mode 100644
index ae814f1..0000000
--- a/net/asterisk-devel/files/patch-formats::format_g723_1.c
+++ /dev/null
@@ -1,354 +0,0 @@
-
-$FreeBSD$
-
---- /dev/null Fri Jan 13 12:18:51 2006
-+++ formats/format_g723_1.c Fri Jan 13 12:18:41 2006
-@@ -0,0 +1,348 @@
-+/*
-+ * Asterisk -- A telephony toolkit for Linux.
-+ *
-+ * Save and read raw, headerless G723.1 Annex A data.
-+ *
-+ * Copyright (C) 1999, Mark Spencer <markster@linux-support.net>
-+ * Copyright (C) 2003, Maxim Sobolev <sobomax@FreeBSD.org>
-+ *
-+ * This program is free software, distributed under the terms of
-+ * the GNU General Public License
-+ */
-+
-+#include <stdio.h>
-+#include <asterisk/lock.h>
-+#include <asterisk/channel.h>
-+#include <asterisk/file.h>
-+#include <asterisk/logger.h>
-+#include <asterisk/sched.h>
-+#include <asterisk/module.h>
-+#include <netinet/in.h>
-+#include <arpa/inet.h>
-+#include <stdlib.h>
-+#include <sys/time.h>
-+#include <unistd.h>
-+#include <errno.h>
-+#include <string.h>
-+#include <pthread.h>
-+#ifdef __linux__
-+#include <endian.h>
-+#else
-+#include <machine/endian.h>
-+#endif
-+
-+/* Based on format_g729.c */
-+
-+#define TYPE_HIGH 0x0
-+#define TYPE_LOW 0x1
-+#define TYPE_SILENCE 0x2
-+#define TYPE_DONTSEND 0x3
-+#define TYPE_MASK 0x3
-+
-+struct ast_filestream {
-+ void *reserved[AST_RESERVED_POINTERS];
-+ /* This is what a filestream means to us */
-+ FILE *f; /* Descriptor */
-+ struct ast_frame fr; /* Frame information */
-+ char waste[AST_FRIENDLY_OFFSET]; /* Buffer for sending frames, etc */
-+ char empty; /* Empty character */
-+ unsigned char g723[24]; /* One Real G723.1 Frame */
-+};
-+
-+static long g723_tell(struct ast_filestream *);
-+
-+AST_MUTEX_DEFINE_STATIC(g723_lock);
-+static int glistcnt = 0;
-+
-+static char *name = "g723";
-+static char *desc = "Raw G723.1 Annex A data";
-+static char *exts = "g723";
-+
-+static int g723_len(unsigned char buf)
-+{
-+ switch(buf & TYPE_MASK) {
-+ case TYPE_DONTSEND:
-+ return 2;
-+ break;
-+ case TYPE_SILENCE:
-+ return 4;
-+ break;
-+ case TYPE_HIGH:
-+ return 24;
-+ break;
-+ case TYPE_LOW:
-+ return 20;
-+ break;
-+ default:
-+ ast_log(LOG_WARNING, "Badly encoded G723.1 frame (%d)\n", buf & TYPE_MASK);
-+ }
-+ return -1;
-+}
-+
-+static struct ast_filestream *g723_open(FILE *f)
-+{
-+ /* We don't have any header to read or anything really, but
-+ if we did, it would go here. We also might want to check
-+ and be sure it's a valid file. */
-+ struct ast_filestream *tmp;
-+ if ((tmp = malloc(sizeof(struct ast_filestream)))) {
-+ memset(tmp, 0, sizeof(struct ast_filestream));
-+ if (ast_mutex_lock(&g723_lock)) {
-+ ast_log(LOG_WARNING, "Unable to lock g723 list\n");
-+ free(tmp);
-+ return NULL;
-+ }
-+ tmp->f = f;
-+ tmp->fr.data = tmp->g723;
-+ tmp->fr.frametype = AST_FRAME_VOICE;
-+ tmp->fr.subclass = AST_FORMAT_G723_1;
-+ /* datalen will vary for each frame */
-+ tmp->fr.src = name;
-+ tmp->fr.mallocd = 0;
-+ glistcnt++;
-+ ast_mutex_unlock(&g723_lock);
-+ ast_update_use_count();
-+ }
-+ return tmp;
-+}
-+
-+static struct ast_filestream *g723_rewrite(FILE *f, const char *comment)
-+{
-+ /* We don't have any header to read or anything really, but
-+ if we did, it would go here. We also might want to check
-+ and be sure it's a valid file. */
-+ struct ast_filestream *tmp;
-+ if ((tmp = malloc(sizeof(struct ast_filestream)))) {
-+ memset(tmp, 0, sizeof(struct ast_filestream));
-+ if (ast_mutex_lock(&g723_lock)) {
-+ ast_log(LOG_WARNING, "Unable to lock g723 list\n");
-+ free(tmp);
-+ return NULL;
-+ }
-+ tmp->f = f;
-+ glistcnt++;
-+ ast_mutex_unlock(&g723_lock);
-+ ast_update_use_count();
-+ } else
-+ ast_log(LOG_WARNING, "Out of memory\n");
-+ return tmp;
-+}
-+
-+static void g723_close(struct ast_filestream *s)
-+{
-+ if (ast_mutex_lock(&g723_lock)) {
-+ ast_log(LOG_WARNING, "Unable to lock g723 list\n");
-+ return;
-+ }
-+ glistcnt--;
-+ ast_mutex_unlock(&g723_lock);
-+ ast_update_use_count();
-+ fclose(s->f);
-+ free(s);
-+ s = NULL;
-+}
-+
-+static struct ast_frame *g723_read(struct ast_filestream *s, int *whennext)
-+{
-+ int res;
-+ /* Send a frame from the file to the appropriate channel */
-+ s->fr.frametype = AST_FRAME_VOICE;
-+ s->fr.subclass = AST_FORMAT_G723_1;
-+ s->fr.offset = AST_FRIENDLY_OFFSET;
-+ s->fr.samples = 240;
-+ s->fr.mallocd = 0;
-+ s->fr.data = s->g723;
-+ if ((res = fread(s->g723, 1, 1, s->f)) != 1) {
-+ if (res)
-+ ast_log(LOG_WARNING, "Short read (%d) (%s)!\n", res, strerror(errno));
-+ return NULL;
-+ }
-+ s->fr.datalen = g723_len(s->g723[0]);
-+ if (s->fr.datalen < 0) {
-+ ast_log(LOG_WARNING, "Invalid G723.1 frame!\n");
-+ return NULL;
-+ }
-+ if (s->fr.datalen > 1 && (res = fread(s->g723 + 1, 1, s->fr.datalen - 1, s->f)) != s->fr.datalen - 1) {
-+ if (res)
-+ ast_log(LOG_WARNING, "Short read (%d) (%s)!\n", res, strerror(errno));
-+ return NULL;
-+ }
-+ *whennext = s->fr.samples;
-+ return &s->fr;
-+}
-+
-+static int g723_write(struct ast_filestream *fs, struct ast_frame *f)
-+{
-+ int res;
-+ unsigned char *cp;
-+ if (f->frametype != AST_FRAME_VOICE) {
-+ ast_log(LOG_WARNING, "Asked to write non-voice frame!\n");
-+ return -1;
-+ }
-+ if (f->subclass != AST_FORMAT_G723_1) {
-+ ast_log(LOG_WARNING, "Asked to write non-G723.1 frame (%d)!\n", f->subclass);
-+ return -1;
-+ }
-+ for (cp = f->data; cp < (unsigned char *)f->data + f->datalen; cp += res) {
-+ res = g723_len(cp[0]);
-+ if (res < 0) {
-+ ast_log(LOG_WARNING, "Asked to write invalid G723.1 frame!\n");
-+ return -1;
-+ }
-+ }
-+ if (cp != (unsigned char *)f->data + f->datalen) {
-+ ast_log(LOG_WARNING, "Invalid G723.1 data length, %d\n", f->datalen);
-+ return -1;
-+ }
-+ if ((res = fwrite(f->data, 1, f->datalen, fs->f)) != f->datalen) {
-+ ast_log(LOG_WARNING, "Bad write %d: %s\n", res, strerror(errno));
-+ return -1;
-+ }
-+ return 0;
-+}
-+
-+static char *g723_getcomment(struct ast_filestream *s)
-+{
-+ return NULL;
-+}
-+
-+static int g723_seek(struct ast_filestream *fs, long sample_offset, int whence)
-+{
-+ long cur, offset, max;
-+ off_t coffset, moffset, soffset;
-+ int res;
-+ unsigned char c;
-+
-+ offset = 0; /* Shut up gcc warning */
-+ if (whence == SEEK_SET) {
-+ offset = sample_offset;
-+ } else if (whence == SEEK_CUR || whence == SEEK_FORCECUR) {
-+ if ((cur = g723_tell(fs)) == -1) {
-+ ast_log(LOG_WARNING, "Can't get current position!\n");
-+ return -1;
-+ }
-+ offset = cur + sample_offset;
-+ }
-+ if (fseeko(fs->f, 0, SEEK_END) == -1) {
-+ ast_log(LOG_WARNING, "Can't seek stream to an end!\n");
-+ return -1;
-+ }
-+ else {
-+ moffset = ftello(fs->f);
-+ }
-+ if (whence == SEEK_END) {
-+ if ((max = g723_tell(fs)) == -1) {
-+ ast_log(LOG_WARNING, "Can't get maximum position!\n");
-+ return -1;
-+ }
-+ offset = max - sample_offset;
-+ }
-+ if (offset < 0)
-+ offset = 0;
-+ soffset = -1;
-+ for (coffset = 0; coffset < moffset && offset > 0; coffset += res) {
-+ if (fseeko(fs->f, coffset, SEEK_SET) == -1) {
-+ ast_log(LOG_WARNING, "Can't seek to offset %lli!\n", coffset);
-+ return -1;
-+ }
-+ if (fread(&c, 1, 1, fs->f) != 1) {
-+ ast_log(LOG_WARNING, "Can't read from offset %lli!\n", coffset);
-+ return -1;
-+ }
-+ soffset = coffset;
-+ if ((res = g723_len(c)) < 0) {
-+ ast_log(LOG_WARNING, "Invalid G723.1 frame at offset %lli!\n", coffset);
-+ return -1;
-+ }
-+ if (res > 1)
-+ offset -= 240;
-+ }
-+ if (soffset != -1 && fseeko(fs->f, soffset, SEEK_SET) == -1) {
-+ ast_log(LOG_WARNING, "Can't seek to offset %lli!\n", soffset);
-+ return -1;
-+ }
-+
-+ return 0;
-+}
-+
-+static int g723_trunc(struct ast_filestream *fs)
-+{
-+ /* Truncate file to current length */
-+ if (ftruncate(fileno(fs->f), ftello(fs->f)) < 0)
-+ return -1;
-+ return 0;
-+}
-+
-+static long g723_tell(struct ast_filestream *fs)
-+{
-+ off_t offset, coffset;
-+ int res;
-+ long rval;
-+ unsigned char c;
-+
-+ offset = ftello(fs->f);
-+ rval = 0;
-+ for (coffset = 0; coffset < offset; coffset += res) {
-+ if (fseeko(fs->f, coffset, SEEK_SET) == -1) {
-+ ast_log(LOG_WARNING, "Can't seek to offset %llu!\n", coffset);
-+ return -1;
-+ }
-+ if (fread(&c, 1, 1, fs->f) != 1) {
-+ ast_log(LOG_WARNING, "Can't read from offset %llu!\n", coffset);
-+ return -1;
-+ }
-+ if ((res = g723_len(c)) < 0) {
-+ ast_log(LOG_WARNING, "Invalid G723.1 frame at offset %llu!\n", coffset);
-+ return -1;
-+ }
-+ if (res > 1)
-+ rval += 240;
-+ }
-+ if (fseeko(fs->f, offset, SEEK_SET) == -1) {
-+ ast_log(LOG_WARNING, "Can't seek to offset %llu!\n", offset);
-+ return -1;
-+ }
-+ return rval;
-+}
-+
-+int load_module()
-+{
-+ return ast_format_register(name, exts, AST_FORMAT_G723_1,
-+ g723_open,
-+ g723_rewrite,
-+ g723_write,
-+ g723_seek,
-+ g723_trunc,
-+ g723_tell,
-+ g723_read,
-+ g723_close,
-+ g723_getcomment);
-+}
-+
-+int unload_module()
-+{
-+ return ast_format_unregister(name);
-+}
-+
-+int usecount()
-+{
-+ int res;
-+ if (ast_mutex_lock(&g723_lock)) {
-+ ast_log(LOG_WARNING, "Unable to lock g723 list\n");
-+ return -1;
-+ }
-+ res = glistcnt;
-+ ast_mutex_unlock(&g723_lock);
-+ return res;
-+}
-+
-+char *description()
-+{
-+ return desc;
-+}
-+
-+
-+char *key()
-+{
-+ return ASTERISK_GPL_KEY;
-+}
diff --git a/net/asterisk-devel/files/patch-formats::format_g729.c b/net/asterisk-devel/files/patch-formats::format_g729.c
deleted file mode 100644
index 11be528..0000000
--- a/net/asterisk-devel/files/patch-formats::format_g729.c
+++ /dev/null
@@ -1,47 +0,0 @@
-
-$FreeBSD$
-
---- formats/format_g729.c.orig Fri Jan 13 12:20:53 2006
-+++ formats/format_g729.c Fri Jan 13 12:23:33 2006
-@@ -60,7 +60,7 @@ struct ast_filestream {
- struct ast_frame fr; /* Frame information */
- char waste[AST_FRIENDLY_OFFSET]; /* Buffer for sending frames, etc */
- char empty; /* Empty character */
-- unsigned char g729[20]; /* Two Real G729 Frames */
-+ unsigned char g729[10]; /* One Real G729 Frame */
- };
-
-
-@@ -141,11 +141,11 @@ static struct ast_frame *g729_read(struc
- s->fr.frametype = AST_FRAME_VOICE;
- s->fr.subclass = AST_FORMAT_G729A;
- s->fr.offset = AST_FRIENDLY_OFFSET;
-- s->fr.samples = 160;
-- s->fr.datalen = 20;
-+ s->fr.samples = 80;
-+ s->fr.datalen = 10;
- s->fr.mallocd = 0;
- s->fr.data = s->g729;
-- if ((res = fread(s->g729, 1, 20, s->f)) != 20) {
-+ if ((res = fread(s->g729, 1, 10, s->f)) != 10) {
- if (res && (res != 10))
- ast_log(LOG_WARNING, "Short read (%d) (%s)!\n", res, strerror(errno));
- return NULL;
-@@ -190,7 +190,7 @@ static int g729_seek(struct ast_filestre
- fseek(fs->f, 0, SEEK_END);
- max = ftell(fs->f);
-
-- bytes = 20 * (sample_offset / 160);
-+ bytes = 10 * (sample_offset / 80);
- if (whence == SEEK_SET)
- offset = bytes;
- else if (whence == SEEK_CUR || whence == SEEK_FORCECUR)
-@@ -219,7 +219,7 @@ static long g729_tell(struct ast_filestr
- {
- off_t offset;
- offset = ftell(fs->f);
-- return (offset/20)*160;
-+ return (offset/10)*80;
- }
-
- int load_module()
diff --git a/net/asterisk-devel/files/patch-frame.c b/net/asterisk-devel/files/patch-frame.c
deleted file mode 100644
index 753253c..0000000
--- a/net/asterisk-devel/files/patch-frame.c
+++ /dev/null
@@ -1,14 +0,0 @@
-
-$FreeBSD$
-
---- frame.c.orig Wed Jan 25 13:22:43 2006
-+++ frame.c Wed Jan 25 13:21:25 2006
-@@ -1170,7 +1170,7 @@ static int g723_len(unsigned char buf)
- {
- switch(buf & TYPE_MASK) {
- case TYPE_DONTSEND:
-- return 0;
-+ return 2;
- break;
- case TYPE_SILENCE:
- return 4;
diff --git a/net/asterisk-devel/files/patch-funcs::Makefile b/net/asterisk-devel/files/patch-funcs::Makefile
deleted file mode 100644
index a14daee..0000000
--- a/net/asterisk-devel/files/patch-funcs::Makefile
+++ /dev/null
@@ -1,14 +0,0 @@
-
-$FreeBSD$
-
---- funcs/Makefile.orig Tue Nov 29 20:24:39 2005
-+++ funcs/Makefile Fri Jan 13 12:36:57 2006
-@@ -67,7 +67,7 @@
- $(CC) $(SOLINK) -o $@ ${CYGSOLINK} $< ${CYGSOLIB}
-
- install: all
-- for x in $(FUNCS); do $(INSTALL) -m 755 $$x $(DESTDIR)$(MODULES_DIR) ; done
-+ for x in $(FUNCS); do $(BSD_INSTALL_PROGRAM) $$x $(DESTDIR)$(MODULES_DIR) ; done
-
- ifneq ($(wildcard .depend),)
- include .depend
diff --git a/net/asterisk-devel/files/patch-include::asterisk::utils.h b/net/asterisk-devel/files/patch-include::asterisk::utils.h
deleted file mode 100644
index a06f7d0..0000000
--- a/net/asterisk-devel/files/patch-include::asterisk::utils.h
+++ /dev/null
@@ -1,13 +0,0 @@
-
-$FreeBSD$
-
---- include/asterisk/utils.h 2004/10/10 12:55:50 1.1
-+++ include/asterisk/utils.h 2004/10/10 12:56:43
-@@ -37,7 +37,6 @@
- #ifdef inet_ntoa
- #undef inet_ntoa
- #endif
--#define inet_ntoa __dont__use__inet_ntoa__use__ast_inet_ntoa__instead__
-
- #ifdef LINUX
- #define ast_pthread_create pthread_create
diff --git a/net/asterisk-devel/files/patch-pbx::Makefile b/net/asterisk-devel/files/patch-pbx::Makefile
deleted file mode 100644
index 97d03e1..0000000
--- a/net/asterisk-devel/files/patch-pbx::Makefile
+++ /dev/null
@@ -1,25 +0,0 @@
-
-$FreeBSD$
-
---- pbx/Makefile.orig
-+++ pbx/Makefile
-@@ -23,8 +23,8 @@
- # Add KDE Console if appropriate
- #PBX_LIBS+=$(shell [ "$$QTDIR" != "" ] && echo "pbx_kdeconsole.so")
-
--GTK_FLAGS=`${CROSS_COMPILE_BIN}gtk-config --cflags gthread`
--GTK_LIBS=`${CROSS_COMPILE_BIN}gtk-config --libs gthread`
-+#GTK_FLAGS=`${CROSS_COMPILE_BIN}gtk-config --cflags gthread`
-+#GTK_LIBS=`${CROSS_COMPILE_BIN}gtk-config --libs gthread`
- MOC=$(QTDIR)/bin/moc
- KDE_FLAGS=-I$(KDEDIR)/include -I$(KDEDIR)/include/kde -I$(QTDIR)/include
- KDE_LIBS=-L$(KDEDIR)/lib -L$(QTDIR)/lib -lqt -lkdecore -lkdeui
-@@ -72,7 +72,7 @@
- endif
-
- install: all
-- for x in $(PBX_LIBS); do $(INSTALL) -m 755 $$x $(DESTDIR)$(MODULES_DIR) ; done
-+ for x in $(PBX_LIBS); do $(BSD_INSTALL_PROGRAM) $$x $(DESTDIR)$(MODULES_DIR) ; done
-
- depend: .depend
-
diff --git a/net/asterisk-devel/files/patch-res::Makefile b/net/asterisk-devel/files/patch-res::Makefile
deleted file mode 100644
index de5c365..0000000
--- a/net/asterisk-devel/files/patch-res::Makefile
+++ /dev/null
@@ -1,35 +0,0 @@
-
-$FreeBSD$
-
---- res/Makefile
-+++ res/Makefile
-@@ -37,8 +37,8 @@
- endif
-
- ifeq ($(findstring BSD,${OSARCH}),BSD)
-- CFLAGS+=-I$(CROSS_COMPILE_TARGET)/usr/local/include
-- SOLINK+=-L$(CROSS_COMPILE_TARGET)/usr/local/lib
-+ CFLAGS+=-I$(CROSS_COMPILE_TARGET)$(LOCALBASE)/include
-+ SOLINK+=-L$(CROSS_COMPILE_TARGET)$(LOCALBASE)/lib
- endif
-
- ifeq (${OSARCH},CYGWIN)
-@@ -55,9 +55,7 @@
- CFLAGS+=
-
- ifndef WITHOUT_ZAPTEL
--ifneq ($(wildcard $(CROSS_COMPILE_TARGET)/usr/include/linux/zaptel.h)$(wildcard $(CROSS_COMPILE_TARGET)/usr/local/include/zaptel.h),)
- CFLAGS+=-DZAPATA_MOH
--endif
- endif # WITHOUT_ZAPTEL
-
- #
-@@ -75,7 +73,7 @@
- rm -f $(DESTDIR)$(ASTHEADERDIR)/parking.h
- rm -f $(DESTDIR)$(MODULES_DIR)/app_agi.so
- rm -f $(DESTDIR)$(MODULES_DIR)/res_parking.so
-- for x in $(MODS); do $(INSTALL) -m 755 $$x $(DESTDIR)$(MODULES_DIR) ; done
-+ for x in $(MODS); do $(BSD_INSTALL_PROGRAM) $$x $(DESTDIR)$(MODULES_DIR) ; done
- @if [ x`which mpg123 2>/dev/null | grep -v '^no'` != x ] ; then \
- if mpg123 --longhelp 2>&1 | grep -q .59r 2>&1 >/dev/null ; then echo ; else \
- echo "*************************************************************";\
diff --git a/net/asterisk-devel/files/patch-rtp.c b/net/asterisk-devel/files/patch-rtp.c
deleted file mode 100644
index bbc2649..0000000
--- a/net/asterisk-devel/files/patch-rtp.c
+++ /dev/null
@@ -1,17 +0,0 @@
-
-$FreeBSD$
-
---- rtp.c.orig Fri Jan 13 13:38:01 2006
-+++ rtp.c Fri Jan 13 13:40:50 2006
-@@ -950,8 +950,10 @@ struct ast_rtp *ast_rtp_new_with_bindadd
- rtp->us.sin_port = htons(x);
- rtp->us.sin_addr = addr;
- /* If there's rtcp, initialize it as well. */
-- if (rtp->rtcp)
-+ if (rtp->rtcp) {
- rtp->rtcp->us.sin_port = htons(x + 1);
-+ rtp->rtcp->us.sin_addr = addr;
-+ }
- /* Try to bind it/them. */
- if (!(first = bind(rtp->s, (struct sockaddr *)&rtp->us, sizeof(rtp->us))) &&
- (!rtp->rtcp || !bind(rtp->rtcp->s, (struct sockaddr *)&rtp->rtcp->us, sizeof(rtp->rtcp->us))))
diff --git a/net/asterisk-devel/files/patch-utils::Makefile b/net/asterisk-devel/files/patch-utils::Makefile
deleted file mode 100644
index f3164c0..0000000
--- a/net/asterisk-devel/files/patch-utils::Makefile
+++ /dev/null
@@ -1,34 +0,0 @@
-
-$FreeBSD$
-
---- utils/Makefile
-+++ utils/Makefile
-@@ -17,16 +17,16 @@
- CFLAGS+=-DNO_AST_MM
-
- ifeq ($(findstring BSD,${OSARCH}),BSD)
-- CFLAGS+=-I$(CROSS_COMPILE_TARGET)/usr/local/include -L$(CROSS_COMPILE_TARGET)/usr/local/lib
-+ CFLAGS+=-I$(CROSS_COMPILE_TARGET)$(LOCALBASE)/include -L$(CROSS_COMPILE_TARGET)$(LOCALBASE)/lib
- endif
-
- TARGET=stereorize streamplayer
-
--ifneq ($(wildcard $(CROSS_COMPILE_TARGET)/usr/include/popt.h)$(wildcard -f $(CROSS_COMPILE_TARGET)/usr/local/include/popt.h),)
-+ifneq ($(wildcard $(CROSS_COMPILE_TARGET)/usr/include/popt.h)$(wildcard -f $(CROSS_COMPILE_TARGET)$(LOCALBASE)/include/popt.h),)
- TARGET+=smsq
- endif
-
--ifneq ($(wildcard $(CROSS_COMPILE_TARGET)/usr/include/newt.h)$(wildcard -f $(CROSS_COMPILE_TARGET)/usr/local/include/newt.h),)
-+ifneq ($(wildcard $(CROSS_COMPILE_TARGET)/usr/include/newt.h)$(wildcard -f $(CROSS_COMPILE_TARGET)$(LOCALBASE)/include/newt.h),)
- TARGET+=astman
- endif
-
-@@ -40,7 +40,7 @@
- install:
- for x in $(TARGET); do \
- if [ "$$x" != "none" ]; then \
-- $(INSTALL) -m 755 $$x $(DESTDIR)$(ASTSBINDIR)/$$x; \
-+ $(BSD_INSTALL_PROGRAM) $$x $(DESTDIR)$(ASTSBINDIR)/$$x; \
- fi; \
- done
-
diff --git a/net/asterisk-devel/pkg-descr b/net/asterisk-devel/pkg-descr
index 28b7a1d..024be35 100644
--- a/net/asterisk-devel/pkg-descr
+++ b/net/asterisk-devel/pkg-descr
@@ -1,5 +1,7 @@
-Asterisk is an Open Source PBX and telephony toolkit. It is, in a
-sense, middleware between Internet and telephony channels on the bottom,
-and Internet and telephony applications at the top.
+This port is for the head branch of Asterisk, an open source PBX.
+It is meant as a convenience to developers who want to test the
+FreeBSD compliance of the main development branch and to support
+FreeBSD-specific patches that may not find room in the original
+distribution.
WWW: http://www.asteriskpbx.com
diff --git a/net/asterisk-devel/pkg-plist b/net/asterisk-devel/pkg-plist
deleted file mode 100644
index 702370a..0000000
--- a/net/asterisk-devel/pkg-plist
+++ /dev/null
@@ -1,755 +0,0 @@
-@unexec if cmp -s %D/etc/asterisk/adsi.conf %D/etc/asterisk/adsi.conf-dist; then rm -f %D/etc/asterisk/adsi.conf; fi
-etc/asterisk/adsi.conf-dist
-@exec [ -f %B/adsi.conf ] || cp %B/%f %B/adsi.conf
-@unexec if cmp -s %D/etc/asterisk/adtranvofr.conf %D/etc/asterisk/adtranvofr.conf-dist; then rm -f %D/etc/asterisk/adtranvofr.conf; fi
-etc/asterisk/adtranvofr.conf-dist
-@exec [ -f %B/adtranvofr.conf ] || cp %B/%f %B/adtranvofr.conf
-@unexec if cmp -s %D/etc/asterisk/agents.conf %D/etc/asterisk/agents.conf-dist; then rm -f %D/etc/asterisk/agents.conf; fi
-etc/asterisk/agents.conf-dist
-@exec [ -f %B/agents.conf ] || cp %B/%f %B/agents.conf
-@unexec if cmp -s %D/etc/asterisk/alarmreceiver.conf %D/etc/asterisk/alarmreceiver.conf-dist; then rm -f %D/etc/asterisk/alarmreceiver.conf; fi
-etc/asterisk/alarmreceiver.conf-dist
-@exec [ -f %B/alarmreceiver.conf ] || cp %B/%f %B/alarmreceiver.conf
-@unexec if cmp -s %D/etc/asterisk/alsa.conf %D/etc/asterisk/alsa.conf-dist; then rm -f %D/etc/asterisk/alsa.conf; fi
-etc/asterisk/alsa.conf-dist
-@exec [ -f %B/alsa.conf ] || cp %B/%f %B/alsa.conf
-@unexec if cmp -s %D/etc/asterisk/asterisk.adsi %D/etc/asterisk/asterisk.adsi-dist; then rm -f %D/etc/asterisk/asterisk.adsi; fi
-etc/asterisk/asterisk.adsi-dist
-@exec [ -f %B/asterisk.adsi ] || cp %B/%f %B/asterisk.adsi
-@unexec if cmp -s %D/etc/asterisk/asterisk.conf %D/etc/asterisk/asterisk.conf-dist; then rm -f %D/etc/asterisk/asterisk.conf; fi
-etc/asterisk/asterisk.conf-dist
-@exec [ -f %B/asterisk.conf ] || cp %B/%f %B/asterisk.conf
-@unexec if cmp -s %D/etc/asterisk/cdr.conf %D/etc/asterisk/cdr.conf-dist; then rm -f %D/etc/asterisk/cdr.conf; fi
-etc/asterisk/cdr.conf-dist
-@exec [ -f %B/cdr.conf ] || cp %B/%f %B/cdr.conf
-@unexec if cmp -s %D/etc/asterisk/cdr_custom.conf %D/etc/asterisk/cdr_custom.conf-dist; then rm -f %D/etc/asterisk/cdr_custom.conf; fi
-etc/asterisk/cdr_custom.conf-dist
-@exec [ -f %B/cdr_custom.conf ] || cp %B/%f %B/cdr_custom.conf
-@unexec if cmp -s %D/etc/asterisk/cdr_manager.conf %D/etc/asterisk/cdr_manager.conf-dist; then rm -f %D/etc/asterisk/cdr_manager.conf; fi
-etc/asterisk/cdr_manager.conf-dist
-@exec [ -f %B/cdr_manager.conf ] || cp %B/%f %B/cdr_manager.conf
-@unexec if cmp -s %D/etc/asterisk/cdr_odbc.conf %D/etc/asterisk/cdr_odbc.conf-dist; then rm -f %D/etc/asterisk/cdr_odbc.conf; fi
-etc/asterisk/cdr_odbc.conf-dist
-@exec [ -f %B/cdr_odbc.conf ] || cp %B/%f %B/cdr_odbc.conf
-@unexec if cmp -s %D/etc/asterisk/cdr_pgsql.conf %D/etc/asterisk/cdr_pgsql.conf-dist; then rm -f %D/etc/asterisk/cdr_pgsql.conf; fi
-etc/asterisk/cdr_pgsql.conf-dist
-@exec [ -f %B/cdr_pgsql.conf ] || cp %B/%f %B/cdr_pgsql.conf
-@unexec if cmp -s %D/etc/asterisk/cdr_tds.conf %D/etc/asterisk/cdr_tds.conf-dist; then rm -f %D/etc/asterisk/cdr_tds.conf; fi
-etc/asterisk/cdr_tds.conf-dist
-@exec [ -f %B/cdr_tds.conf ] || cp %B/%f %B/cdr_tds.conf
-@unexec if cmp -s %D/etc/asterisk/codecs.conf %D/etc/asterisk/codecs.conf-dist; then rm -f %D/etc/asterisk/codecs.conf; fi
-etc/asterisk/codecs.conf-dist
-@exec [ -f %B/codecs.conf ] || cp %B/%f %B/codecs.conf
-@unexec if cmp -s %D/etc/asterisk/dnsmgr.conf %D/etc/asterisk/dnsmgr.conf-dist; then rm -f %D/etc/asterisk/dnsmgr.conf; fi
-etc/asterisk/dnsmgr.conf-dist
-@exec [ -f %B/dnsmgr.conf ] || cp %B/%f %B/dmsmgr.conf
-@unexec if cmp -s %D/etc/asterisk/dundi.conf %D/etc/asterisk/dundi.conf-dist; then rm -f %D/etc/asterisk/dundi.conf; fi
-etc/asterisk/dundi.conf-dist
-@exec [ -f %B/dundi.conf ] || cp %B/%f %B/dundi.conf
-@unexec if cmp -s %D/etc/asterisk/enum.conf %D/etc/asterisk/enum.conf-dist; then rm -f %D/etc/asterisk/enum.conf; fi
-etc/asterisk/enum.conf-dist
-@exec [ -f %B/enum.conf ] || cp %B/%f %B/enum.conf
-@unexec if cmp -s %D/etc/asterisk/extensions.ael %D/etc/asterisk/extensions.ael-dist; then rm -f %D/etc/asterisk/extensions.ael; fi
-etc/asterisk/extensions.ael-dist
-@exec [ -f %B/extensions.ael ] || cp %B/%f %B/extensions.ael
-@unexec if cmp -s %D/etc/asterisk/extconfig.conf %D/etc/asterisk/extconfig.conf-dist; then rm -f %D/etc/asterisk/extconfig.conf; fi
-etc/asterisk/extconfig.conf-dist
-@exec [ -f %B/extconfig.conf ] || cp %B/%f %B/extconfig.conf
-@unexec if cmp -s %D/etc/asterisk/extensions.conf %D/etc/asterisk/extensions.conf-dist; then rm -f %D/etc/asterisk/extensions.conf; fi
-etc/asterisk/extensions.conf-dist
-@exec [ -f %B/extensions.conf ] || cp %B/%f %B/extensions.conf
-@unexec if cmp -s %D/etc/asterisk/features.conf %D/etc/asterisk/features.conf-dist; then rm -f %D/etc/asterisk/features.conf; fi
-etc/asterisk/features.conf-dist
-@exec [ -f %B/features.conf ] || cp %B/%f %B/features.conf
-@unexec if cmp -s %D/etc/asterisk/festival.conf %D/etc/asterisk/festival.conf-dist; then rm -f %D/etc/asterisk/festival.conf; fi
-etc/asterisk/festival.conf-dist
-@exec [ -f %B/festival.conf ] || cp %B/%f %B/festival.conf
-@unexec if cmp -s %D/etc/asterisk/iax.conf %D/etc/asterisk/iax.conf-dist; then rm -f %D/etc/asterisk/iax.conf; fi
-etc/asterisk/iax.conf-dist
-@exec [ -f %B/iax.conf ] || cp %B/%f %B/iax.conf
-@unexec if cmp -s %D/etc/asterisk/iaxprov.conf %D/etc/asterisk/iaxprov.conf-dist; then rm -f %D/etc/asterisk/iaxprov.conf; fi
-etc/asterisk/iaxprov.conf-dist
-@exec [ -f %B/iaxprov.conf ] || cp %B/%f %B/iaxprov.conf
-@unexec if cmp -s %D/etc/asterisk/indications.conf %D/etc/asterisk/indications.conf-dist; then rm -f %D/etc/asterisk/indications.conf; fi
-etc/asterisk/indications.conf-dist
-@exec [ -f %B/indications.conf ] || cp %B/%f %B/indications.conf
-@unexec if cmp -s %D/etc/asterisk/logger.conf %D/etc/asterisk/logger.conf-dist; then rm -f %D/etc/asterisk/logger.conf; fi
-etc/asterisk/logger.conf-dist
-@exec [ -f %B/logger.conf ] || cp %B/%f %B/logger.conf
-@unexec if cmp -s %D/etc/asterisk/manager.conf %D/etc/asterisk/manager.conf-dist; then rm -f %D/etc/asterisk/manager.conf; fi
-etc/asterisk/manager.conf-dist
-@exec [ -f %B/manager.conf ] || cp %B/%f %B/manager.conf
-@unexec if cmp -s %D/etc/asterisk/meetme.conf %D/etc/asterisk/meetme.conf-dist; then rm -f %D/etc/asterisk/meetme.conf; fi
-etc/asterisk/meetme.conf-dist
-@exec [ -f %B/meetme.conf ] || cp %B/%f %B/meetme.conf
-@unexec if cmp -s %D/etc/asterisk/mgcp.conf %D/etc/asterisk/mgcp.conf-dist; then rm -f %D/etc/asterisk/mgcp.conf; fi
-etc/asterisk/mgcp.conf-dist
-@exec [ -f %B/mgcp.conf ] || cp %B/%f %B/mgcp.conf
-@unexec if cmp -s %D/etc/asterisk/misdn.conf %D/etc/asterisk/misdn.conf-dist; then rm -f %D/etc/asterisk/misdn.conf; fi
-etc/asterisk/misdn.conf-dist
-@exec [ -f %B/misdn.conf ] || cp %B/%f %B/misdn.conf
-@unexec if cmp -s %D/etc/asterisk/modem.conf %D/etc/asterisk/modem.conf-dist; then rm -f %D/etc/asterisk/modem.conf; fi
-etc/asterisk/modem.conf-dist
-@exec [ -f %B/modem.conf ] || cp %B/%f %B/modem.conf
-@unexec if cmp -s %D/etc/asterisk/modules.conf %D/etc/asterisk/modules.conf-dist; then rm -f %D/etc/asterisk/modules.conf; fi
-etc/asterisk/modules.conf-dist
-@exec [ -f %B/modules.conf ] || cp %B/%f %B/modules.conf
-@unexec if cmp -s %D/etc/asterisk/musiconhold.conf %D/etc/asterisk/musiconhold.conf-dist; then rm -f %D/etc/asterisk/musiconhold.conf; fi
-etc/asterisk/musiconhold.conf-dist
-@exec [ -f %B/musiconhold.conf ] || cp %B/%f %B/musiconhold.conf
-@unexec if cmp -s %D/etc/asterisk/osp.conf %D/etc/asterisk/osp.conf-dist; then rm -f %D/etc/asterisk/osp.conf; fi
-etc/asterisk/osp.conf-dist
-@exec [ -f %B/osp.conf ] || cp %B/%f %B/osp.conf
-@unexec if cmp -s %D/etc/asterisk/oss.conf %D/etc/asterisk/oss.conf-dist; then rm -f %D/etc/asterisk/oss.conf; fi
-etc/asterisk/oss.conf-dist
-@exec [ -f %B/oss.conf ] || cp %B/%f %B/oss.conf
-@unexec if cmp -s %D/etc/asterisk/phone.conf %D/etc/asterisk/phone.conf-dist; then rm -f %D/etc/asterisk/phone.conf; fi
-etc/asterisk/phone.conf-dist
-@exec [ -f %B/phone.conf ] || cp %B/%f %B/phone.conf
-@unexec if cmp -s %D/etc/asterisk/privacy.conf %D/etc/asterisk/privacy.conf-dist; then rm -f %D/etc/asterisk/privacy.conf; fi
-etc/asterisk/privacy.conf-dist
-@exec [ -f %B/privacy.conf ] || cp %B/%f %B/privacy.conf
-@unexec if cmp -s %D/etc/asterisk/queues.conf %D/etc/asterisk/queues.conf-dist; then rm -f %D/etc/asterisk/queues.conf; fi
-etc/asterisk/queues.conf-dist
-@exec [ -f %B/queues.conf ] || cp %B/%f %B/queues.conf
-@unexec if cmp -s %D/etc/asterisk/res_odbc.conf %D/etc/asterisk/res_odbc.conf-dist; then rm -f %D/etc/asterisk/res_odbc.conf; fi
-etc/asterisk/res_odbc.conf-dist
-@exec [ -f %B/res_odbc.conf ] || cp %B/%f %B/res_odbc.conf
-@unexec if cmp -s %D/etc/asterisk/rpt.conf %D/etc/asterisk/rpt.conf-dist; then rm -f %D/etc/asterisk/rpt.conf; fi
-etc/asterisk/rpt.conf-dist
-@exec [ -f %B/rpt.conf ] || cp %B/%f %B/rpt.conf
-@unexec if cmp -s %D/etc/asterisk/rtp.conf %D/etc/asterisk/rtp.conf-dist; then rm -f %D/etc/asterisk/rtp.conf; fi
-etc/asterisk/rtp.conf-dist
-@exec [ -f %B/rtp.conf ] || cp %B/%f %B/rtp.conf
-@unexec if cmp -s %D/etc/asterisk/sip.conf %D/etc/asterisk/sip.conf-dist; then rm -f %D/etc/asterisk/sip.conf; fi
-etc/asterisk/sip.conf-dist
-@exec [ -f %B/sip.conf ] || cp %B/%f %B/sip.conf
-@unexec if cmp -s %D/etc/asterisk/sip_notify.conf %D/etc/asterisk/sip_notify.conf-dist; then rm -f %D/etc/asterisk/sip_notify.conf; fi
-etc/asterisk/sip_notify.conf-dist
-@exec [ -f %B/sip_notify.conf ] || cp %B/%f %B/sip_notify.conf
-@unexec if cmp -s %D/etc/asterisk/skinny.conf %D/etc/asterisk/skinny.conf-dist; then rm -f %D/etc/asterisk/skinny.conf; fi
-etc/asterisk/skinny.conf-dist
-@exec [ -f %B/skinny.conf ] || cp %B/%f %B/skinny.conf
-@unexec if cmp -s %D/etc/asterisk/telcordia-1.adsi %D/etc/asterisk/telcordia-1.adsi-dist; then rm -f %D/etc/asterisk/telcordia-1.adsi; fi
-etc/asterisk/telcordia-1.adsi-dist
-@exec [ -f %B/telcordia-1.adsi ] || cp %B/%f %B/telcordia-1.adsi
-@unexec if cmp -s %D/etc/asterisk/voicemail.conf %D/etc/asterisk/voicemail.conf-dist; then rm -f %D/etc/asterisk/voicemail.conf; fi
-etc/asterisk/voicemail.conf-dist
-@exec [ -f %B/voicemail.conf ] || cp %B/%f %B/voicemail.conf
-@unexec if cmp -s %D/etc/asterisk/vpb.conf %D/etc/asterisk/vpb.conf-dist; then rm -f %D/etc/asterisk/vpb.conf; fi
-etc/asterisk/vpb.conf-dist
-@exec [ -f %B/vpb.conf ] || cp %B/%f %B/vpb.conf
-@unexec if cmp -s %D/etc/asterisk/zapata.conf %D/etc/asterisk/zapata.conf-dist; then rm -f %D/etc/asterisk/zapata.conf; fi
-etc/asterisk/zapata.conf-dist
-@exec [ -f %B/zapata.conf ] || cp %B/%f %B/zapata.conf
-include/asterisk/acl.h
-include/asterisk/adsi.h
-include/asterisk/aes.h
-include/asterisk/agi.h
-include/asterisk/alaw.h
-include/asterisk/app.h
-include/asterisk/ast_expr.h
-include/asterisk/astdb.h
-include/asterisk/astmm.h
-include/asterisk/astobj.h
-include/asterisk/astosp.h
-include/asterisk/build.h
-include/asterisk/callerid.h
-include/asterisk/causes.h
-include/asterisk/cdr.h
-include/asterisk/channel.h
-include/asterisk/chanspy.h
-include/asterisk/chanvars.h
-include/asterisk/cli.h
-include/asterisk/compat.h
-include/asterisk/config.h
-include/asterisk/compiler.h
-include/asterisk/crypto.h
-include/asterisk/devicestate.h
-include/asterisk/dlfcn-compat.h
-include/asterisk/dns.h
-include/asterisk/dnsmgr.h
-include/asterisk/doxyref.h
-include/asterisk/dsp.h
-include/asterisk/dundi.h
-include/asterisk/enum.h
-include/asterisk/endian.h
-include/asterisk/features.h
-include/asterisk/file.h
-include/asterisk/frame.h
-include/asterisk/fskmodem.h
-include/asterisk/image.h
-include/asterisk/indications.h
-include/asterisk/inline_api.h
-include/asterisk/io.h
-include/asterisk/linkedlists.h
-include/asterisk/localtime.h
-include/asterisk/lock.h
-include/asterisk/logger.h
-include/asterisk/manager.h
-include/asterisk/md5.h
-include/asterisk/module.h
-include/asterisk/monitor.h
-include/asterisk/musiconhold.h
-include/asterisk/netsock.h
-include/asterisk/options.h
-include/asterisk/pbx.h
-include/asterisk/plc.h
-include/asterisk/poll-compat.h
-include/asterisk/privacy.h
-include/asterisk/res_odbc.h
-include/asterisk/rtp.h
-include/asterisk/say.h
-include/asterisk/sched.h
-include/asterisk/slinfactory.h
-include/asterisk/srv.h
-include/asterisk/strings.h
-include/asterisk/tdd.h
-include/asterisk/term.h
-include/asterisk/time.h
-include/asterisk/transcap.h
-include/asterisk/translate.h
-include/asterisk/ulaw.h
-include/asterisk/unaligned.h
-include/asterisk/utils.h
-include/asterisk/version.h
-include/asterisk/vmodem.h
-lib/asterisk/modules/app_adsiprog.so
-lib/asterisk/modules/app_alarmreceiver.so
-lib/asterisk/modules/app_authenticate.so
-lib/asterisk/modules/app_cdr.so
-lib/asterisk/modules/app_chanisavail.so
-lib/asterisk/modules/app_chanspy.so
-lib/asterisk/modules/app_controlplayback.so
-lib/asterisk/modules/app_curl.so
-lib/asterisk/modules/app_cut.so
-lib/asterisk/modules/app_db.so
-lib/asterisk/modules/app_dial.so
-lib/asterisk/modules/app_dictate.so
-lib/asterisk/modules/app_directed_pickup.so
-lib/asterisk/modules/app_directory.so
-lib/asterisk/modules/app_disa.so
-lib/asterisk/modules/app_dumpchan.so
-lib/asterisk/modules/app_echo.so
-lib/asterisk/modules/app_enumlookup.so
-lib/asterisk/modules/app_eval.so
-lib/asterisk/modules/app_exec.so
-lib/asterisk/modules/app_externalivr.so
-lib/asterisk/modules/app_festival.so
-%%WITH_ZAPTEL%%lib/asterisk/modules/app_flash.so
-lib/asterisk/modules/app_forkcdr.so
-lib/asterisk/modules/app_getcpeid.so
-lib/asterisk/modules/app_groupcount.so
-lib/asterisk/modules/app_hasnewvoicemail.so
-lib/asterisk/modules/app_ices.so
-lib/asterisk/modules/app_image.so
-lib/asterisk/modules/app_lookupblacklist.so
-lib/asterisk/modules/app_lookupcidname.so
-lib/asterisk/modules/app_macro.so
-lib/asterisk/modules/app_math.so
-lib/asterisk/modules/app_md5.so
-%%WITH_ZAPTEL%%lib/asterisk/modules/app_meetme.so
-lib/asterisk/modules/app_milliwatt.so
-lib/asterisk/modules/app_mixmonitor.so
-lib/asterisk/modules/app_mp3.so
-lib/asterisk/modules/app_nbscat.so
-%%WITH_ZAPTEL%%lib/asterisk/modules/app_page.so
-lib/asterisk/modules/app_parkandannounce.so
-lib/asterisk/modules/app_playback.so
-lib/asterisk/modules/app_privacy.so
-lib/asterisk/modules/app_queue.so
-lib/asterisk/modules/app_random.so
-lib/asterisk/modules/app_read.so
-lib/asterisk/modules/app_readfile.so
-lib/asterisk/modules/app_realtime.so
-lib/asterisk/modules/app_record.so
-%%WITH_FAX%%lib/asterisk/modules/app_rxfax.so
-lib/asterisk/modules/app_sayunixtime.so
-lib/asterisk/modules/app_senddtmf.so
-lib/asterisk/modules/app_sendtext.so
-lib/asterisk/modules/app_setcallerid.so
-lib/asterisk/modules/app_setcdruserfield.so
-lib/asterisk/modules/app_setcidname.so
-lib/asterisk/modules/app_setcidnum.so
-lib/asterisk/modules/app_setrdnis.so
-lib/asterisk/modules/app_settransfercapability.so
-lib/asterisk/modules/app_sms.so
-lib/asterisk/modules/app_softhangup.so
-lib/asterisk/modules/app_stack.so
-lib/asterisk/modules/app_system.so
-lib/asterisk/modules/app_talkdetect.so
-lib/asterisk/modules/app_test.so
-lib/asterisk/modules/app_transfer.so
-%%WITH_FAX%%lib/asterisk/modules/app_txfax.so
-lib/asterisk/modules/app_txtcidname.so
-lib/asterisk/modules/app_url.so
-lib/asterisk/modules/app_userevent.so
-lib/asterisk/modules/app_verbose.so
-lib/asterisk/modules/app_voicemail.so
-lib/asterisk/modules/app_waitforring.so
-lib/asterisk/modules/app_waitforsilence.so
-lib/asterisk/modules/app_while.so
-lib/asterisk/modules/app_zapateller.so
-%%WITH_ZAPTEL%%lib/asterisk/modules/app_zapbarge.so
-%%WITH_ZAPTEL%%lib/asterisk/modules/app_zapras.so
-%%WITH_ZAPTEL%%lib/asterisk/modules/app_zapscan.so
-lib/asterisk/modules/cdr_csv.so
-lib/asterisk/modules/cdr_custom.so
-lib/asterisk/modules/cdr_manager.so
-%%WITH_ODBC%%lib/asterisk/modules/cdr_odbc.so
-lib/asterisk/modules/chan_agent.so
-lib/asterisk/modules/chan_features.so
-%%WITH_H323%%lib/asterisk/modules/chan_h323.so
-lib/asterisk/modules/chan_iax2.so
-lib/asterisk/modules/chan_local.so
-lib/asterisk/modules/chan_mgcp.so
-lib/asterisk/modules/chan_oss.so
-lib/asterisk/modules/chan_sip.so
-lib/asterisk/modules/chan_skinny.so
-%%WITH_ZAPTEL%%lib/asterisk/modules/chan_zap.so
-lib/asterisk/modules/codec_a_mu.so
-lib/asterisk/modules/codec_adpcm.so
-lib/asterisk/modules/codec_alaw.so
-lib/asterisk/modules/codec_g726.so
-lib/asterisk/modules/codec_gsm.so
-lib/asterisk/modules/codec_ilbc.so
-lib/asterisk/modules/codec_lpc10.so
-lib/asterisk/modules/codec_speex.so
-lib/asterisk/modules/codec_ulaw.so
-lib/asterisk/modules/format_au.so
-lib/asterisk/modules/format_g723_1.so
-lib/asterisk/modules/format_g726.so
-lib/asterisk/modules/format_g729.so
-lib/asterisk/modules/format_gsm.so
-lib/asterisk/modules/format_h263.so
-lib/asterisk/modules/format_ilbc.so
-lib/asterisk/modules/format_jpeg.so
-lib/asterisk/modules/format_pcm.so
-lib/asterisk/modules/format_pcm_alaw.so
-lib/asterisk/modules/format_sln.so
-lib/asterisk/modules/format_vox.so
-lib/asterisk/modules/format_wav.so
-lib/asterisk/modules/format_wav_gsm.so
-lib/asterisk/modules/func_callerid.so
-lib/asterisk/modules/func_enum.so
-lib/asterisk/modules/func_uri.so
-lib/asterisk/modules/pbx_ael.so
-lib/asterisk/modules/pbx_config.so
-lib/asterisk/modules/pbx_dundi.so
-lib/asterisk/modules/pbx_functions.so
-lib/asterisk/modules/pbx_loopback.so
-lib/asterisk/modules/pbx_realtime.so
-lib/asterisk/modules/pbx_spool.so
-lib/asterisk/modules/res_adsi.so
-lib/asterisk/modules/res_agi.so
-lib/asterisk/modules/res_config_odbc.so
-lib/asterisk/modules/res_crypto.so
-lib/asterisk/modules/res_features.so
-lib/asterisk/modules/res_indications.so
-lib/asterisk/modules/res_monitor.so
-lib/asterisk/modules/res_odbc.so
-lib/asterisk/modules/res_musiconhold.so
-sbin/asterisk
-sbin/astgenkey
-sbin/astman
-sbin/autosupport
-sbin/rasterisk
-sbin/safe_asterisk
-sbin/smsq
-sbin/stereorize
-sbin/streamplayer
-%%DATADIR%%/agi-bin/agi-test.agi
-%%DATADIR%%/agi-bin/eagi-sphinx-test
-%%DATADIR%%/agi-bin/eagi-test
-%%DATADIR%%/firmware/iax/iaxy.bin
-%%DATADIR%%/images/asterisk-intro.jpg
-%%DATADIR%%/keys/freeworlddialup.pub
-%%DATADIR%%/keys/iaxtel.pub
-%%DATADIR%%/mohmp3/fpm-calm-river.mp3
-%%DATADIR%%/mohmp3/fpm-sunshine.mp3
-%%DATADIR%%/mohmp3/fpm-world-mix.mp3
-%%DATADIR%%/sounds/agent-alreadyon.gsm
-%%DATADIR%%/sounds/agent-incorrect.gsm
-%%DATADIR%%/sounds/agent-loggedoff.gsm
-%%DATADIR%%/sounds/agent-loginok.gsm
-%%DATADIR%%/sounds/agent-newlocation.gsm
-%%DATADIR%%/sounds/agent-pass.gsm
-%%DATADIR%%/sounds/agent-user.gsm
-%%DATADIR%%/sounds/auth-incorrect.gsm
-%%DATADIR%%/sounds/auth-thankyou.gsm
-%%DATADIR%%/sounds/beep.gsm
-%%DATADIR%%/sounds/beeperr.gsm
-%%DATADIR%%/sounds/conf-adminmenu.gsm
-%%DATADIR%%/sounds/conf-enteringno.gsm
-%%DATADIR%%/sounds/conf-errormenu.gsm
-%%DATADIR%%/sounds/conf-getchannel.gsm
-%%DATADIR%%/sounds/conf-getconfno.gsm
-%%DATADIR%%/sounds/conf-getpin.gsm
-%%DATADIR%%/sounds/conf-hasjoin.gsm
-%%DATADIR%%/sounds/conf-hasleft.gsm
-%%DATADIR%%/sounds/conf-invalid.gsm
-%%DATADIR%%/sounds/conf-invalidpin.gsm
-%%DATADIR%%/sounds/conf-kicked.gsm
-%%DATADIR%%/sounds/conf-leaderhasleft.gsm
-%%DATADIR%%/sounds/conf-locked.gsm
-%%DATADIR%%/sounds/conf-lockednow.gsm
-%%DATADIR%%/sounds/conf-muted.gsm
-%%DATADIR%%/sounds/conf-noempty.gsm
-%%DATADIR%%/sounds/conf-onlyone.gsm
-%%DATADIR%%/sounds/conf-onlyperson.gsm
-%%DATADIR%%/sounds/conf-otherinparty.gsm
-%%DATADIR%%/sounds/conf-placeintoconf.gsm
-%%DATADIR%%/sounds/conf-thereare.gsm
-%%DATADIR%%/sounds/conf-unlockednow.gsm
-%%DATADIR%%/sounds/conf-unmuted.gsm
-%%DATADIR%%/sounds/conf-usermenu.gsm
-%%DATADIR%%/sounds/conf-userswilljoin.gsm
-%%DATADIR%%/sounds/conf-userwilljoin.gsm
-%%DATADIR%%/sounds/conf-waitforleader.gsm
-%%DATADIR%%/sounds/demo-abouttotry.gsm
-%%DATADIR%%/sounds/demo-congrats.gsm
-%%DATADIR%%/sounds/demo-echodone.gsm
-%%DATADIR%%/sounds/demo-echotest.gsm
-%%DATADIR%%/sounds/demo-enterkeywords.gsm
-%%DATADIR%%/sounds/demo-instruct.gsm
-%%DATADIR%%/sounds/demo-moreinfo.gsm
-%%DATADIR%%/sounds/demo-nogo.gsm
-%%DATADIR%%/sounds/demo-nomatch.gsm
-%%DATADIR%%/sounds/demo-thanks.gsm
-%%DATADIR%%/sounds/dictate/both_help.gsm
-%%DATADIR%%/sounds/dictate/enter_filename.gsm
-%%DATADIR%%/sounds/dictate/forhelp.gsm
-%%DATADIR%%/sounds/dictate/pause.gsm
-%%DATADIR%%/sounds/dictate/paused.gsm
-%%DATADIR%%/sounds/dictate/play_help.gsm
-%%DATADIR%%/sounds/dictate/playback.gsm
-%%DATADIR%%/sounds/dictate/playback_mode.gsm
-%%DATADIR%%/sounds/dictate/record.gsm
-%%DATADIR%%/sounds/dictate/record_help.gsm
-%%DATADIR%%/sounds/dictate/record_mode.gsm
-%%DATADIR%%/sounds/dictate/truncating_audio.gsm
-%%DATADIR%%/sounds/digits/0.gsm
-%%DATADIR%%/sounds/digits/1.gsm
-%%DATADIR%%/sounds/digits/10.gsm
-%%DATADIR%%/sounds/digits/11.gsm
-%%DATADIR%%/sounds/digits/12.gsm
-%%DATADIR%%/sounds/digits/13.gsm
-%%DATADIR%%/sounds/digits/14.gsm
-%%DATADIR%%/sounds/digits/15.gsm
-%%DATADIR%%/sounds/digits/16.gsm
-%%DATADIR%%/sounds/digits/17.gsm
-%%DATADIR%%/sounds/digits/18.gsm
-%%DATADIR%%/sounds/digits/19.gsm
-%%DATADIR%%/sounds/digits/2.gsm
-%%DATADIR%%/sounds/digits/20.gsm
-%%DATADIR%%/sounds/digits/3.gsm
-%%DATADIR%%/sounds/digits/30.gsm
-%%DATADIR%%/sounds/digits/4.gsm
-%%DATADIR%%/sounds/digits/40.gsm
-%%DATADIR%%/sounds/digits/5.gsm
-%%DATADIR%%/sounds/digits/50.gsm
-%%DATADIR%%/sounds/digits/6.gsm
-%%DATADIR%%/sounds/digits/60.gsm
-%%DATADIR%%/sounds/digits/7.gsm
-%%DATADIR%%/sounds/digits/70.gsm
-%%DATADIR%%/sounds/digits/8.gsm
-%%DATADIR%%/sounds/digits/80.gsm
-%%DATADIR%%/sounds/digits/9.gsm
-%%DATADIR%%/sounds/digits/90.gsm
-%%DATADIR%%/sounds/digits/a-m.gsm
-%%DATADIR%%/sounds/digits/at.gsm
-%%DATADIR%%/sounds/digits/day-0.gsm
-%%DATADIR%%/sounds/digits/day-1.gsm
-%%DATADIR%%/sounds/digits/day-2.gsm
-%%DATADIR%%/sounds/digits/day-3.gsm
-%%DATADIR%%/sounds/digits/day-4.gsm
-%%DATADIR%%/sounds/digits/day-5.gsm
-%%DATADIR%%/sounds/digits/day-6.gsm
-%%DATADIR%%/sounds/digits/dollars.gsm
-%%DATADIR%%/sounds/digits/h-1.gsm
-%%DATADIR%%/sounds/digits/h-10.gsm
-%%DATADIR%%/sounds/digits/h-11.gsm
-%%DATADIR%%/sounds/digits/h-12.gsm
-%%DATADIR%%/sounds/digits/h-13.gsm
-%%DATADIR%%/sounds/digits/h-14.gsm
-%%DATADIR%%/sounds/digits/h-15.gsm
-%%DATADIR%%/sounds/digits/h-16.gsm
-%%DATADIR%%/sounds/digits/h-17.gsm
-%%DATADIR%%/sounds/digits/h-18.gsm
-%%DATADIR%%/sounds/digits/h-19.gsm
-%%DATADIR%%/sounds/digits/h-2.gsm
-%%DATADIR%%/sounds/digits/h-20.gsm
-%%DATADIR%%/sounds/digits/h-3.gsm
-%%DATADIR%%/sounds/digits/h-30.gsm
-%%DATADIR%%/sounds/digits/h-4.gsm
-%%DATADIR%%/sounds/digits/h-5.gsm
-%%DATADIR%%/sounds/digits/h-6.gsm
-%%DATADIR%%/sounds/digits/h-7.gsm
-%%DATADIR%%/sounds/digits/h-8.gsm
-%%DATADIR%%/sounds/digits/h-9.gsm
-%%DATADIR%%/sounds/digits/hundred.gsm
-%%DATADIR%%/sounds/digits/million.gsm
-%%DATADIR%%/sounds/digits/minus.gsm
-%%DATADIR%%/sounds/digits/mon-0.gsm
-%%DATADIR%%/sounds/digits/mon-1.gsm
-%%DATADIR%%/sounds/digits/mon-10.gsm
-%%DATADIR%%/sounds/digits/mon-11.gsm
-%%DATADIR%%/sounds/digits/mon-2.gsm
-%%DATADIR%%/sounds/digits/mon-3.gsm
-%%DATADIR%%/sounds/digits/mon-4.gsm
-%%DATADIR%%/sounds/digits/mon-5.gsm
-%%DATADIR%%/sounds/digits/mon-6.gsm
-%%DATADIR%%/sounds/digits/mon-7.gsm
-%%DATADIR%%/sounds/digits/mon-8.gsm
-%%DATADIR%%/sounds/digits/mon-9.gsm
-%%DATADIR%%/sounds/digits/oclock.gsm
-%%DATADIR%%/sounds/digits/oh.gsm
-%%DATADIR%%/sounds/digits/p-m.gsm
-%%DATADIR%%/sounds/digits/pound.gsm
-%%DATADIR%%/sounds/digits/star.gsm
-%%DATADIR%%/sounds/digits/thousand.gsm
-%%DATADIR%%/sounds/digits/today.gsm
-%%DATADIR%%/sounds/digits/tomorrow.gsm
-%%DATADIR%%/sounds/digits/yesterday.gsm
-%%DATADIR%%/sounds/dir-instr.gsm
-%%DATADIR%%/sounds/dir-intro-fn.gsm
-%%DATADIR%%/sounds/dir-intro.gsm
-%%DATADIR%%/sounds/dir-nomatch.gsm
-%%DATADIR%%/sounds/dir-nomore.gsm
-%%DATADIR%%/sounds/hello-world.gsm
-%%DATADIR%%/sounds/invalid.gsm
-%%DATADIR%%/sounds/letters/a.gsm
-%%DATADIR%%/sounds/letters/at.gsm
-%%DATADIR%%/sounds/letters/b.gsm
-%%DATADIR%%/sounds/letters/c.gsm
-%%DATADIR%%/sounds/letters/d.gsm
-%%DATADIR%%/sounds/letters/dash.gsm
-%%DATADIR%%/sounds/letters/dollar.gsm
-%%DATADIR%%/sounds/letters/dot.gsm
-%%DATADIR%%/sounds/letters/e.gsm
-%%DATADIR%%/sounds/letters/equals.gsm
-%%DATADIR%%/sounds/letters/exclaimation-point.gsm
-%%DATADIR%%/sounds/letters/f.gsm
-%%DATADIR%%/sounds/letters/g.gsm
-%%DATADIR%%/sounds/letters/h.gsm
-%%DATADIR%%/sounds/letters/i.gsm
-%%DATADIR%%/sounds/letters/j.gsm
-%%DATADIR%%/sounds/letters/k.gsm
-%%DATADIR%%/sounds/letters/l.gsm
-%%DATADIR%%/sounds/letters/m.gsm
-%%DATADIR%%/sounds/letters/n.gsm
-%%DATADIR%%/sounds/letters/o.gsm
-%%DATADIR%%/sounds/letters/p.gsm
-%%DATADIR%%/sounds/letters/plus.gsm
-%%DATADIR%%/sounds/letters/q.gsm
-%%DATADIR%%/sounds/letters/r.gsm
-%%DATADIR%%/sounds/letters/s.gsm
-%%DATADIR%%/sounds/letters/slash.gsm
-%%DATADIR%%/sounds/letters/space.gsm
-%%DATADIR%%/sounds/letters/t.gsm
-%%DATADIR%%/sounds/letters/u.gsm
-%%DATADIR%%/sounds/letters/v.gsm
-%%DATADIR%%/sounds/letters/w.gsm
-%%DATADIR%%/sounds/letters/x.gsm
-%%DATADIR%%/sounds/letters/y.gsm
-%%DATADIR%%/sounds/letters/z.gsm
-%%DATADIR%%/sounds/letters/zed.gsm
-%%DATADIR%%/sounds/pbx-invalid.gsm
-%%DATADIR%%/sounds/pbx-invalidpark.gsm
-%%DATADIR%%/sounds/pbx-transfer.gsm
-%%DATADIR%%/sounds/phonetic/9_p.gsm
-%%DATADIR%%/sounds/phonetic/a_p.gsm
-%%DATADIR%%/sounds/phonetic/b_p.gsm
-%%DATADIR%%/sounds/phonetic/c_p.gsm
-%%DATADIR%%/sounds/phonetic/d_p.gsm
-%%DATADIR%%/sounds/phonetic/e_p.gsm
-%%DATADIR%%/sounds/phonetic/f_p.gsm
-%%DATADIR%%/sounds/phonetic/g_p.gsm
-%%DATADIR%%/sounds/phonetic/h_p.gsm
-%%DATADIR%%/sounds/phonetic/i_p.gsm
-%%DATADIR%%/sounds/phonetic/j_p.gsm
-%%DATADIR%%/sounds/phonetic/k_p.gsm
-%%DATADIR%%/sounds/phonetic/l_p.gsm
-%%DATADIR%%/sounds/phonetic/m_p.gsm
-%%DATADIR%%/sounds/phonetic/n_p.gsm
-%%DATADIR%%/sounds/phonetic/o_p.gsm
-%%DATADIR%%/sounds/phonetic/p_p.gsm
-%%DATADIR%%/sounds/phonetic/q_p.gsm
-%%DATADIR%%/sounds/phonetic/r_p.gsm
-%%DATADIR%%/sounds/phonetic/s_p.gsm
-%%DATADIR%%/sounds/phonetic/t_p.gsm
-%%DATADIR%%/sounds/phonetic/u_p.gsm
-%%DATADIR%%/sounds/phonetic/v_p.gsm
-%%DATADIR%%/sounds/phonetic/w_p.gsm
-%%DATADIR%%/sounds/phonetic/x_p.gsm
-%%DATADIR%%/sounds/phonetic/y_p.gsm
-%%DATADIR%%/sounds/phonetic/z_p.gsm
-%%DATADIR%%/sounds/priv-callee-options.gsm
-%%DATADIR%%/sounds/priv-callpending.gsm
-%%DATADIR%%/sounds/priv-introsaved.gsm
-%%DATADIR%%/sounds/priv-recordintro.gsm
-%%DATADIR%%/sounds/privacy-incorrect.gsm
-%%DATADIR%%/sounds/privacy-prompt.gsm
-%%DATADIR%%/sounds/privacy-thankyou.gsm
-%%DATADIR%%/sounds/privacy-unident.gsm
-%%DATADIR%%/sounds/queue-callswaiting.gsm
-%%DATADIR%%/sounds/queue-holdtime.gsm
-%%DATADIR%%/sounds/queue-less-than.gsm
-%%DATADIR%%/sounds/queue-minutes.gsm
-%%DATADIR%%/sounds/queue-periodic-announce.gsm
-%%DATADIR%%/sounds/queue-reporthold.gsm
-%%DATADIR%%/sounds/queue-seconds.gsm
-%%DATADIR%%/sounds/queue-thankyou.gsm
-%%DATADIR%%/sounds/queue-thereare.gsm
-%%DATADIR%%/sounds/queue-youarenext.gsm
-%%DATADIR%%/sounds/screen-callee-options.gsm
-%%DATADIR%%/sounds/spy-agent.gsm
-%%DATADIR%%/sounds/spy-h323.gsm
-%%DATADIR%%/sounds/spy-iax.gsm
-%%DATADIR%%/sounds/spy-iax2.gsm
-%%DATADIR%%/sounds/spy-mgcp.gsm
-%%DATADIR%%/sounds/spy-sip.gsm
-%%DATADIR%%/sounds/spy-skinny.gsm
-%%DATADIR%%/sounds/spy-zap.gsm
-%%DATADIR%%/sounds/ss-noservice.gsm
-%%DATADIR%%/sounds/transfer.gsm
-%%DATADIR%%/sounds/tt-allbusy.gsm
-%%DATADIR%%/sounds/tt-monkeys.gsm
-%%DATADIR%%/sounds/tt-monkeysintro.gsm
-%%DATADIR%%/sounds/tt-somethingwrong.gsm
-%%DATADIR%%/sounds/tt-weasels.gsm
-%%DATADIR%%/sounds/vm-Cust1.gsm
-%%DATADIR%%/sounds/vm-Cust2.gsm
-%%DATADIR%%/sounds/vm-Cust3.gsm
-%%DATADIR%%/sounds/vm-Cust4.gsm
-%%DATADIR%%/sounds/vm-Cust5.gsm
-%%DATADIR%%/sounds/vm-Family.gsm
-%%DATADIR%%/sounds/vm-Friends.gsm
-%%DATADIR%%/sounds/vm-INBOX.gsm
-%%DATADIR%%/sounds/vm-Old.gsm
-%%DATADIR%%/sounds/vm-Work.gsm
-%%DATADIR%%/sounds/vm-advopts.gsm
-%%DATADIR%%/sounds/vm-and.gsm
-%%DATADIR%%/sounds/vm-calldiffnum.gsm
-%%DATADIR%%/sounds/vm-changeto.gsm
-%%DATADIR%%/sounds/vm-delete.gsm
-%%DATADIR%%/sounds/vm-deleted.gsm
-%%DATADIR%%/sounds/vm-dialout.gsm
-%%DATADIR%%/sounds/vm-enter-num-to-call.gsm
-%%DATADIR%%/sounds/vm-extension.gsm
-%%DATADIR%%/sounds/vm-first.gsm
-%%DATADIR%%/sounds/vm-for.gsm
-%%DATADIR%%/sounds/vm-forward.gsm
-%%DATADIR%%/sounds/vm-forwardoptions.gsm
-%%DATADIR%%/sounds/vm-from-extension.gsm
-%%DATADIR%%/sounds/vm-from-phonenumber.gsm
-%%DATADIR%%/sounds/vm-from.gsm
-%%DATADIR%%/sounds/vm-goodbye.gsm
-%%DATADIR%%/sounds/vm-helpexit.gsm
-%%DATADIR%%/sounds/vm-incorrect-mailbox.gsm
-%%DATADIR%%/sounds/vm-incorrect.gsm
-%%DATADIR%%/sounds/vm-instructions.gsm
-%%DATADIR%%/sounds/vm-intro.gsm
-%%DATADIR%%/sounds/vm-isonphone.gsm
-%%DATADIR%%/sounds/vm-isunavail.gsm
-%%DATADIR%%/sounds/vm-last.gsm
-%%DATADIR%%/sounds/vm-leavemsg.gsm
-%%DATADIR%%/sounds/vm-login.gsm
-%%DATADIR%%/sounds/vm-mailboxfull.gsm
-%%DATADIR%%/sounds/vm-message.gsm
-%%DATADIR%%/sounds/vm-messages.gsm
-%%DATADIR%%/sounds/vm-minutes.gsm
-%%DATADIR%%/sounds/vm-mismatch.gsm
-%%DATADIR%%/sounds/vm-msginstruct.gsm
-%%DATADIR%%/sounds/vm-msgsaved.gsm
-%%DATADIR%%/sounds/vm-newpassword.gsm
-%%DATADIR%%/sounds/vm-newuser.gsm
-%%DATADIR%%/sounds/vm-next.gsm
-%%DATADIR%%/sounds/vm-no.gsm
-%%DATADIR%%/sounds/vm-nobodyavail.gsm
-%%DATADIR%%/sounds/vm-nobox.gsm
-%%DATADIR%%/sounds/vm-nomore.gsm
-%%DATADIR%%/sounds/vm-nonumber.gsm
-%%DATADIR%%/sounds/vm-num-i-have.gsm
-%%DATADIR%%/sounds/vm-onefor.gsm
-%%DATADIR%%/sounds/vm-options.gsm
-%%DATADIR%%/sounds/vm-opts.gsm
-%%DATADIR%%/sounds/vm-passchanged.gsm
-%%DATADIR%%/sounds/vm-password.gsm
-%%DATADIR%%/sounds/vm-press.gsm
-%%DATADIR%%/sounds/vm-prev.gsm
-%%DATADIR%%/sounds/vm-reachoper.gsm
-%%DATADIR%%/sounds/vm-rec-busy.gsm
-%%DATADIR%%/sounds/vm-rec-name.gsm
-%%DATADIR%%/sounds/vm-rec-temp.gsm
-%%DATADIR%%/sounds/vm-rec-unv.gsm
-%%DATADIR%%/sounds/vm-received.gsm
-%%DATADIR%%/sounds/vm-reenterpassword.gsm
-%%DATADIR%%/sounds/vm-repeat.gsm
-%%DATADIR%%/sounds/vm-review.gsm
-%%DATADIR%%/sounds/vm-saved.gsm
-%%DATADIR%%/sounds/vm-savedto.gsm
-%%DATADIR%%/sounds/vm-savefolder.gsm
-%%DATADIR%%/sounds/vm-savemessage.gsm
-%%DATADIR%%/sounds/vm-saveoper.gsm
-%%DATADIR%%/sounds/vm-sorry.gsm
-%%DATADIR%%/sounds/vm-star-cancel.gsm
-%%DATADIR%%/sounds/vm-starmain.gsm
-%%DATADIR%%/sounds/vm-tempgreeting.gsm
-%%DATADIR%%/sounds/vm-tempgreeting2.gsm
-%%DATADIR%%/sounds/vm-tempremoved.gsm
-%%DATADIR%%/sounds/vm-then-pound.gsm
-%%DATADIR%%/sounds/vm-theperson.gsm
-%%DATADIR%%/sounds/vm-tocallback.gsm
-%%DATADIR%%/sounds/vm-tocallnum.gsm
-%%DATADIR%%/sounds/vm-tocancel.gsm
-%%DATADIR%%/sounds/vm-tocancelmsg.gsm
-%%DATADIR%%/sounds/vm-toenternumber.gsm
-%%DATADIR%%/sounds/vm-toforward.gsm
-%%DATADIR%%/sounds/vm-tohearenv.gsm
-%%DATADIR%%/sounds/vm-tomakecall.gsm
-%%DATADIR%%/sounds/vm-tooshort.gsm
-%%DATADIR%%/sounds/vm-toreply.gsm
-%%DATADIR%%/sounds/vm-torerecord.gsm
-%%DATADIR%%/sounds/vm-undelete.gsm
-%%DATADIR%%/sounds/vm-undeleted.gsm
-%%DATADIR%%/sounds/vm-unknown-caller.gsm
-%%DATADIR%%/sounds/vm-whichbox.gsm
-%%DATADIR%%/sounds/vm-youhave.gsm
-%%DATADIR%%/sounds/voicemail
-@dirrm %%DATADIR%%/sounds/dictate
-@dirrm %%DATADIR%%/sounds/phonetic
-@dirrm %%DATADIR%%/sounds/letters
-@dirrm %%DATADIR%%/sounds/digits
-@dirrm %%DATADIR%%/sounds/priv-callerintros
-@dirrm %%DATADIR%%/sounds
-@dirrm %%DATADIR%%/mohmp3
-@dirrm %%DATADIR%%/keys
-@dirrm %%DATADIR%%/images
-@dirrm %%DATADIR%%/firmware/iax
-@dirrm %%DATADIR%%/firmware
-@dirrm %%DATADIR%%/agi-bin
-@dirrm %%DATADIR%%
-@dirrm lib/asterisk/modules
-@dirrm lib/asterisk
-@dirrm include/asterisk
-@dirrm etc/asterisk
-@unexec rm -f %D/%%DATADIR%%/astdb
-@cwd /var
-spool/asterisk/voicemail/default/1234/busy.gsm
-spool/asterisk/voicemail/default/1234/unavail.gsm
-@exec mkdir -p %D/log/asterisk/cdr-csv
-@exec mkdir -p %D/spool/asterisk/voicemail/default/1234/INBOX
-@dirrm spool/asterisk/dictate
-@dirrm spool/asterisk/meetme
-@dirrm spool/asterisk/monitor
-@dirrm spool/asterisk/system
-@dirrm spool/asterisk/voicemail/default/1234/INBOX
-@dirrm spool/asterisk/voicemail/default/1234
-@dirrm spool/asterisk/voicemail/default
-@dirrm spool/asterisk/voicemail
-@dirrm spool/asterisk/tmp
-@dirrm spool/asterisk
-@dirrm log/asterisk/cdr-csv
-@dirrm log/asterisk/cdr-custom
-@dirrm log/asterisk
OpenPOWER on IntegriCloud