summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTony Vroon <chainsaw@gentoo.org>2010-12-30 17:28:01 +0000
committerTony Vroon <chainsaw@gentoo.org>2010-12-30 17:28:01 +0000
commit0395362da5c2f6e694385ff320315d68843153c3 (patch)
tree103fb6ac915af71015a479771f0eb1fadac768b6 /net-misc/asterisk
parentMark alpha/ia64/s390/sh stable #348471. (diff)
downloadhistorical-0395362da5c2f6e694385ff320315d68843153c3.tar.gz
historical-0395362da5c2f6e694385ff320315d68843153c3.tar.bz2
historical-0395362da5c2f6e694385ff320315d68843153c3.zip
Remove last 1.6.2 branch ebuild that uses in-tree patching. Clean up surrounding directories accordingly.
Package-Manager: portage-2.1.9.25/cvs/Linux x86_64
Diffstat (limited to 'net-misc/asterisk')
-rw-r--r--net-misc/asterisk/ChangeLog19
-rw-r--r--net-misc/asterisk/Manifest22
-rw-r--r--net-misc/asterisk/asterisk-1.6.2.13-r2.ebuild270
-rw-r--r--net-misc/asterisk/files/1.6.1/asterisk-1.6.1-uclibc.patch13
-rw-r--r--net-misc/asterisk/files/1.6.2/asterisk-1.6.2.11-strip-noapi.patch23
-rw-r--r--net-misc/asterisk/files/1.6.2/asterisk-1.6.2.13-alarm-receiver-use-playtones.patch151
-rw-r--r--net-misc/asterisk/files/1.6.2/asterisk-1.6.2.13-backport-bri-net-ptmp.patch35
-rw-r--r--net-misc/asterisk/files/1.6.2/asterisk-1.6.2.13-confbridge-menu-invocation.patch13
-rw-r--r--net-misc/asterisk/files/1.6.2/asterisk-1.6.2.13-dahdiras-without-root.patch12
-rw-r--r--net-misc/asterisk/files/1.6.2/asterisk-1.6.2.13-iax2-peerstate.patch12
-rw-r--r--net-misc/asterisk/files/1.6.2/asterisk-1.6.2.13-pbxstart-failed-spurious-bye.patch17
-rw-r--r--net-misc/asterisk/files/1.6.2/asterisk-1.6.2.2-nv-faxdetect.patch650
-rw-r--r--net-misc/asterisk/files/1.6.2/asterisk-1.6.2.8-inband-indications.patch20
-rw-r--r--net-misc/asterisk/files/1.6.2/asterisk-1.6.2.8-pri-missing-keyword.patch12
-rw-r--r--net-misc/asterisk/files/1.6.2/asterisk-1.6.2.9-gsm-pic.patch64
15 files changed, 22 insertions, 1311 deletions
diff --git a/net-misc/asterisk/ChangeLog b/net-misc/asterisk/ChangeLog
index 8583fe6f4a74..8d058ec57cdd 100644
--- a/net-misc/asterisk/ChangeLog
+++ b/net-misc/asterisk/ChangeLog
@@ -1,6 +1,23 @@
# ChangeLog for net-misc/asterisk
# Copyright 1999-2010 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/net-misc/asterisk/ChangeLog,v 1.277 2010/12/30 17:18:02 chainsaw Exp $
+# $Header: /var/cvsroot/gentoo-x86/net-misc/asterisk/ChangeLog,v 1.278 2010/12/30 17:28:01 chainsaw Exp $
+
+ 30 Dec 2010; Tony Vroon <chainsaw@gentoo.org>
+ -files/1.6.1/asterisk-1.6.1-uclibc.patch,
+ -files/1.6.2/asterisk-1.6.2.2-nv-faxdetect.patch,
+ -files/1.6.2/asterisk-1.6.2.8-inband-indications.patch,
+ -files/1.6.2/asterisk-1.6.2.8-pri-missing-keyword.patch,
+ -files/1.6.2/asterisk-1.6.2.9-gsm-pic.patch,
+ -files/1.6.2/asterisk-1.6.2.11-strip-noapi.patch,
+ -asterisk-1.6.2.13-r2.ebuild,
+ -files/1.6.2/asterisk-1.6.2.13-alarm-receiver-use-playtones.patch,
+ -files/1.6.2/asterisk-1.6.2.13-backport-bri-net-ptmp.patch,
+ -files/1.6.2/asterisk-1.6.2.13-confbridge-menu-invocation.patch,
+ -files/1.6.2/asterisk-1.6.2.13-dahdiras-without-root.patch,
+ -files/1.6.2/asterisk-1.6.2.13-iax2-peerstate.patch,
+ -files/1.6.2/asterisk-1.6.2.13-pbxstart-failed-spurious-bye.patch:
+ Remove last 1.6.2 branch ebuild that uses in-tree patching. Clean up
+ surrounding directories accordingly.
*asterisk-1.8.1.1 (30 Dec 2010)
diff --git a/net-misc/asterisk/Manifest b/net-misc/asterisk/Manifest
index a38a54ff8b3b..5361246375ac 100644
--- a/net-misc/asterisk/Manifest
+++ b/net-misc/asterisk/Manifest
@@ -20,18 +20,6 @@ AUX 1.4.0/asterisk.logrotate 436 RMD160 06a98d2a908464a951e3386a2681f5829dcb0220
AUX 1.4.0/func_devstate-r6.c 6070 RMD160 5c9c299b486a001e6f871d5177b5405521faf5d0 SHA1 a6b320bfc514fcfe7c396d848a17eb702ab194fd SHA256 50ca3794824f6772fce23d40b868a9bf6451e84765de44b8aa96b334c1d2967d
AUX 1.4.0/func_volume.c 4503 RMD160 7cdd1b570a3cc4ee8f7d49139ab50fe80f33d8bb SHA1 f34e4bb5d75fc9589b27ccd6555c0db5a0d27dbf SHA256 28c8040837ce9cf1c86fdc1d043685723a9f56a2398140d751b85c609248b698
AUX 1.6.0/asterisk.confd 2204 RMD160 31bceebfa535e97cb2634e313678cc42186d4750 SHA1 748c623cea238cd9b322672d5ebcfe214a4f0463 SHA256 daec84c58e0ef6cbd71a6fc62cb83129b1bcffdfdd619ebbd62a642f0cd1eee7
-AUX 1.6.1/asterisk-1.6.1-uclibc.patch 373 RMD160 08f18dd2af3736497995ebcbea84939ae4c4cc98 SHA1 b10884d4b9123800f62b4aabac5a93b1a110e3da SHA256 b6fe54def0ab3f90058c2ed7bd288dd21c96aaf88b9028f12d223fb31d7e41c5
-AUX 1.6.2/asterisk-1.6.2.11-strip-noapi.patch 742 RMD160 d9a176bc9bfed14adc3e59881c04932070cb98c3 SHA1 4d40de82f27bbeb8a0b62fa17d864b9629ba29a3 SHA256 c874f28eb895b0c87a0bbf9b60ec7cd7dfe2599faa1920d1f1a20c983be3bca8
-AUX 1.6.2/asterisk-1.6.2.13-alarm-receiver-use-playtones.patch 3989 RMD160 919d03d1d59517a4f7999b54a416e42d2e0f9e90 SHA1 80efe8e6b0421b8063a3419d760563af98caac5c SHA256 63f3fd50f923c6dd38e5c5f7d89bbfca5bb27d76e17a0bf1e679873349105e96
-AUX 1.6.2/asterisk-1.6.2.13-backport-bri-net-ptmp.patch 1839 RMD160 3b2b6101ef65325609bbdd7249240869fe1389bf SHA1 c62ce68ca642b32ffdc67ab52159ddd7c7061840 SHA256 1afdcb99201d3f97e94bafcb74f5c0c97f7b6a37262bd0333e728392a3152cc3
-AUX 1.6.2/asterisk-1.6.2.13-confbridge-menu-invocation.patch 650 RMD160 b938f7183425cb33ba1df505322ff885be004ce5 SHA1 0a15a661400d175162b3181ae3a1baa4c3c59aa2 SHA256 dcfb933f5c3bd8f1545b83dd8c67cf3c8e336d81bcdf471c01c50f2b366a759f
-AUX 1.6.2/asterisk-1.6.2.13-dahdiras-without-root.patch 419 RMD160 c08f2a41cbc54dfee87ea4a11eef63bbb67c0f4a SHA1 ab066ac1b4fd2ab2942e9229c4d53575cc3a242d SHA256 577ad92c596eaa9df4aff90c73e485cf88ba072d9e2264b8d44535e22e4d3293
-AUX 1.6.2/asterisk-1.6.2.13-iax2-peerstate.patch 1064 RMD160 dc65fe0f6acbf1c4def3458cbe316a11f665d9e2 SHA1 b02c13528184f603334ea440c2f1e05bf51aa754 SHA256 a92d24b968abcba8967d5584095a8b2b409248226fd8002e995e495289811f3d
-AUX 1.6.2/asterisk-1.6.2.13-pbxstart-failed-spurious-bye.patch 444 RMD160 5badc5dc3539b9a388e53b7699769add0e32fd82 SHA1 a65215d253072817c353f61d2628177c7f0acc77 SHA256 632f7b4f842474273d451340eb59ece3cd852af3480d3e2282e8173245195aaf
-AUX 1.6.2/asterisk-1.6.2.2-nv-faxdetect.patch 21042 RMD160 fa31dbfa3828f60073d59d0262166436ef37c516 SHA1 50f6b7a917dac981df1adf0713b373410af4ec68 SHA256 9919af0de073fc6c68a926daf84164df3b506d8fe4687177e8f9d636111707af
-AUX 1.6.2/asterisk-1.6.2.8-inband-indications.patch 468 RMD160 590c9271486fa08c6408d68eea332ab8a7fa76a7 SHA1 f586944eade3d1e9f21705ac27c11e90bb9edff6 SHA256 ddfe757f4810964b8d48e7363068763fbf313db14e4f9205d926dc34b1a86ba6
-AUX 1.6.2/asterisk-1.6.2.8-pri-missing-keyword.patch 547 RMD160 30deeb63ae09c316d5ada7597939adc8861a40d8 SHA1 722efddb5dde9238c0ee11cbfb58da25a5a2c95a SHA256 e3b98ee06015b062929613f41e430a93e571cf0920393f4480ebce256dd1e7fc
-AUX 1.6.2/asterisk-1.6.2.9-gsm-pic.patch 2423 RMD160 9eee96d54d9613c2e565d1983479b26762913e0e SHA1 c61479f1ee1f6ac113dae4dbf68222034990f6be SHA256 9cd951f984189f1dc93f9ecde1409f07c53644ef22091d668f55c0bb7122bc0c
AUX 1.6.2/asterisk.initd2 6658 RMD160 b694da109e746e9a9e642ffa7f1d278f03543cea SHA1 63443d3066d4c47228fe1d852420d571ae6f8800 SHA256 f6fd2c229e61c12360b1d289a631f6a0a6f8638e7c6f6add6040ad988170bf70
AUX 1.6.2/asterisk.initd3 6658 RMD160 adabbacaff55cc49077a919fb23eb6f8e3a2c076 SHA1 a256b7af478a4d83c19a89b23d79a4f832f1fb5a SHA256 ba737b5eadd4a5ff8653e30b54959c1d25a8a68699b8ce9adc9afe09da8b4110
AUX 1.6.2/asterisk.logrotate3 436 RMD160 06a98d2a908464a951e3386a2681f5829dcb0220 SHA1 31331f8fabc643f722a1c12cee0557e0268019ea SHA256 675705506d1adf7ec8c278581412a7ed69eed2735fea6c5f2faf368fb4ad9a26
@@ -52,7 +40,6 @@ DIST asterisk-1.2.27-patches-1.0.tar.bz2 6653 RMD160 18f1d7fc4497466050ed4f517ff
DIST asterisk-1.2.37.tar.gz 29899629 RMD160 1de7ff96d3b1fd8d89f3ef7b3bb9e35bedccfb33 SHA1 c9a3c4684e021f62b4d19f6e0c8fc11f64db19d6 SHA256 9f3ec67efe0e4d45434621cd358e8e7d64e1b05df04d66e2390c9420acd2aeaa
DIST asterisk-1.2.40.tar.gz 29903514 RMD160 dc3da60756c82c98a055e49b068eb6760a01948e SHA1 4b4b794e858a3436bc35bdd2f4edf824c2885b68 SHA256 61dc745b12f6dc2998404e77747a964db56df8efae84a666c4ccddf016c9c06d
DIST asterisk-1.4.37.tar.gz 21666828 RMD160 0918c251f4f1045a65a3276afbbe78525cc09e74 SHA1 c56758e0e39970eacf2d1d081e960f44d4efdb0e SHA256 0168cc552eb5c3758a447d22c6d08a8cba0509b0be4036e253f895066facf3f6
-DIST asterisk-1.6.2.13.tar.gz 23679304 RMD160 ebdd776da2e76a247a621748d8aea0c1f0cffc63 SHA1 b412d4a8589b5b58bd64e2b7f277712b7cbbfabd SHA256 28bb18e988d22557ee77220cb33209212af1e618348c3d42666f785da517c01e
DIST asterisk-1.6.2.14.tar.gz 23715262 RMD160 96024982e8e298c5ec61c5e3d6322a788060df51 SHA1 452b5b9200b9ac82679102516cb7cbf006c1bd9a SHA256 344fc0c4d0bb5488084aee7c2068b9efe21ec0fa183f41a4c3608e64fa38f332
DIST asterisk-1.8.0.tar.gz 26035124 RMD160 b2892a5718618d8fbd88147b8fc0c278ecb6b4ed SHA1 9e39d6678a5c09f2a145f04e492d3aadb63e2006 SHA256 8f1edbc8fab23596a6f6ee2881d67c22b4a6cb20bfad84125fcdcb3ff2e1de1b
DIST asterisk-1.8.1.1.tar.gz 26198619 RMD160 a761369083f9b5789dd055ab7df678b1cce83287 SHA1 8499778d83a8f35ce5abbfe4680de1701dc10f7c SHA256 71016372d81dd6c0b2977b8994aa626afa8aa71a2379005fc8fe30625ceedafa
@@ -61,16 +48,15 @@ DIST gentoo-asterisk-patchset-0.2.tar.bz2 7398 RMD160 65b282fa621b3e65d293cd7e1d
EBUILD asterisk-1.2.37.ebuild 10738 RMD160 0f409319cb82c2c92cde0ab6436e44dd214c0cf3 SHA1 6cce3c94e5ace2f1f9fa7e6a621b358e3921cbec SHA256 fc6ed3447de3400e74fcffeee457adc59a4433047655f4190b55a9dfbec8c18b
EBUILD asterisk-1.2.40.ebuild 10743 RMD160 f3db358e4776aef3dfb196f5e182f6f588030f60 SHA1 ae80355f7aa6e84c413f83c20028209e2908e3f9 SHA256 f67e2a7c507315feffdeb5950f9225c9edb038bb915f5402102dbd4da693c35d
EBUILD asterisk-1.4.37.ebuild 8182 RMD160 cba2a7b76e5e85af081628c93ce8bca08578b585 SHA1 865eb1c2338b82863c4a37c24afc74997251c9c5 SHA256 bb18a3f8e15aa66c1f8ec6171d7228a10d9a0e9a89fa5908fe008e2a5bb81ffd
-EBUILD asterisk-1.6.2.13-r2.ebuild 7377 RMD160 12c080a61d7c345fcebb6bc148baf0396f2db8f9 SHA1 4df6a0218d162724e759d9d11660d623a7c314ce SHA256 40a5be578f62de21c53f4d312d743796746705a5d27deccefb5e0504add00c75
EBUILD asterisk-1.6.2.14.ebuild 6450 RMD160 f53c065e0d5f5f89c14bcbf54f32e2016a4c3142 SHA1 e3bbafe31336381edfaef2278283ce8e9c6c8f34 SHA256 a62ebf9759f9083dbf23dd758bbcec14dc14a16ff6f1041fdc10ed84bfb74267
EBUILD asterisk-1.8.0.ebuild 8206 RMD160 3120b6ff9de7a75fa78f7060eb47cbf5cc839af3 SHA1 04296cdd77a2d55a2fc15b2359f08b83be316b5e SHA256 e1d17452162bd0d97ef34686ada271bcba9751d60941990304c1060b03cccdc0
EBUILD asterisk-1.8.1.1.ebuild 7719 RMD160 fd474abdbf6ac205d5f1ed8bfd40e1700b30aacf SHA1 d0218b502f4e4451c1a9bc41546cb288de5178bb SHA256 ebd79af48f11143b81b6402d5fb8fcfdf25a2631542aae1dce3911d31d485250
-MISC ChangeLog 66794 RMD160 b523b91f0a61621229f8cec2e461b70880bc0d0b SHA1 b1f417031f4b60d561f2624b0a3aeae86f49b792 SHA256 351b33ee9de16c92839daa46cc07a5a99474471de3758afe9fe404dd16c5b444
+MISC ChangeLog 67681 RMD160 ebae9e3273b4ff7704da7227f06a394ed12ca865 SHA1 585443eabe2800520761f350f552f55cc0ed6bc4 SHA256 48016e1f2bdae18e566237912397cf54c1a03f8ae943eefc7bd5c3f3aefa854e
MISC metadata.xml 1773 RMD160 42bd30a0749acec6c954d6a12a63138876aa9e6c SHA1 1516741f8181e5fffa11222b29872110ac0d7928 SHA256 e5f6bae7a2ec088d102398005ffe5d409f38b698887c333a7c4afc9c30a1008e
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.16 (GNU/Linux)
-iEYEARECAAYFAk0cvs8ACgkQp5vW4rUFj5o3ZgCcDg2cxlsHWLAnA3fimRlKfWns
-d2MAn3l8QEWQihXgQGK6/D0pnQTPB+LD
-=reTd
+iEYEARECAAYFAk0cwSUACgkQp5vW4rUFj5pyPgCgiqI6YRHCm7VZEuz/mX78qwGR
+6pYAnAvrr4xt/f24TmmNLE84PlPzh7aV
+=2YVH
-----END PGP SIGNATURE-----
diff --git a/net-misc/asterisk/asterisk-1.6.2.13-r2.ebuild b/net-misc/asterisk/asterisk-1.6.2.13-r2.ebuild
deleted file mode 100644
index 01bcbe596757..000000000000
--- a/net-misc/asterisk/asterisk-1.6.2.13-r2.ebuild
+++ /dev/null
@@ -1,270 +0,0 @@
-# Copyright 1999-2010 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/net-misc/asterisk/asterisk-1.6.2.13-r2.ebuild,v 1.1 2010/10/15 17:30:59 chainsaw Exp $
-
-EAPI=3
-inherit autotools base eutils linux-info multilib
-
-MY_P="${PN}-${PV/_/-}"
-
-DESCRIPTION="Asterisk: A Modular Open Source PBX System"
-HOMEPAGE="http://www.asterisk.org/"
-SRC_URI="http://downloads.asterisk.org/pub/telephony/asterisk/releases/${MY_P}.tar.gz"
-LICENSE="GPL-2"
-SLOT="0"
-KEYWORDS="~amd64 ~x86"
-
-IUSE="alsa +caps dahdi debug doc freetds iconv jabber ldap lua keepsrc logrotate misdn newt +samples oss postgres radius snmp span speex ssl sqlite static vorbis"
-
-RDEPEND="sys-libs/ncurses
- dev-libs/popt
- sys-libs/zlib
- alsa? ( media-libs/alsa-lib )
- caps? ( sys-libs/libcap )
- dahdi? ( >=net-libs/libpri-1.4.7
- net-misc/dahdi-tools )
- freetds? ( dev-db/freetds )
- iconv? ( virtual/libiconv )
- jabber? ( dev-libs/iksemel )
- ldap? ( net-nds/openldap )
- lua? ( dev-lang/lua )
- misdn? ( net-dialup/misdnuser )
- newt? ( dev-libs/newt )
- postgres? ( dev-db/postgresql-base )
- radius? ( net-dialup/radiusclient-ng )
- snmp? ( net-analyzer/net-snmp )
- span? ( media-libs/spandsp )
- speex? ( media-libs/speex )
- sqlite? ( dev-db/sqlite )
- ssl? ( dev-libs/openssl )
- vorbis? ( media-libs/libvorbis )"
-
-DEPEND="${RDEPEND}
- !<net-misc/asterisk-addons-1.6
- !net-misc/asterisk-chan_unistim
- !net-misc/zaptel"
-
-PDEPEND="net-misc/asterisk-core-sounds
- net-misc/asterisk-extra-sounds
- net-misc/asterisk-moh-opsound"
-
-S="${WORKDIR}/${MY_P}"
-
-PATCHES=(
- "${FILESDIR}/1.6.2/${PN}-1.6.2.9-gsm-pic.patch"
- "${FILESDIR}/1.6.2/${PN}-1.6.2.8-pri-missing-keyword.patch"
- "${FILESDIR}/1.6.2/${PN}-1.6.2.8-inband-indications.patch"
- "${FILESDIR}/1.6.1/${PN}-1.6.1-uclibc.patch"
- "${FILESDIR}/1.6.2/${PN}-1.6.2.2-nv-faxdetect.patch"
- "${FILESDIR}/1.6.2/${PN}-1.6.2.11-strip-noapi.patch"
- "${FILESDIR}/1.6.2/${P}-iax2-peerstate.patch"
- "${FILESDIR}/1.6.2/${P}-dahdiras-without-root.patch"
- "${FILESDIR}/1.6.2/${P}-backport-bri-net-ptmp.patch"
- "${FILESDIR}/1.6.2/${P}-pbxstart-failed-spurious-bye.patch"
- "${FILESDIR}/1.6.2/${P}-confbridge-menu-invocation.patch"
- "${FILESDIR}/1.6.2/${P}-alarm-receiver-use-playtones.patch"
-)
-
-pkg_setup() {
- CONFIG_CHECK="~!NF_CONNTRACK_SIP"
- local WARNING_NF_CONNTRACK_SIP="SIP (NAT) connection tracking is enabled. Some users
- have reported that this module dropped critical SIP packets in their deployments. You
- may want to disable it if you see such problems."
- check_extra_config
-}
-
-src_prepare() {
- base_src_prepare
- AT_M4DIR=autoconf eautoreconf
-}
-
-src_configure() {
- econf \
- --libdir="/usr/$(get_libdir)" \
- --localstatedir="/var" \
- --with-gsm=internal \
- --with-popt \
- --with-z \
- $(use_with alsa asound) \
- $(use_with caps cap) \
- $(use_with dahdi pri) \
- $(use_with dahdi tonezone) \
- $(use_with dahdi) \
- $(use_with freetds tds) \
- $(use_with iconv) \
- $(use_with jabber iksemel) \
- $(use_with lua) \
- $(use_with misdn isdnnet) \
- $(use_with misdn suppserv) \
- $(use_with misdn) \
- $(use_with newt) \
- $(use_with oss) \
- $(use_with postgres) \
- $(use_with radius) \
- $(use_with snmp netsnmp) \
- $(use_with span spandsp) \
- $(use_with speex) \
- $(use_with speex speexdsp) \
- $(use_with sqlite sqlite3) \
- $(use_with ssl crypto) \
- $(use_with ssl) \
- $(use_with vorbis ogg) \
- $(use_with vorbis) || die "econf failed"
-
- #
- # blank out sounds/sounds.xml file to prevent
- # asterisk from installing sounds files (we pull them in via
- # asterisk-{core,extra}-sounds and asterisk-moh-opsound.
- #
- >"${S}"/sounds/sounds.xml
-}
-
-src_compile() {
- ASTLDFLAGS="${LDFLAGS}" emake || die "emake failed"
-}
-
-src_install() {
- # setup directory structure
- #
- mkdir -p "${D}"usr/$(get_libdir)/pkgconfig
-
- emake DESTDIR="${D}" install || die "emake install failed"
-
- if use samples; then
- emake DESTDIR="${D}" samples || die "emake samples failed"
- for conffile in "${D}"etc/asterisk/*.*
- do
- chown asterisk:asterisk $conffile
- chmod 0660 $conffile
- done
- einfo "Sample files have been installed"
- else
- einfo "Skipping installation of sample files..."
- rm -f "${D}"var/lib/asterisk/mohmp3/*
- rm -f "${D}"var/lib/asterisk/sounds/demo-*
- rm -f "${D}"var/lib/asterisk/agi-bin/*
- rm -f "${D}"etc/asterisk/*
- fi
- rm -rf "${D}"var/spool/asterisk/voicemail/default
-
- # keep directories
- diropts -m 0770 -o asterisk -g asterisk
- keepdir /etc/asterisk
- keepdir /var/lib/asterisk
- keepdir /var/run/asterisk
- keepdir /var/spool/asterisk
- keepdir /var/spool/asterisk/{system,tmp,meetme,monitor,dictate,voicemail}
- diropts -m 0750 -o asterisk -g asterisk
- keepdir /var/log/asterisk/{cdr-csv,cdr-custom}
-
- newinitd "${FILESDIR}"/1.6.2/asterisk.initd2 asterisk
- newconfd "${FILESDIR}"/1.6.0/asterisk.confd asterisk
-
- # some people like to keep the sources around for custom patching
- # copy the whole source tree to /usr/src/asterisk-${PVF} and run make clean there
- if use keepsrc
- then
- dodir /usr/src
-
- ebegin "Copying sources into /usr/src"
- cp -dPR "${S}" "${D}"/usr/src/${PF} || die "Unable to copy sources"
- eend $?
-
- ebegin "Cleaning source tree"
- emake -C "${D}"/usr/src/${PF} clean &>/dev/null || die "Unable to clean sources"
- eend $?
-
- einfo "Clean sources are available in "${ROOT}"usr/src/${PF}"
- fi
-
- # install the upgrade documentation
- #
- dodoc README UPGRADE* BUGS CREDITS
-
- # install extra documentation
- #
- if use doc
- then
- dodoc doc/*.txt
- dodoc doc/*.pdf
- dodoc doc/PEERING
- dodoc doc/CODING-GUIDELINES
- dodoc doc/tex/*.pdf
- fi
-
- # install snmp mib files
- #
- if use snmp
- then
- insinto /usr/share/snmp/mibs/
- doins doc/digium-mib.txt doc/asterisk-mib.txt
- fi
-
- # install SIP scripts; bug #300832
- #
- dodoc "${FILESDIR}/1.6.2/sip_calc_auth"
- dodoc "${FILESDIR}/1.6.2/find_call_sip_trace.sh"
- dodoc "${FILESDIR}/1.6.2/find_call_ids.sh"
- dodoc "${FILESDIR}/1.6.2/call_data.txt"
-
- # install logrotate snippet; bug #329281
- #
- if use logrotate
- then
- insinto /etc/logrotate.d
- newins "${FILESDIR}/1.6.2/asterisk.logrotate3" asterisk
- fi
-}
-
-pkg_preinst() {
- enewgroup asterisk
- enewuser asterisk -1 -1 /var/lib/asterisk "asterisk,dialout"
-}
-
-pkg_postinst() {
- #
- # Announcements, warnings, reminders...
- #
- einfo "Asterisk has been installed"
- echo
- elog "If you want to know more about asterisk, visit these sites:"
- elog "http://www.asteriskdocs.org/"
- elog "http://www.voip-info.org/wiki-Asterisk"
- echo
- elog "http://www.automated.it/guidetoasterisk.htm"
- echo
- elog "Gentoo VoIP IRC Channel:"
- elog "#gentoo-voip @ irc.freenode.net"
- echo
- echo
- elog "1.6.1 -> 1.6.2 changes that you may care about:"
- elog "canreinvite -> directmedia (sip.conf)"
- elog "extensive T.38 (fax) changes"
- elog "http://svn.asterisk.org/svn/${PN}/tags/${PV}/UPGRADE.txt"
- elog "or: bzless ${ROOT}usr/share/doc/${PF}/UPGRADE.txt.bz2"
-}
-
-pkg_config() {
- einfo "Do you want to reset file permissions and ownerships (y/N)?"
-
- read tmp
- tmp="$(echo $tmp | tr '[:upper:]' '[:lower:]')"
-
- if [[ "$tmp" = "y" ]] ||\
- [[ "$tmp" = "yes" ]]
- then
- einfo "Resetting permissions to defaults..."
-
- for x in spool run lib log; do
- chown -R asterisk:asterisk "${ROOT}"var/${x}/asterisk
- chmod -R u=rwX,g=rwX,o= "${ROOT}"var/${x}/asterisk
- done
-
- chown -R root:asterisk "${ROOT}"etc/asterisk
- chmod -R u=rwX,g=rwX,o= "${ROOT}"etc/asterisk
-
- einfo "done"
- else
- einfo "skipping"
- fi
-}
diff --git a/net-misc/asterisk/files/1.6.1/asterisk-1.6.1-uclibc.patch b/net-misc/asterisk/files/1.6.1/asterisk-1.6.1-uclibc.patch
deleted file mode 100644
index 36b49e60b19e..000000000000
--- a/net-misc/asterisk/files/1.6.1/asterisk-1.6.1-uclibc.patch
+++ /dev/null
@@ -1,13 +0,0 @@
---- Makefile.old 2008-03-22 11:51:39.000000000 +0100
-+++ Makefile 2008-03-22 11:51:49.000000000 +0100
-@@ -259,6 +259,10 @@
- ASTCFLAGS+=-pthread
- endif
-
-+ifeq ($(OSARCH),linux-uclibc)
-+ AST_LIBS+=-lpthread -ldl
-+endif
-+
- ifeq ($(OSARCH),SunOS)
- ASTCFLAGS+=-Wcast-align -DSOLARIS -I../include/solaris-compat -I/opt/ssl/include -I/usr/local/ssl/include -D_XPG4_2
- endif
diff --git a/net-misc/asterisk/files/1.6.2/asterisk-1.6.2.11-strip-noapi.patch b/net-misc/asterisk/files/1.6.2/asterisk-1.6.2.11-strip-noapi.patch
deleted file mode 100644
index 4861a6cdc932..000000000000
--- a/net-misc/asterisk/files/1.6.2/asterisk-1.6.2.11-strip-noapi.patch
+++ /dev/null
@@ -1,23 +0,0 @@
-diff -uNr asterisk-1.6.2.2.ORIG/build_tools/strip_nonapi asterisk-1.6.2.2/build_tools/strip_nonapi
---- asterisk-1.6.2.2.ORIG/build_tools/strip_nonapi 2008-06-19 21:26:50.000000000 +0500
-+++ asterisk-1.6.2.2/build_tools/strip_nonapi 2010-02-10 20:15:13.000000000 +0400
-@@ -29,10 +29,15 @@
-
- case "${OSARCH}" in
- linux-gnu|FreeBSD)
-- nm ${1} | ${GREP} -e "$TEXTSYM" | cut -d" " -f3 | ${FILTER} > striplist
-- sed -e "s/^/-N /" striplist | xargs -n 40 ${STRIP} ${1}
-- rm -f striplist
-- ;;
-+ nm ${1} > symlist
-+ if [ -s symlist ]
-+ then
-+ ${GREP} -e "$TEXTSYM" symlist | cut -d" " -f3 | ${FILTER} > striplist
-+ sed -e "s/^/-N /" striplist | xargs -n 40 ${STRIP} ${1}
-+ rm -f striplist
-+ fi
-+ rm -f symlist
-+ ;;
- *)
- ;;
- esac
diff --git a/net-misc/asterisk/files/1.6.2/asterisk-1.6.2.13-alarm-receiver-use-playtones.patch b/net-misc/asterisk/files/1.6.2/asterisk-1.6.2.13-alarm-receiver-use-playtones.patch
deleted file mode 100644
index e434a12aa1e9..000000000000
--- a/net-misc/asterisk/files/1.6.2/asterisk-1.6.2.13-alarm-receiver-use-playtones.patch
+++ /dev/null
@@ -1,151 +0,0 @@
-diff -uNr asterisk-1.6.2.13.ORIG//apps/app_alarmreceiver.c asterisk-1.6.2.13/apps/app_alarmreceiver.c
---- asterisk-1.6.2.13.ORIG//apps/app_alarmreceiver.c 2010-10-15 18:17:49.000000000 +0100
-+++ asterisk-1.6.2.13/apps/app_alarmreceiver.c 2010-10-15 18:18:50.000000000 +0100
-@@ -51,6 +51,7 @@
- #include "asterisk/callerid.h"
- #include "asterisk/astdb.h"
- #include "asterisk/utils.h"
-+#include "asterisk/indications.h"
-
- #define ALMRCV_CONFIG "alarmreceiver.conf"
- #define ADEMCO_CONTACT_ID "ADEMCO_CONTACT_ID"
-@@ -139,86 +140,6 @@
- return;
- }
-
--
--/*
--* Build a MuLaw data block for a single frequency tone
--*/
--static void make_tone_burst(unsigned char *data, float freq, float loudness, int len, int *x)
--{
-- int i;
-- float val;
--
-- for (i = 0; i < len; i++) {
-- val = loudness * sin((freq * 2.0 * M_PI * (*x)++)/8000.0);
-- data[i] = AST_LIN2MU((int)val);
-- }
--
-- /* wrap back around from 8000 */
--
-- if (*x >= 8000)
-- *x = 0;
-- return;
--}
--
--/*
--* Send a single tone burst for a specifed duration and frequency.
--* Returns 0 if successful
--*/
--static int send_tone_burst(struct ast_channel *chan, float freq, int duration, int tldn)
--{
-- int res = 0;
-- int i = 0;
-- int x = 0;
-- struct ast_frame *f, wf;
--
-- struct {
-- unsigned char offset[AST_FRIENDLY_OFFSET];
-- unsigned char buf[640];
-- } tone_block;
--
-- for (;;) {
--
-- if (ast_waitfor(chan, -1) < 0) {
-- res = -1;
-- break;
-- }
--
-- f = ast_read(chan);
-- if (!f) {
-- res = -1;
-- break;
-- }
--
-- if (f->frametype == AST_FRAME_VOICE) {
-- wf.frametype = AST_FRAME_VOICE;
-- wf.subclass = AST_FORMAT_ULAW;
-- wf.offset = AST_FRIENDLY_OFFSET;
-- wf.mallocd = 0;
-- wf.data.ptr = tone_block.buf;
-- wf.datalen = f->datalen;
-- wf.samples = wf.datalen;
--
-- make_tone_burst(tone_block.buf, freq, (float) tldn, wf.datalen, &x);
--
-- i += wf.datalen / 8;
-- if (i > duration) {
-- ast_frfree(f);
-- break;
-- }
-- if (ast_write(chan, &wf)) {
-- ast_verb(4, "AlarmReceiver: Failed to write frame on %s\n", chan->name);
-- ast_log(LOG_WARNING, "AlarmReceiver Failed to write frame on %s\n",chan->name);
-- res = -1;
-- ast_frfree(f);
-- break;
-- }
-- }
--
-- ast_frfree(f);
-- }
-- return res;
--}
--
- /*
- * Receive a string of DTMF digits where the length of the digit string is known in advance. Do not give preferential
- * treatment to any digit value, and allow separate time out values to be specified for the first digit and all subsequent
-@@ -433,19 +354,29 @@
- database_increment("calls-received");
-
- /* Wait for first event */
-- ast_verb(4, "AlarmReceiver: Waiting for first event from panel\n");
-+ ast_verb(4, "AlarmReceiver: Waiting for first event from panel...\n");
-
- while (res >= 0) {
- if (got_some_digits == 0) {
- /* Send ACK tone sequence */
- ast_verb(4, "AlarmReceiver: Sending 1400Hz 100ms burst (ACK)\n");
-- res = send_tone_burst(chan, 1400.0, 100, tldn);
-- if (!res)
-- res = ast_safe_sleep(chan, 100);
-+ res = ast_playtones_start(chan, tldn, "1400", 0);
- if (!res) {
-+ ast_safe_sleep(chan, 100);
-+ ast_playtones_stop(chan);
-+ }
-+ if (!res) {
-+ ast_safe_sleep(chan, 100);
- ast_verb(4, "AlarmReceiver: Sending 2300Hz 100ms burst (ACK)\n");
-- res = send_tone_burst(chan, 2300.0, 100, tldn);
-+ res = ast_playtones_start(chan, tldn, "2300", 0);
-+ if (!res) {
-+ ast_safe_sleep(chan, 100);
-+ ast_playtones_stop(chan);
-+ }
-+ } else {
-+ ast_debug(1, "AlarmReceiver: Failed sending tones\n");
- }
-+
- }
- if ( res >= 0)
- res = receive_dtmf_digits(chan, event, sizeof(event) - 1, fdto, sdto);
-@@ -552,9 +483,14 @@
- if (res == 0)
- res = ast_safe_sleep(chan, 200);
-
-- /* Send the kissoff tone */
-- if (res == 0)
-- res = send_tone_burst(chan, 1400.0, 900, tldn);
-+ /* Send the kissoff tone (1400 Hz, 900 ms) */
-+ if (res == 0) {
-+ res = ast_playtones_start(chan, tldn, "1400", 0);
-+ if (res == 0) {
-+ ast_safe_sleep(chan, 900);
-+ ast_playtones_stop(chan);
-+ }
-+ }
- }
-
- return res;
diff --git a/net-misc/asterisk/files/1.6.2/asterisk-1.6.2.13-backport-bri-net-ptmp.patch b/net-misc/asterisk/files/1.6.2/asterisk-1.6.2.13-backport-bri-net-ptmp.patch
deleted file mode 100644
index 18f8dcce8090..000000000000
--- a/net-misc/asterisk/files/1.6.2/asterisk-1.6.2.13-backport-bri-net-ptmp.patch
+++ /dev/null
@@ -1,35 +0,0 @@
-diff -uNr asterisk-1.6.2.13.ORIG//channels/chan_dahdi.c asterisk-1.6.2.13/channels/chan_dahdi.c
---- asterisk-1.6.2.13.ORIG//channels/chan_dahdi.c 2010-09-16 18:25:04.000000000 +0100
-+++ asterisk-1.6.2.13/channels/chan_dahdi.c 2010-09-16 18:25:21.000000000 +0100
-@@ -16630,7 +16630,12 @@
- confp->chan.sig = SIG_BRI_PTMP;
- confp->pri.nodetype = PRI_CPE;
- } else if (!strcasecmp(v->value, "bri_net_ptmp")) {
-+#if defined(HAVE_PRI_CALL_HOLD)
-+ confp->chan.sig = SIG_BRI_PTMP;
-+ confp->pri.nodetype = PRI_NETWORK;
-+#else
- ast_log(LOG_WARNING, "How cool would it be if someone implemented this mode! For now, sucks for you. (line %d)\n", v->lineno);
-+#endif
- } else if (!strcasecmp(v->value, "gr303fxoks_net")) {
- confp->chan.sig = SIG_GR303FXOKS;
- confp->pri.nodetype = PRI_NETWORK;
-diff -uNr asterisk-1.6.2.13.ORIG//configure.ac asterisk-1.6.2.13/configure.ac
---- asterisk-1.6.2.13.ORIG//configure.ac 2010-09-16 18:25:04.000000000 +0100
-+++ asterisk-1.6.2.13/configure.ac 2010-09-16 18:25:21.000000000 +0100
-@@ -334,6 +334,7 @@
- AST_EXT_LIB_SETUP([PORTAUDIO], [PortAudio], [portaudio])
- AST_EXT_LIB_SETUP([PRI], [ISDN PRI], [pri])
- AST_EXT_LIB_SETUP_DEPENDENT([PRI_INBANDDISCONNECT], [ISDN PRI set_inbanddisconnect], [PRI], [pri])
-+AST_EXT_LIB_SETUP_DEPENDENT([PRI_CALL_HOLD], [ISDN PRI call hold], [PRI], [pri])
- AST_EXT_LIB_SETUP([PWLIB], [PWlib], [pwlib])
- AST_EXT_LIB_SETUP([RADIUS], [Radius Client], [radius])
- AST_EXT_LIB_SETUP([RESAMPLE], [LIBRESAMPLE], [resample])
-@@ -1490,6 +1491,7 @@
- AST_EXT_LIB_CHECK([PORTAUDIO], [portaudio], [Pa_GetDeviceCount], [portaudio.h])
-
- AST_EXT_LIB_CHECK([PRI], [pri], [pri_new_bri], [libpri.h])
-+AST_EXT_LIB_CHECK([PRI_CALL_HOLD], [pri], [pri_hold_enable], [libpri.h])
-
- AST_EXT_LIB_CHECK([PRI_PROG_W_CAUSE], [pri], [pri_progress_with_cause], [libpri.h])
-
diff --git a/net-misc/asterisk/files/1.6.2/asterisk-1.6.2.13-confbridge-menu-invocation.patch b/net-misc/asterisk/files/1.6.2/asterisk-1.6.2.13-confbridge-menu-invocation.patch
deleted file mode 100644
index 9685af91a53a..000000000000
--- a/net-misc/asterisk/files/1.6.2/asterisk-1.6.2.13-confbridge-menu-invocation.patch
+++ /dev/null
@@ -1,13 +0,0 @@
-Index: apps/app_confbridge.c
-===================================================================
---- apps/app_confbridge.c (revision 271056)
-+++ apps/app_confbridge.c (working copy)
-@@ -734,7 +734,7 @@
-
- /* If the menu option is enabled provide a user or admin menu as a custom feature hook */
- if (ast_test_flag(&conference_bridge_user.flags, OPTION_MENU)) {
-- ast_bridge_features_hook(&conference_bridge_user.features, "#", menu_callback, &conference_bridge_user);
-+ ast_bridge_features_hook(&conference_bridge_user.features, "*", menu_callback, &conference_bridge_user);
- }
-
- /* If the caller should be joined already muted, make it so */
diff --git a/net-misc/asterisk/files/1.6.2/asterisk-1.6.2.13-dahdiras-without-root.patch b/net-misc/asterisk/files/1.6.2/asterisk-1.6.2.13-dahdiras-without-root.patch
deleted file mode 100644
index 94f3d3681288..000000000000
--- a/net-misc/asterisk/files/1.6.2/asterisk-1.6.2.13-dahdiras-without-root.patch
+++ /dev/null
@@ -1,12 +0,0 @@
-diff -uNr asterisk-1.6.2.13.ORIG/apps/app_dahdiras.c asterisk-1.6.2.13/apps/app_dahdiras.c
---- asterisk-1.6.2.13.ORIG/apps/app_dahdiras.c 2010-09-16 17:40:39.000000000 +0100
-+++ asterisk-1.6.2.13/apps/app_dahdiras.c 2010-09-16 17:41:05.000000000 +0100
-@@ -119,8 +119,6 @@
- c = strsep(&stringp, ",");
- }
-
-- argv[argc++] = "plugin";
-- argv[argc++] = "dahdi.so";
- argv[argc++] = "stdin";
-
- /* Finally launch PPP */
diff --git a/net-misc/asterisk/files/1.6.2/asterisk-1.6.2.13-iax2-peerstate.patch b/net-misc/asterisk/files/1.6.2/asterisk-1.6.2.13-iax2-peerstate.patch
deleted file mode 100644
index c9eb8d579205..000000000000
--- a/net-misc/asterisk/files/1.6.2/asterisk-1.6.2.13-iax2-peerstate.patch
+++ /dev/null
@@ -1,12 +0,0 @@
-diff -uNr asterisk-1.6.2.13.ORIG/channels/chan_iax2.c asterisk-1.6.2.13/channels/chan_iax2.c
---- asterisk-1.6.2.13.ORIG/channels/chan_iax2.c 2010-09-16 13:18:19.000000000 +0100
-+++ asterisk-1.6.2.13/channels/chan_iax2.c 2010-09-16 13:18:41.000000000 +0100
-@@ -8403,7 +8403,7 @@
- ast_db_put("IAX/Registry", p->name, data);
- ast_verb(3, "Registered IAX2 '%s' (%s) at %s:%d\n", p->name,
- ast_test_flag(&iaxs[callno]->state, IAX_STATE_AUTHENTICATED) ? "AUTHENTICATED" : "UNAUTHENTICATED", ast_inet_ntoa(sin->sin_addr), ntohs(sin->sin_port));
-- manager_event(EVENT_FLAG_SYSTEM, "PeerStatus", "ChannelType: IAX2\r\nPeer: IAX2/%s\r\nPeerStatus: Registered\r\n", p->name);
-+ manager_event(EVENT_FLAG_SYSTEM, "PeerStatus", "ChannelType: IAX2\r\nPeer: IAX2/%s\r\nPeerStatus: Registered\r\nAddress: %s\r\nPost: %d\r\n", p->name, ast_inet_ntoa(sin->sin_addr), ntohs(sin->sin_port));
- register_peer_exten(p, 1);
- ast_devstate_changed(AST_DEVICE_UNKNOWN, "IAX2/%s", p->name); /* Activate notification */
- } else if (!ast_test_flag(p, IAX_TEMPONLY)) {
diff --git a/net-misc/asterisk/files/1.6.2/asterisk-1.6.2.13-pbxstart-failed-spurious-bye.patch b/net-misc/asterisk/files/1.6.2/asterisk-1.6.2.13-pbxstart-failed-spurious-bye.patch
deleted file mode 100644
index 1a47eff12cb5..000000000000
--- a/net-misc/asterisk/files/1.6.2/asterisk-1.6.2.13-pbxstart-failed-spurious-bye.patch
+++ /dev/null
@@ -1,17 +0,0 @@
----
- channels/chan_sip.c | 2 ++
- 1 file changed, 2 insertions(+)
-
-Index: b/channels/chan_sip.c
-===================================================================
---- a/channels/chan_sip.c
-+++ b/channels/chan_sip.c
-@@ -20871,6 +20871,8 @@ static int handle_request_invite(struct
-
- if (result) {
-
-+ sip_alreadygone(p);
-+
- /* Unlock locks so ast_hangup can do its magic */
- ast_channel_unlock(c);
- sip_pvt_unlock(p);
diff --git a/net-misc/asterisk/files/1.6.2/asterisk-1.6.2.2-nv-faxdetect.patch b/net-misc/asterisk/files/1.6.2/asterisk-1.6.2.2-nv-faxdetect.patch
deleted file mode 100644
index ee2ef4408cf6..000000000000
--- a/net-misc/asterisk/files/1.6.2/asterisk-1.6.2.2-nv-faxdetect.patch
+++ /dev/null
@@ -1,650 +0,0 @@
-diff -uNr apps/app_nv_backgrounddetect.c apps/app_nv_backgrounddetect.c
---- apps/app_nv_backgrounddetect.c 1970-01-01 01:00:00.000000000 +0100
-+++ apps/app_nv_backgrounddetect.c 2010-02-10 22:09:40.118390386 +0000
-@@ -0,0 +1,325 @@
-+/*
-+ * Asterisk -- A telephony toolkit for Linux.
-+ *
-+ * Playback a file with audio detect
-+ *
-+ * Copyright (C) 2004-2005, Newman Telecom, Inc. and Newman Ventures, Inc.
-+ *
-+ * Justin Newman <jnewman@newmantelecom.com>
-+ *
-+ * We would like to thank Newman Ventures, Inc. for funding this
-+ * Asterisk project.
-+ *
-+ * Newman Ventures <info@newmanventures.com>
-+ *
-+ * Portions Copyright:
-+ * Copyright (C) 2001, Linux Support Services, Inc.
-+ * Copyright (C) 2004, Digium, Inc.
-+ *
-+ * Matthew Fredrickson <creslin@linux-support.net>
-+ * Mark Spencer <markster@digium.com>
-+ *
-+ * This program is free software, distributed under the terms of
-+ * the GNU General Public License
-+ */
-+
-+#include "asterisk.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/utils.h>
-+#include <asterisk/dsp.h>
-+
-+static char *app = "NVBackgroundDetect";
-+
-+static char *synopsis = "Background a file with talk and fax detect (IAX and SIP too)";
-+
-+static char *descrip =
-+" NVBackgroundDetect(filename[|options[|sildur[|mindur|[maxdur]]]]):\n"
-+"Plays filename, waiting for interruption from fax tones (on IAX and SIP too),\n"
-+"a digit, or non-silence. Audio is monitored in the receive direction. If\n"
-+"digits interrupt, they must be the start of a valid extension unless the\n"
-+"option is included to ignore. If fax is detected, it will jump to the\n"
-+"'fax' extension. If a period of non-silence is greater than 'mindur' ms,\n"
-+"yet less than 'maxdur' ms is followed by silence at least 'sildur' ms\n"
-+"then the app is aborted and processing jumps to the 'talk' extension.\n"
-+"If all undetected, control will continue at the next priority.\n"
-+" options:\n"
-+" 'n': Attempt on-hook if unanswered (default=no)\n"
-+" 'x': DTMF digits terminate without extension (default=no)\n"
-+" 'd': Ignore DTMF digit detection (default=no)\n"
-+" 'f': Ignore fax detection (default=no)\n"
-+" 't': Ignore talk detection (default=no)\n"
-+" sildur: Silence ms after mindur/maxdur before aborting (default=1000)\n"
-+" mindur: Minimum non-silence ms needed (default=100)\n"
-+" maxdur: Maximum non-silence ms allowed (default=0/forever)\n"
-+"Returns -1 on hangup, and 0 on successful completion with no exit conditions.\n\n"
-+"For questions or comments, please e-mail support@newmantelecom.com.\n";
-+
-+// Use the second one for recent Asterisk releases
-+#define CALLERID_FIELD cid.cid_num
-+//#define CALLERID_FIELD callerid
-+
-+static int nv_background_detect_exec(struct ast_channel *chan, void *data)
-+{
-+ int res = 0;
-+ char tmp[256] = "\0";
-+ char *p = NULL;
-+ char *filename = NULL;
-+ char *options = NULL;
-+ char *silstr = NULL;
-+ char *minstr = NULL;
-+ char *maxstr = NULL;
-+ struct ast_frame *fr = NULL;
-+ struct ast_frame *fr2 = NULL;
-+ int notsilent = 0;
-+ struct timeval start = {0, 0}, end = {0, 0};
-+ int sildur = 1000;
-+ int mindur = 100;
-+ int maxdur = -1;
-+ int skipanswer = 0;
-+ int noextneeded = 0;
-+ int ignoredtmf = 0;
-+ int ignorefax = 0;
-+ int ignoretalk = 0;
-+ int x = 0;
-+ int origrformat = 0;
-+ int features = 0;
-+ struct ast_dsp *dsp = NULL;
-+
-+ pbx_builtin_setvar_helper(chan, "FAX_DETECTED", "");
-+ pbx_builtin_setvar_helper(chan, "FAXEXTEN", "");
-+ pbx_builtin_setvar_helper(chan, "DTMF_DETECTED", "");
-+ pbx_builtin_setvar_helper(chan, "TALK_DETECTED", "");
-+
-+ if (!data || ast_strlen_zero((char *)data)) {
-+ ast_log(LOG_WARNING, "NVBackgroundDetect requires an argument (filename)\n");
-+ return -1;
-+ }
-+
-+ strncpy(tmp, (char *)data, sizeof(tmp)-1);
-+ p = tmp;
-+
-+ filename = strsep(&p, "|");
-+ options = strsep(&p, "|");
-+ silstr = strsep(&p, "|");
-+ minstr = strsep(&p, "|");
-+ maxstr = strsep(&p, "|");
-+
-+ if (options) {
-+ if (strchr(options, 'n'))
-+ skipanswer = 1;
-+ if (strchr(options, 'x'))
-+ noextneeded = 1;
-+ if (strchr(options, 'd'))
-+ ignoredtmf = 1;
-+ if (strchr(options, 'f'))
-+ ignorefax = 1;
-+ if (strchr(options, 't'))
-+ ignoretalk = 1;
-+ }
-+
-+ if (silstr) {
-+ if ((sscanf(silstr, "%d", &x) == 1) && (x > 0))
-+ sildur = x;
-+ }
-+
-+ if (minstr) {
-+ if ((sscanf(minstr, "%d", &x) == 1) && (x > 0))
-+ mindur = x;
-+ }
-+
-+ if (maxstr) {
-+ if ((sscanf(maxstr, "%d", &x) == 1) && (x > 0))
-+ maxdur = x;
-+ }
-+
-+ ast_log(LOG_DEBUG, "Preparing detect of '%s' (sildur=%dms, mindur=%dms, maxdur=%dms)\n",
-+ tmp, sildur, mindur, maxdur);
-+
-+ // LOCAL_USER_ADD(u);
-+ if (chan->_state != AST_STATE_UP && !skipanswer) {
-+ /* Otherwise answer unless we're supposed to send this while on-hook */
-+ res = ast_answer(chan);
-+ }
-+ if (!res) {
-+ origrformat = chan->readformat;
-+ if ((res = ast_set_read_format(chan, AST_FORMAT_SLINEAR)))
-+ ast_log(LOG_WARNING, "Unable to set read format to linear!\n");
-+ }
-+ if (!(dsp = ast_dsp_new())) {
-+ ast_log(LOG_WARNING, "Unable to allocate DSP!\n");
-+ res = -1;
-+ }
-+
-+ if (dsp) {
-+ if (!ignoretalk)
-+ ; /* features |= DSP_FEATURE_SILENCE_SUPPRESS; */
-+ if (!ignorefax)
-+ features |= DSP_FEATURE_FAX_DETECT;
-+ //if (!ignoredtmf)
-+ features |= DSP_FEATURE_DIGIT_DETECT;
-+
-+ ast_dsp_set_threshold(dsp, 256);
-+ ast_dsp_set_features(dsp, features | DSP_DIGITMODE_RELAXDTMF);
-+ ast_dsp_set_digitmode(dsp, DSP_DIGITMODE_DTMF);
-+ }
-+
-+ if (!res) {
-+ ast_stopstream(chan);
-+ res = ast_streamfile(chan, tmp, chan->language);
-+ if (!res) {
-+ while(chan->stream) {
-+ res = ast_sched_wait(chan->sched);
-+ if ((res < 0) && !chan->timingfunc) {
-+ res = 0;
-+ break;
-+ }
-+ if (res < 0)
-+ res = 1000;
-+ res = ast_waitfor(chan, res);
-+ if (res < 0) {
-+ ast_log(LOG_WARNING, "Waitfor failed on %s\n", chan->name);
-+ break;
-+ } else if (res > 0) {
-+ fr = ast_read(chan);
-+ if (!fr) {
-+ ast_log(LOG_DEBUG, "Got hangup\n");
-+ res = -1;
-+ break;
-+ }
-+
-+ fr2 = ast_dsp_process(chan, dsp, fr);
-+ if (!fr2) {
-+ ast_log(LOG_WARNING, "Bad DSP received (what happened!!)\n");
-+ fr2 = fr;
-+ }
-+
-+ if (fr2->frametype == AST_FRAME_DTMF) {
-+ if (fr2->subclass == 'f' && !ignorefax) {
-+ /* Fax tone -- Handle and return NULL */
-+ ast_log(LOG_DEBUG, "Fax detected on %s\n", chan->name);
-+ if (strcmp(chan->exten, "fax")) {
-+ ast_log(LOG_NOTICE, "Redirecting %s to fax extension\n", chan->name);
-+ pbx_builtin_setvar_helper(chan, "FAX_DETECTED", "1");
-+ pbx_builtin_setvar_helper(chan,"FAXEXTEN",chan->exten);
-+ if (ast_exists_extension(chan, chan->context, "fax", 1, chan->CALLERID_FIELD)) {
-+ /* Save the DID/DNIS when we transfer the fax call to a "fax" extension */
-+ strncpy(chan->exten, "fax", sizeof(chan->exten)-1);
-+ chan->priority = 0;
-+ } else
-+ ast_log(LOG_WARNING, "Fax detected, but no fax extension\n");
-+ } else
-+ ast_log(LOG_WARNING, "Already in a fax extension, not redirecting\n");
-+
-+ res = 0;
-+ ast_frfree(fr);
-+ break;
-+ } else if (!ignoredtmf) {
-+ ast_log(LOG_DEBUG, "DTMF detected on %s\n", chan->name);
-+ char t[2];
-+ t[0] = fr2->subclass;
-+ t[1] = '\0';
-+ if (noextneeded || ast_canmatch_extension(chan, chan->context, t, 1, chan->CALLERID_FIELD)) {
-+ pbx_builtin_setvar_helper(chan, "DTMF_DETECTED", "1");
-+ /* They entered a valid extension, or might be anyhow */
-+ if (noextneeded) {
-+ ast_log(LOG_NOTICE, "DTMF received (not matching to exten)\n");
-+ res = 0;
-+ } else {
-+ ast_log(LOG_NOTICE, "DTMF received (matching to exten)\n");
-+ res = fr2->subclass;
-+ }
-+ ast_frfree(fr);
-+ break;
-+ } else
-+ ast_log(LOG_DEBUG, "Valid extension requested and DTMF did not match\n");
-+ }
-+ } else if ((fr->frametype == AST_FRAME_VOICE) && (fr->subclass == AST_FORMAT_SLINEAR) && !ignoretalk) {
-+ int totalsilence;
-+ int ms;
-+ res = ast_dsp_silence(dsp, fr, &totalsilence);
-+ if (res && (totalsilence > sildur)) {
-+ /* We've been quiet a little while */
-+ if (notsilent) {
-+ /* We had heard some talking */
-+ gettimeofday(&end, NULL);
-+ ms = (end.tv_sec - start.tv_sec) * 1000;
-+ ms += (end.tv_usec - start.tv_usec) / 1000;
-+ ms -= sildur;
-+ if (ms < 0)
-+ ms = 0;
-+ if ((ms > mindur) && ((maxdur < 0) || (ms < maxdur))) {
-+ char ms_str[10];
-+ ast_log(LOG_DEBUG, "Found qualified token of %d ms\n", ms);
-+ ast_log(LOG_NOTICE, "Redirecting %s to talk extension\n", chan->name);
-+
-+ /* Save detected talk time (in milliseconds) */
-+ sprintf(ms_str, "%d", ms);
-+ pbx_builtin_setvar_helper(chan, "TALK_DETECTED", ms_str);
-+
-+ if (ast_exists_extension(chan, chan->context, "talk", 1, chan->CALLERID_FIELD)) {
-+ strncpy(chan->exten, "talk", sizeof(chan->exten) - 1);
-+ chan->priority = 0;
-+ } else
-+ ast_log(LOG_WARNING, "Talk detected, but no talk extension\n");
-+ res = 0;
-+ ast_frfree(fr);
-+ break;
-+ } else
-+ ast_log(LOG_DEBUG, "Found unqualified token of %d ms\n", ms);
-+ notsilent = 0;
-+ }
-+ } else {
-+ if (!notsilent) {
-+ /* Heard some audio, mark the begining of the token */
-+ gettimeofday(&start, NULL);
-+ ast_log(LOG_DEBUG, "Start of voice token!\n");
-+ notsilent = 1;
-+ }
-+ }
-+ }
-+ ast_frfree(fr);
-+ }
-+ ast_sched_runq(chan->sched);
-+ }
-+ ast_stopstream(chan);
-+ } else {
-+ ast_log(LOG_WARNING, "ast_streamfile failed on %s for %s\n", chan->name, (char *)data);
-+ res = 0;
-+ }
-+ } else
-+ ast_log(LOG_WARNING, "Could not answer channel '%s'\n", chan->name);
-+
-+ if (res > -1) {
-+ if (origrformat && ast_set_read_format(chan, origrformat)) {
-+ ast_log(LOG_WARNING, "Failed to restore read format for %s to %s\n",
-+ chan->name, ast_getformatname(origrformat));
-+ }
-+ }
-+
-+ if (dsp)
-+ ast_dsp_free(dsp);
-+
-+ // LOCAL_USER_REMOVE(u);
-+
-+ return res;
-+}
-+
-+static int unload_module(void)
-+{
-+ // STANDARD_HANGUP_LOCALUSERS;
-+ return ast_unregister_application(app);
-+}
-+
-+static int load_module(void)
-+{
-+ return ast_register_application(app, nv_background_detect_exec, synopsis, descrip);
-+}
-+
-+AST_MODULE_INFO_STANDARD(ASTERISK_GPL_KEY, "Fax playing Background Music Detection Application");
-diff -uNr apps/app_nv_faxdetect.c apps/app_nv_faxdetect.c
---- apps/app_nv_faxdetect.c 1970-01-01 01:00:00.000000000 +0100
-+++ apps/app_nv_faxdetect.c 2010-02-10 22:09:40.119390638 +0000
-@@ -0,0 +1,317 @@
-+/*
-+ * Asterisk -- A telephony toolkit for Linux.
-+ *
-+ * Fax detection application for all channel types.
-+ *
-+ * Copyright (C) 2004-2005, Newman Telecom, Inc. and Newman Ventures, Inc.
-+ *
-+ * Justin Newman <jnewman@newmantelecom.com>
-+ *
-+ * We would like to thank Newman Ventures, Inc. for funding this
-+ * Asterisk project.
-+ *
-+ * Newman Ventures <info@newmanventures.com>
-+ *
-+ * Portions Copyright:
-+ * Copyright (C) 2001, Linux Support Services, Inc.
-+ * Copyright (C) 2004, Digium, Inc.
-+ *
-+ * Matthew Fredrickson <creslin@linux-support.net>
-+ * Mark Spencer <markster@digium.com>
-+ *
-+ * This program is free software, distributed under the terms of
-+ * the GNU General Public License
-+ */
-+
-+#include "asterisk.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/utils.h>
-+
-+static char *app = "NVFaxDetect";
-+
-+static char *synopsis = "Detects fax sounds on all channel types (IAX and SIP too)";
-+
-+static char *descrip =
-+" NVFaxDetect([waitdur[|options[|sildur[|mindur[|maxdur]]]]]):\n"
-+"This application listens for fax tones (on IAX and SIP channels too)\n"
-+"for waitdur seconds of time. In addition, it can be interrupted by digits,\n"
-+"or non-silence. Audio is only monitored in the receive direction. If\n"
-+"digits interrupt, they must be the start of a valid extension unless the\n"
-+"option is included to ignore. If fax is detected, it will jump to the\n"
-+"'fax' extension. If a period of non-silence greater than 'mindur' ms,\n"
-+"yet less than 'maxdur' ms is followed by silence at least 'sildur' ms\n"
-+"then the app is aborted and processing jumps to the 'talk' extension.\n"
-+"If all undetected, control will continue at the next priority.\n"
-+" waitdur: Maximum number of seconds to wait (default=4)\n"
-+" options:\n"
-+" 'n': Attempt on-hook if unanswered (default=no)\n"
-+" 'x': DTMF digits terminate without extension (default=no)\n"
-+" 'd': Ignore DTMF digit detection (default=no)\n"
-+" 'f': Ignore fax detection (default=no)\n"
-+" 't': Ignore talk detection (default=no)\n"
-+" sildur: Silence ms after mindur/maxdur before aborting (default=1000)\n"
-+" mindur: Minimum non-silence ms needed (default=100)\n"
-+" maxdur: Maximum non-silence ms allowed (default=0/forever)\n"
-+"Returns -1 on hangup, and 0 on successful completion with no exit conditions.\n\n"
-+"For questions or comments, please e-mail support@newmantelecom.com.\n";
-+
-+// Use the second one for recent Asterisk releases
-+#define CALLERID_FIELD cid.cid_num
-+//#define CALLERID_FIELD callerid
-+
-+static int nv_detectfax_exec(struct ast_channel *chan, void *data)
-+{
-+ int res = 0;
-+ char tmp[256] = "\0";
-+ char *p = NULL;
-+ char *waitstr = NULL;
-+ char *options = NULL;
-+ char *silstr = NULL;
-+ char *minstr = NULL;
-+ char *maxstr = NULL;
-+ struct ast_frame *fr = NULL;
-+ struct ast_frame *fr2 = NULL;
-+ int notsilent = 0;
-+ struct timeval start = {0, 0}, end = {0, 0};
-+ int waitdur = 4;
-+ int sildur = 1000;
-+ int mindur = 100;
-+ int maxdur = -1;
-+ int skipanswer = 0;
-+ int noextneeded = 0;
-+ int ignoredtmf = 0;
-+ int ignorefax = 0;
-+ int ignoretalk = 0;
-+ int x = 0;
-+ int origrformat = 0;
-+ int features = 0;
-+ time_t timeout = 0;
-+ struct ast_dsp *dsp = NULL;
-+
-+ pbx_builtin_setvar_helper(chan, "FAX_DETECTED", "");
-+ pbx_builtin_setvar_helper(chan, "FAXEXTEN", "");
-+ pbx_builtin_setvar_helper(chan, "DTMF_DETECTED", "");
-+ pbx_builtin_setvar_helper(chan, "TALK_DETECTED", "");
-+
-+ if (data || !ast_strlen_zero((char *)data)) {
-+ strncpy(tmp, (char *)data, sizeof(tmp)-1);
-+ }
-+
-+ p = tmp;
-+
-+ waitstr = strsep(&p, "|");
-+ options = strsep(&p, "|");
-+ silstr = strsep(&p, "|");
-+ minstr = strsep(&p, "|");
-+ maxstr = strsep(&p, "|");
-+
-+ if (waitstr) {
-+ if ((sscanf(waitstr, "%d", &x) == 1) && (x > 0))
-+ waitdur = x;
-+ }
-+
-+ if (options) {
-+ if (strchr(options, 'n'))
-+ skipanswer = 1;
-+ if (strchr(options, 'x'))
-+ noextneeded = 1;
-+ if (strchr(options, 'd'))
-+ ignoredtmf = 1;
-+ if (strchr(options, 'f'))
-+ ignorefax = 1;
-+ if (strchr(options, 't'))
-+ ignoretalk = 1;
-+ }
-+
-+ if (silstr) {
-+ if ((sscanf(silstr, "%d", &x) == 1) && (x > 0))
-+ sildur = x;
-+ }
-+
-+ if (minstr) {
-+ if ((sscanf(minstr, "%d", &x) == 1) && (x > 0))
-+ mindur = x;
-+ }
-+
-+ if (maxstr) {
-+ if ((sscanf(maxstr, "%d", &x) == 1) && (x > 0))
-+ maxdur = x;
-+ }
-+
-+ ast_log(LOG_DEBUG, "Preparing detect of fax (waitdur=%dms, sildur=%dms, mindur=%dms, maxdur=%dms)\n",
-+ waitdur, sildur, mindur, maxdur);
-+
-+ // LOCAL_USER_ADD(u);
-+ if (chan->_state != AST_STATE_UP && !skipanswer) {
-+ /* Otherwise answer unless we're supposed to send this while on-hook */
-+ res = ast_answer(chan);
-+ }
-+ if (!res) {
-+ origrformat = chan->readformat;
-+ if ((res = ast_set_read_format(chan, AST_FORMAT_SLINEAR)))
-+ ast_log(LOG_WARNING, "Unable to set read format to linear!\n");
-+ }
-+ if (!(dsp = ast_dsp_new())) {
-+ ast_log(LOG_WARNING, "Unable to allocate DSP!\n");
-+ res = -1;
-+ }
-+
-+ if (dsp) {
-+ if (!ignoretalk)
-+ ; /* features |= DSP_FEATURE_SILENCE_SUPPRESS; */
-+ if (!ignorefax)
-+ features |= DSP_FEATURE_FAX_DETECT;
-+ //if (!ignoredtmf)
-+ features |= DSP_FEATURE_DIGIT_DETECT;
-+
-+ ast_dsp_set_threshold(dsp, 256);
-+ ast_dsp_set_features(dsp, features | DSP_DIGITMODE_RELAXDTMF);
-+ ast_dsp_set_digitmode(dsp, DSP_DIGITMODE_DTMF);
-+ }
-+
-+ if (!res) {
-+ if (waitdur > 0)
-+ timeout = time(NULL) + (time_t)waitdur;
-+
-+ while(ast_waitfor(chan, -1) > -1) {
-+ if (waitdur > 0 && time(NULL) > timeout) {
-+ res = 0;
-+ break;
-+ }
-+
-+ fr = ast_read(chan);
-+ if (!fr) {
-+ ast_log(LOG_DEBUG, "Got hangup\n");
-+ res = -1;
-+ break;
-+ }
-+
-+ fr2 = ast_dsp_process(chan, dsp, fr);
-+ if (!fr2) {
-+ ast_log(LOG_WARNING, "Bad DSP received (what happened?)\n");
-+ fr2 = fr;
-+ }
-+
-+ if (fr2->frametype == AST_FRAME_DTMF) {
-+ if (fr2->subclass == 'f' && !ignorefax) {
-+ /* Fax tone -- Handle and return NULL */
-+ ast_log(LOG_DEBUG, "Fax detected on %s\n", chan->name);
-+ if (strcmp(chan->exten, "fax")) {
-+ ast_log(LOG_NOTICE, "Redirecting %s to fax extension\n", chan->name);
-+ pbx_builtin_setvar_helper(chan, "FAX_DETECTED", "1");
-+ pbx_builtin_setvar_helper(chan,"FAXEXTEN",chan->exten);
-+ if (ast_exists_extension(chan, chan->context, "fax", 1, chan->CALLERID_FIELD)) {
-+ /* Save the DID/DNIS when we transfer the fax call to a "fax" extension */
-+ strncpy(chan->exten, "fax", sizeof(chan->exten)-1);
-+ chan->priority = 0;
-+ } else
-+ ast_log(LOG_WARNING, "Fax detected, but no fax extension\n");
-+ } else
-+ ast_log(LOG_WARNING, "Already in a fax extension, not redirecting\n");
-+
-+ res = 0;
-+ ast_frfree(fr);
-+ break;
-+ } else if (!ignoredtmf) {
-+ ast_log(LOG_DEBUG, "DTMF detected on %s\n", chan->name);
-+ char t[2];
-+ t[0] = fr2->subclass;
-+ t[1] = '\0';
-+ if (noextneeded || ast_canmatch_extension(chan, chan->context, t, 1, chan->CALLERID_FIELD)) {
-+ pbx_builtin_setvar_helper(chan, "DTMF_DETECTED", "1");
-+ /* They entered a valid extension, or might be anyhow */
-+ if (noextneeded) {
-+ ast_log(LOG_NOTICE, "DTMF received (not matching to exten)\n");
-+ res = 0;
-+ } else {
-+ ast_log(LOG_NOTICE, "DTMF received (matching to exten)\n");
-+ res = fr2->subclass;
-+ }
-+ ast_frfree(fr);
-+ break;
-+ } else
-+ ast_log(LOG_DEBUG, "Valid extension requested and DTMF did not match\n");
-+ }
-+ } else if ((fr->frametype == AST_FRAME_VOICE) && (fr->subclass == AST_FORMAT_SLINEAR) && !ignoretalk) {
-+ int totalsilence;
-+ int ms;
-+ res = ast_dsp_silence(dsp, fr, &totalsilence);
-+ if (res && (totalsilence > sildur)) {
-+ /* We've been quiet a little while */
-+ if (notsilent) {
-+ /* We had heard some talking */
-+ gettimeofday(&end, NULL);
-+ ms = (end.tv_sec - start.tv_sec) * 1000;
-+ ms += (end.tv_usec - start.tv_usec) / 1000;
-+ ms -= sildur;
-+ if (ms < 0)
-+ ms = 0;
-+ if ((ms > mindur) && ((maxdur < 0) || (ms < maxdur))) {
-+ char ms_str[10];
-+ ast_log(LOG_DEBUG, "Found qualified token of %d ms\n", ms);
-+ ast_log(LOG_NOTICE, "Redirecting %s to talk extension\n", chan->name);
-+
-+ /* Save detected talk time (in milliseconds) */
-+ sprintf(ms_str, "%d", ms);
-+ pbx_builtin_setvar_helper(chan, "TALK_DETECTED", ms_str);
-+
-+ if (ast_exists_extension(chan, chan->context, "talk", 1, chan->CALLERID_FIELD)) {
-+ strncpy(chan->exten, "talk", sizeof(chan->exten) - 1);
-+ chan->priority = 0;
-+ } else
-+ ast_log(LOG_WARNING, "Talk detected, but no talk extension\n");
-+ res = 0;
-+ ast_frfree(fr);
-+ break;
-+ } else
-+ ast_log(LOG_DEBUG, "Found unqualified token of %d ms\n", ms);
-+ notsilent = 0;
-+ }
-+ } else {
-+ if (!notsilent) {
-+ /* Heard some audio, mark the begining of the token */
-+ gettimeofday(&start, NULL);
-+ ast_log(LOG_DEBUG, "Start of voice token!\n");
-+ notsilent = 1;
-+ }
-+ }
-+ }
-+ ast_frfree(fr);
-+ }
-+ } else
-+ ast_log(LOG_WARNING, "Could not answer channel '%s'\n", chan->name);
-+
-+ if (res > -1) {
-+ if (origrformat && ast_set_read_format(chan, origrformat)) {
-+ ast_log(LOG_WARNING, "Failed to restore read format for %s to %s\n",
-+ chan->name, ast_getformatname(origrformat));
-+ }
-+ }
-+
-+ if (dsp)
-+ ast_dsp_free(dsp);
-+
-+ // LOCAL_USER_REMOVE(u);
-+
-+ return res;
-+}
-+
-+static int unload_module(void)
-+{
-+ return ast_unregister_application(app);
-+}
-+
-+static int load_module(void)
-+{
-+ return ast_register_application(app, nv_detectfax_exec, synopsis, descrip);
-+}
-+
-+AST_MODULE_INFO_STANDARD(ASTERISK_GPL_KEY, "Fax Detection Application");
diff --git a/net-misc/asterisk/files/1.6.2/asterisk-1.6.2.8-inband-indications.patch b/net-misc/asterisk/files/1.6.2/asterisk-1.6.2.8-inband-indications.patch
deleted file mode 100644
index c8d409584263..000000000000
--- a/net-misc/asterisk/files/1.6.2/asterisk-1.6.2.8-inband-indications.patch
+++ /dev/null
@@ -1,20 +0,0 @@
---- asterisk-1.6.2.8-orig/main/channel.c 2010-06-06 10:04:33.439148782 +0200
-+++ asterisk-1.6.2.8/main/channel.c 2010-06-06 10:05:51.124146954 +0200
-@@ -2014,6 +2014,8 @@
- chan->generator->release(chan, chan->generatordata);
- chan->generatordata = NULL;
- }
-+
-+ ast_prod(chan);
- if (gen->alloc && !(chan->generatordata = gen->alloc(chan, params))) {
- res = -1;
- }
-@@ -2023,8 +2025,6 @@
- }
- ast_channel_unlock(chan);
-
-- ast_prod(chan);
--
- return res;
- }
-
diff --git a/net-misc/asterisk/files/1.6.2/asterisk-1.6.2.8-pri-missing-keyword.patch b/net-misc/asterisk/files/1.6.2/asterisk-1.6.2.8-pri-missing-keyword.patch
deleted file mode 100644
index 60cde9785d88..000000000000
--- a/net-misc/asterisk/files/1.6.2/asterisk-1.6.2.8-pri-missing-keyword.patch
+++ /dev/null
@@ -1,12 +0,0 @@
-diff -uNr asterisk-1.6.2.8.ORIG/include/asterisk/autoconfig.h.in asterisk-1.6.2.8/include/asterisk/autoconfig.h.in
---- asterisk-1.6.2.8.ORIG/include/asterisk/autoconfig.h.in 2009-09-29 09:53:36.000000000 +0200
-+++ asterisk-1.6.2.8/include/asterisk/autoconfig.h.in 2009-09-29 2009-09-29 09:53:36.000000000 +0200
-@@ -620,6 +620,8 @@
- /* Define to 1 if you have the ISDN PRI library. */
- #undef HAVE_PRI
-
-+#undef HAVE_PRI_PROG_W_CAUSE
-+
- /* Define to 1 if you have the ISDN PRI set_inbanddisconnect library. */
- #undef HAVE_PRI_INBANDDISCONNECT
-
diff --git a/net-misc/asterisk/files/1.6.2/asterisk-1.6.2.9-gsm-pic.patch b/net-misc/asterisk/files/1.6.2/asterisk-1.6.2.9-gsm-pic.patch
deleted file mode 100644
index df85382f0df0..000000000000
--- a/net-misc/asterisk/files/1.6.2/asterisk-1.6.2.9-gsm-pic.patch
+++ /dev/null
@@ -1,64 +0,0 @@
-diff -uNr asterisk-1.6.2.9.ORIG/codecs/gsm/Makefile asterisk-1.6.2.9/codecs/gsm/Makefile
---- asterisk-1.6.2.9.ORIG/codecs/gsm/Makefile 2010-03-09 21:39:20.000000000 +0100
-+++ asterisk-1.6.2.9/codecs/gsm/Makefile 2010-03-09 21:39:20.000000000 +0100
-@@ -37,30 +37,6 @@
- ######### ppro's, etc, as well as the AMD K6 and K7. The compile will
- ######### probably require gcc.
-
--ifeq (,$(findstring $(OSARCH),Darwin SunOS))
-- ifeq (,$(strip $(findstring $(PROC) ,"x86_64 amd64 ultrasparc sparc64 arm armv5b armeb ppc powerpc ppc64 ia64 s390 bfin mipsel mips ")))
-- ifeq (,$(strip $(findstring $(shell uname -m) ,"ppc ppc64 alpha armv4l s390 ")))
-- OPTIMIZE+=-march=$(PROC)
-- endif
-- endif
--else
-- ifneq (,$(findstring $(OSARCH),Darwin))
-- ifeq ($(shell /usr/bin/sw_vers -productVersion | cut -c1-4),10.6)
-- # Snow Leopard reports i386, even though it's really x86_64
-- OPTIMIZE+=-mtune=native
-- endif
-- endif
--endif
--
--#The problem with sparc is the best stuff is in newer versions of gcc (post 3.0) only.
--#This works for even old (2.96) versions of gcc and provides a small boost either way.
--#A ultrasparc cpu is really v9 but the stock debian stable 3.0 gcc doesn't support it.
--#So we go lowest common available by gcc and go a step down, still a step up from
--#the default as we now have a better instruction set to work with. - Belgarath
--ifeq ($(PROC),ultrasparc)
--OPTIMIZE+=-mcpu=v8 -mtune=$(PROC) -O3
--endif
--
- PG =
- #PG = -g -pg
- ######### Profiling flags. If you don't know what that means, leave it blank.
-@@ -215,11 +191,9 @@
- # XXX Keep a space after each findstring argument
- # XXX should merge with GSM_OBJECTS
- ifeq ($(OSARCH),linux-gnu)
--ifeq (,$(findstring $(shell uname -m) , x86_64 amd64 ppc ppc64 alpha armv4l sparc64 parisc s390 ))
--ifeq (,$(findstring $(PROC) , arm armv5b armeb powerpc ia64 s390 bfin mipsel mips ))
--GSM_SOURCES+= $(SRC)/k6opt.s
--endif
--endif
-+ ifneq ($(K6OPT),)
-+ GSM_SOURCES+= $(SRC)/k6opt.s
-+ endif
- endif
-
- TOAST_SOURCES = $(SRC)/toast.c \
-@@ -267,11 +241,9 @@
- $(SRC)/table.o
-
- ifeq ($(OSARCH),linux-gnu)
--ifeq (,$(findstring $(shell uname -m) , x86_64 amd64 ppc ppc64 alpha armv4l sparc64 parisc ))
--ifeq (,$(findstring $(PROC) , arm armv5b armeb powerpc ia64 bfin mipsel mips ))
--GSM_OBJECTS+= $(SRC)/k6opt.o
--endif
--endif
-+ ifneq ($(K6OPT),)
-+ GSM_OBJECTS+= $(SRC)/k6opt.o
-+ endif
- endif
-
- TOAST_OBJECTS = $(SRC)/toast.o \