summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTony Vroon <chainsaw@gentoo.org>2013-05-20 20:31:28 +0000
committerTony Vroon <chainsaw@gentoo.org>2013-05-20 20:31:28 +0000
commitab69adb0b9d44e937a2ad13e5a431db63c24b9eb (patch)
tree84bcd0982dfbcbc647c4ba7854b647e5292cc39d /net-misc/asterisk
parentVersion bump (diff)
downloadhistorical-ab69adb0b9d44e937a2ad13e5a431db63c24b9eb.tar.gz
historical-ab69adb0b9d44e937a2ad13e5a431db63c24b9eb.tar.bz2
historical-ab69adb0b9d44e937a2ad13e5a431db63c24b9eb.zip
In a refreshing change of heart, upstream now care about parallel build failures. Drop our relevant two downstream patches. Fixes a res_timing_pthread deadlock, an FD leak in the web server and more SRTP decryption/white noise issues.
Package-Manager: portage-2.1.12.1/cvs/Linux x86_64 Manifest-Sign-Key: 0xB5058F9A
Diffstat (limited to 'net-misc/asterisk')
-rw-r--r--net-misc/asterisk/ChangeLog10
-rw-r--r--net-misc/asterisk/Manifest13
-rw-r--r--net-misc/asterisk/asterisk-11.4.0.ebuild308
3 files changed, 325 insertions, 6 deletions
diff --git a/net-misc/asterisk/ChangeLog b/net-misc/asterisk/ChangeLog
index 4652217f08f5..87f0182d823c 100644
--- a/net-misc/asterisk/ChangeLog
+++ b/net-misc/asterisk/ChangeLog
@@ -1,6 +1,14 @@
# ChangeLog for net-misc/asterisk
# Copyright 1999-2013 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/net-misc/asterisk/ChangeLog,v 1.451 2013/03/30 13:13:13 chainsaw Exp $
+# $Header: /var/cvsroot/gentoo-x86/net-misc/asterisk/ChangeLog,v 1.452 2013/05/20 20:31:13 chainsaw Exp $
+
+*asterisk-11.4.0 (20 May 2013)
+
+ 20 May 2013; Tony Vroon <chainsaw@gentoo.org> +asterisk-11.4.0.ebuild:
+ In a refreshing change of heart, upstream now care about parallel build
+ failures. Drop our relevant two downstream patches. Fixes a
+ res_timing_pthread deadlock, an FD leak in the web server and more SRTP
+ decryption/white noise issues.
30 Mar 2013; Tony Vroon <chainsaw@gentoo.org> -asterisk-1.8.20.1.ebuild,
-asterisk-11.2.1.ebuild:
diff --git a/net-misc/asterisk/Manifest b/net-misc/asterisk/Manifest
index 72f1e86af43d..9e2c574988fc 100644
--- a/net-misc/asterisk/Manifest
+++ b/net-misc/asterisk/Manifest
@@ -16,20 +16,23 @@ DIST asterisk-1.8.20.2.tar.gz 25180212 SHA256 67d9cb7f569d49bfdbd94f6d81b13bac69
DIST asterisk-1.8.21.0.tar.gz 25334905 SHA256 5f7ae7ac26eaedb6b7274281073a6b469157eaf4b8fd7e69bd0880125cea3380 SHA512 034b87c9adc24b5f6997d70f8a7279de5f15087d44af622630a148deeb1e74cc999ad171eb4ae4e551505ada02b6eea422ba0e29510a0f0ecc9fcb8e9c5d03b9 WHIRLPOOL f00b5eefc4ab7299d25314faa7527a6ce198e391615973c37e9eae54458b3c535a124da5594f0748c948cb2c8c69d6f1b654766f17402d1435dd1738332d6ca5
DIST asterisk-11.2.2.tar.gz 30468125 SHA256 b470a27745735a49e83dc9842ec892c9b4ab186e5d44db68ea1db66e6c684c7b SHA512 3da0aaf03d4f172e8995021790b166a2182bc09cdd8d38777c4a8dcad7e105edde9a2cead511cd09504a7aac559c7b225aca69990bb9802d6eba70ff49dd0375 WHIRLPOOL e1a36fb7c5c6d6746e67c9cfd0db8eab829ee9c2770b5bc14f71f3686c3a8fb2f8aac3e2660ad455cf403e7f9d51d23a1a81042c44ced5f97f60ae8827c7740a
DIST asterisk-11.3.0.tar.gz 30629838 SHA256 35b7dd5d21449384ebcab631915a844d631676ff6535a6c14bd2bac819808f09 SHA512 a617224db67c5d108d4edad5a8325cb6c1010104e820572a7100417f10def422981f181f50ef694f3ffacd8d3564d81daa9e07da342c8e03671de29a433a2238 WHIRLPOOL 1e2293a4e0a02cd2135a92eb55dfc4d15f76a832c663f3ed65cf44b4131ea923a7c77fabf26e216f354d88dc72181a632ccdf481d6edcf14ed430a3dd887d185
+DIST asterisk-11.4.0.tar.gz 30651949 SHA256 081ba8de5f349ff23de8e000d8cda38a2ca34858174e9379b2662a732557e9d4 SHA512 482ad6a252d8b660b01b5eb5d9cdff86289a8eb8bdc7f69f150441a612b6e0a3652ad237bfbbecc38602fa9b888d7dc8aa9011b23fbeb442ff93d3129eea773b WHIRLPOOL 645c391acfc87d6668f9bf1dcbd5182963c1da9c2c7d8fcd65d9f705225e703397315569017244662c15da5c5c12ecb10ce4fc4b1a6b3ce6cefd0ec4775b1b76
DIST gentoo-asterisk-patchset-1.17.tar.bz2 31552 SHA256 fa1c202a42a9b2b3c8e1f90df05f8c8e818688347ad62d38c1bd2daa69d58af4 SHA512 84d5cd12894f452a4f17f95531321f2e15f745391965f6351de5af52e2ac3b580c50552cf04d656f91fdc7db69c0ebd9e2cf210143f57c8a9fb0d2745477ce00 WHIRLPOOL 54c98f94acd95519087c4a6c62269c5f1c41a250eea4f9def40c01e968be6bc2b4e85cc18a16367a8af02c217a5088718e0bc0f55e03aebc29aa5247a2d03274
DIST gentoo-asterisk-patchset-3.4.tar.bz2 7600 SHA256 e2c1c84c7b1137ece368696d44a518ae58c877f51ae74d37aa76989fed1bb983 SHA512 62b196f7cda00318716dc09f8e8a895080721f362f6215062a564e66428aaeae987136ce84a1b82216d1ce51e77bf94c745f9e89579391ca2140eefc651de798 WHIRLPOOL d67aa57bea86524ec0f0caf9b720fef3d69eeba7e359f533dd48eee8ebb6a81f63ecdc7191b1ce05040a141e8a42059b1eb17f8a17966639eb2fe676ce129ff6
DIST gentoo-asterisk-patchset-3.5.tar.bz2 7277 SHA256 2d0487d9dba92253f2424ef7ab8a78688b2cae5f956482178992426f82a72278 SHA512 2355059d9c2c904e28b9580bd13c4b1edb6b6a6fc055ee7cf3ccac38c2a3d386759bc8d1a13e5573e38fa740d4c24e11e04914a930f813e05ca9b506750c42b1 WHIRLPOOL 95e96a2c6c430256cb81589f30ed42f8becafaefad57d908a58438bb98bbff7035efb071eb26658d402a09adbc71bba7062876d1da11fb2f3f3a56f8d5da8cda
+DIST gentoo-asterisk-patchset-3.6.tar.bz2 5930 SHA256 79083bd4d52c3f741b133fa55c956941f11e1e9754f67739a02a8a50f4b47842 SHA512 f8aedcdaa17ae18da7f463737908df1c8f1bcc53fd65cddbbf48f525d60de1abb5f6ee195f0e4b74a69fb20f7391194409b0814efc947c1800b2a1cd36786aae WHIRLPOOL 0c07c942117ad9b92b83aac4a5bac6c1f72aa49006e3dd538cdd893a0b5312ee6f8bc5512160fdbc530ed642dd2e07608ae3e0f9a99d8a5cbabd52b85afc343b
EBUILD asterisk-1.8.20.2.ebuild 8995 SHA256 c52bf38072f86306f04638453707d40170ddf787eb3f8f6e25cf9fd15081511c SHA512 d01fc10f4b13637e3ea7d069cebf6c614624d97190fdeed13a1dc3a7b62562609fb6f9409fe15a87c1f7e83648a587454bdafa081d1d18247780aafb3b29361c WHIRLPOOL 07c13e403ca4c66ebe933c0e4dc2d8bd4ec14247e7a53be8a20b60a17be1b37faa1c0c86ee1bbcd44dc68046b10b82ddc4e4573dcf1019409ed30b89c03ac11c
EBUILD asterisk-1.8.21.0.ebuild 9002 SHA256 95cbab229cc5cf5a9ac2369be38d520496dd55c935225c69de59c172bdbe7b10 SHA512 77e44ef042dd5b9b1d1af73902eb18df06db7e3cf380f5eb7c77dc428947aaa6f2f42c572b58b851e23684f00da303dad2c669973505fa027b599dd1862fe862 WHIRLPOOL bf45ab1aec4e719921cb493aa0ac2cad9aa831f55a51f319d2c7584dbdea884b8a9681b5eb7b0f8af1a0c9e2408df343b9cb2b0b2d53d469dabc3dfec0e6bb6b
EBUILD asterisk-11.2.2.ebuild 9088 SHA256 7e5df8654ea5356989b7b3e841edb7e56cfaa1ee8111da845d5308a5d900fcc3 SHA512 aba89563dd61d1e97ac5aa576c16bddfe6bc0bd1790925cdffc23a9617bcf479dc5eaaafcb6af2bdbca878c62596bce7d95d6bad90d73051aa8c9f7e49d4eb5e WHIRLPOOL db6e5999a54a44cfeb8f8e716276912b0005c9656d259cc453fc487a1d6cd330527f15248bed64bc2c0508246764b38078469dfe72a4f7f4eb48d388a17d3112
EBUILD asterisk-11.3.0.ebuild 9095 SHA256 10672f84cbf98b1bf57a3bba964a219f94fb52b67494e99a8ec41e82a42e6886 SHA512 85dc707c9387023b729283d10ff5bab289b26e7fd325b31bcf521f5900142fe6e724f82095187144c0b0e2f923cff43f53905a1f8874faa5038c01de03885911 WHIRLPOOL 88f928b39f65c436345920ec6a8c72a50544aa525a33a8da40320c2af844356c598503c80e5634c71bb2277e3b74f110044ae5accaf8f04e9f492ccc5dc77c94
-MISC ChangeLog 5726 SHA256 9f1857a14f8ebf63d426ebef5d2bb22f98509ca396362aa6cef6b734f33763c1 SHA512 fad9585662df22e663cd0dccff2cf889fbdbc928d20bdc974abba296e19f7d23a53b9cff4621f8a7c838319f4de63652bf678030b4eb72d985d2b77b7b7c8fc4 WHIRLPOOL b6cbb0a9833ea1fafdc227c0965797a5032ee2eae1befe65a33680a64ff2242e3169e570fc70d31e80d9e49387a54b8e57d0bc2b9dbcb245d1cacc20ba9293e1
+EBUILD asterisk-11.4.0.ebuild 9095 SHA256 e31800b3409d849d6b8d9f1afb5da0cebffd4125c9e21ad54a42e81d8738aeb1 SHA512 bca5e0d7e3acc3244f6b3b10d82be781636ca7b84a37ded2b0b546109cc1ccfc87fbd3f8309fe7c0e7a3d08e743405b67722343703549414935c14a85b156b3e WHIRLPOOL 378b8fc2889277859296ec0fa15f74214b2260dd9d7f72e8c5f40e2c7bd7a4e232d5ce1299103fd74b75209e38da12c5456fecb016f6d4d00f3deb2179f88586
+MISC ChangeLog 6075 SHA256 c43bf222b7ef52f35ae4fbcc6d9a225f980a09a9d2136782664bacf25047efe5 SHA512 701e90c50f162943b10b5bba413804ae48d1aa64624d41c258120948d7c55e8ef307bda7c6183138447ec2e495d9b9dad280c31cedbc37a973d5ccc72db52a7e WHIRLPOOL 92ae89ac4b38c8d47d876d7054851592389ccbe91423ba42324bec292a99d64a149c4676eca57b334c8f38143d22508e9e07b4fe91eca61679bfb5a33ba3c852
MISC ChangeLog-2012 113409 SHA256 6beb419f0c2e63641c73f2c14bd0c3a6a319c65bca8be526aa441fac2104fc9c SHA512 08c037acd578b9c3c387a80e45e80a68c4da84e63fced30215f22ec14eb6e223348d8e7d68f4decdf8a2d8cd0933b3f7fa3adddf7cd80bb407498b3e2868d917 WHIRLPOOL be0f2192531f7477545ccc0f10d9a50f36228e8d8d0e2773ccce3799c2d1b5e1b7be70d96502f759c7c878f88efd83122fc9230374c40c8963fe0bc7ff014b87
MISC metadata.xml 1203 SHA256 d5acdcd4f214e602c8d6b68258e4e7fa9071bd2fbda10d461f097d35d1f08c0a SHA512 4f65a7268834241af12d41b79da374cc65b977436ad182ea781b2677790da0d1573cc39fc2e9868a0acbaeceb529762cab385e16d9140a5246cafebd6e25e765 WHIRLPOOL d870297ef0b6f1f36a2f39cabb811c3a1845a305884ae7b2bc979cd35f96da04cc3030eb4593039aa0aaf206fe44845a37bbb5ac994085c1e67a422e2fdf0772
-----BEGIN PGP SIGNATURE-----
-Version: GnuPG v2.0.19 (GNU/Linux)
+Version: GnuPG v2.0.20 (GNU/Linux)
-iEYEAREIAAYFAlFW5PUACgkQp5vW4rUFj5qZQQCdEGEiKOtLte/ApdO0h+4v4ZwA
-WwQAn2F+RdciNDWh+28QHp+GW8bC4iMi
-=l3SO
+iEYEAREIAAYFAlGaiBMACgkQp5vW4rUFj5qR4QCeMcDOoh76UbdZ4r6BnR1v0a0q
+vGcAnRU/ys6orjeSwbU4TrNtIcuC3/Gp
+=hRB/
-----END PGP SIGNATURE-----
diff --git a/net-misc/asterisk/asterisk-11.4.0.ebuild b/net-misc/asterisk/asterisk-11.4.0.ebuild
new file mode 100644
index 000000000000..62cf0f5183fd
--- /dev/null
+++ b/net-misc/asterisk/asterisk-11.4.0.ebuild
@@ -0,0 +1,308 @@
+# Copyright 1999-2013 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/net-misc/asterisk/asterisk-11.4.0.ebuild,v 1.1 2013/05/20 20:31:13 chainsaw Exp $
+
+EAPI=5
+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
+ mirror://gentoo/gentoo-asterisk-patchset-3.6.tar.bz2"
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+
+IUSE_VOICEMAIL_STORAGE="
+ +voicemail_storage_file
+ voicemail_storage_odbc
+ voicemail_storage_imap
+"
+IUSE="${IUSE_VOICEMAIL_STORAGE} alsa bluetooth calendar +caps cluster curl dahdi debug doc freetds gtalk http iconv ilbc jabber ldap libedit lua mysql newt +samples odbc osplookup oss portaudio postgres radius selinux snmp span speex srtp static syslog vorbis"
+IUSE_EXPAND="VOICEMAIL_STORAGE"
+REQUIRED_USE="gtalk? ( jabber )
+ ^^ ( ${IUSE_VOICEMAIL_STORAGE/+/} )
+ voicemail_storage_odbc? ( odbc )
+"
+
+EPATCH_SUFFIX="patch"
+PATCHES=( "${WORKDIR}/asterisk-patchset" )
+
+RDEPEND="dev-db/sqlite:3
+ dev-libs/popt
+ dev-libs/libxml2
+ dev-libs/openssl
+ sys-libs/ncurses
+ sys-libs/zlib
+ alsa? ( media-libs/alsa-lib )
+ bluetooth? ( net-wireless/bluez )
+ calendar? ( net-libs/neon
+ dev-libs/libical
+ dev-libs/iksemel )
+ caps? ( sys-libs/libcap )
+ cluster? ( sys-cluster/corosync )
+ curl? ( net-misc/curl )
+ dahdi? ( >=net-libs/libpri-1.4.12_beta2
+ net-misc/dahdi-tools )
+ freetds? ( dev-db/freetds )
+ gtalk? ( dev-libs/iksemel )
+ http? ( dev-libs/gmime:2.4 )
+ iconv? ( virtual/libiconv )
+ ilbc? ( dev-libs/ilbc-rfc3951 )
+ jabber? ( dev-libs/iksemel )
+ ldap? ( net-nds/openldap )
+ libedit? ( dev-libs/libedit )
+ lua? ( dev-lang/lua )
+ mysql? ( virtual/mysql )
+ newt? ( dev-libs/newt )
+ odbc? ( dev-db/unixODBC )
+ osplookup? ( net-libs/osptoolkit )
+ portaudio? ( media-libs/portaudio )
+ postgres? ( dev-db/postgresql-base )
+ radius? ( net-dialup/radiusclient-ng )
+ selinux? ( sec-policy/selinux-asterisk )
+ snmp? ( net-analyzer/net-snmp )
+ span? ( media-libs/spandsp )
+ speex? ( media-libs/speex )
+ srtp? ( net-libs/libsrtp )
+ vorbis? ( media-libs/libvorbis )"
+
+DEPEND="${RDEPEND}
+ !net-libs/openh323
+ voicemail_storage_imap? ( virtual/imap-c-client )
+"
+
+RDEPEND="${RDEPEND}
+ syslog? ( virtual/logger )"
+
+PDEPEND="net-misc/asterisk-core-sounds
+ net-misc/asterisk-extra-sounds
+ net-misc/asterisk-moh-opsound"
+
+S="${WORKDIR}/${MY_P}"
+
+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
+
+ enewgroup asterisk
+ enewgroup dialout 20
+ enewuser asterisk -1 -1 /var/lib/asterisk "asterisk,dialout"
+}
+
+src_prepare() {
+ base_src_prepare
+ AT_M4DIR=autoconf eautoreconf
+}
+
+src_configure() {
+ local vmst
+
+ econf \
+ --libdir="/usr/$(get_libdir)" \
+ --localstatedir="/var" \
+ --with-crypto \
+ --with-gsm=internal \
+ --with-popt \
+ --with-ssl \
+ --with-z \
+ --without-pwlib \
+ $(use_with caps cap) \
+ $(use_with http gmime) \
+ $(use_with newt) \
+ $(use_with portaudio)
+
+ # 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
+
+ # Compile menuselect binary for optional components
+ emake menuselect.makeopts
+
+ # Broken functionality is forcibly disabled (bug #360143)
+ menuselect/menuselect --disable chan_misdn menuselect.makeopts
+ menuselect/menuselect --disable chan_ooh323 menuselect.makeopts
+
+ # Utility set is forcibly enabled (bug #358001)
+ menuselect/menuselect --enable smsq menuselect.makeopts
+ menuselect/menuselect --enable streamplayer menuselect.makeopts
+ menuselect/menuselect --enable aelparse menuselect.makeopts
+ menuselect/menuselect --enable astman menuselect.makeopts
+
+ # this is connected, otherwise it would not find
+ # ast_pktccops_gate_alloc symbol
+ menuselect/menuselect --enable chan_mgcp menuselect.makeopts
+ menuselect/menuselect --enable res_pktccops menuselect.makeopts
+
+ # SSL is forcibly enabled, IAX2 & DUNDI are expected to be available
+ menuselect/menuselect --enable pbx_dundi menuselect.makeopts
+ menuselect/menuselect --enable func_aes menuselect.makeopts
+ menuselect/menuselect --enable chan_iax2 menuselect.makeopts
+
+ # SQlite3 is now the main database backend, enable related features
+ menuselect/menuselect --enable cdr_sqlite3_custom menuselect.makeopts
+ menuselect/menuselect --enable cel_sqlite3_custom menuselect.makeopts
+
+ # The others are based on USE-flag settings
+ use_select() {
+ local state=$(use "$1" && echo enable || echo disable)
+ shift # remove use from parameters
+
+ while [[ -n $1 ]]; do
+ menuselect/menuselect --${state} "$1" menuselect.makeopts
+ shift
+ done
+ }
+
+ use_select alsa chan_alsa
+ use_select bluetooth chan_mobile
+ use_select calendar res_calendar res_calendar_{caldav,ews,exchange,icalendar}
+ use_select cluster res_corosync
+ use_select curl func_curl res_config_curl res_curl
+ use_select dahdi app_dahdibarge app_dahdiras chan_dahdi codec_dahdi res_timing_dahdi
+ use_select freetds {cdr,cel}_tds
+ use_select gtalk chan_motif
+ use_select http res_http_post
+ use_select iconv func_iconv
+ use_select jabber res_xmpp
+ use_select ilbc codec_ilbc format_ilbc
+ use_select ldap res_config_ldap
+ use_select lua pbx_lua
+ use_select mysql app_mysql cdr_mysql res_config_mysql
+ use_select odbc cdr_adaptive_odbc res_config_odbc {cdr,cel,res,func}_odbc
+ use_select osplookup app_osplookup
+ use_select oss chan_oss
+ use_select postgres {cdr,cel}_pgsql res_config_pgsql
+ use_select radius {cdr,cel}_radius
+ use_select snmp res_snmp
+ use_select span res_fax_spandsp
+ use_select speex {codec,func}_speex
+ use_select srtp res_srtp
+ use_select syslog cdr_syslog
+ use_select vorbis format_ogg_vorbis
+
+ # Voicemail storage ...
+ for vmst in ${IUSE_VOICEMAIL_STORAGE/+/}; do
+ if use ${vmst}; then
+ menuselect/menuselect --enable $(echo ${vmst##*_} | tr '[:lower:]' '[:upper:]')_STORAGE menuselect.makeopts
+ fi
+ done
+}
+
+src_compile() {
+ ASTLDFLAGS="${LDFLAGS}" emake
+}
+
+src_install() {
+ mkdir -p "${D}"usr/$(get_libdir)/pkgconfig || die
+ emake DESTDIR="${D}" installdirs
+ emake DESTDIR="${D}" install
+
+ if use radius; then
+ insinto /etc/radiusclient-ng/
+ doins contrib/dictionary.digium
+ fi
+ if use samples; then
+ emake DESTDIR="${D}" samples
+ 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/* || die
+ rm -f "${D}"var/lib/asterisk/sounds/demo-* || die
+ rm -f "${D}"var/lib/asterisk/agi-bin/* || die
+ rm -f "${D}"etc/asterisk/* || die
+ fi
+ rm -rf "${D}"var/spool/asterisk/voicemail/default || die
+
+ # keep directories
+ diropts -m 0770 -o asterisk -g asterisk
+ keepdir /etc/asterisk
+ keepdir /var/lib/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.8.0/asterisk.initd5 asterisk
+ newconfd "${FILESDIR}"/1.8.0/asterisk.confd asterisk
+
+ # install the upgrade documentation
+ #
+ dodoc README UPGRADE* BUGS CREDITS
+
+ # install extra documentation
+ #
+ if use doc
+ then
+ dodoc doc/*.txt
+ dodoc doc/*.pdf
+ fi
+
+ # install SIP scripts; bug #300832
+ #
+ dodoc "${FILESDIR}/1.6.2/sip_calc_auth"
+ dodoc "${FILESDIR}/1.8.0/find_call_sip_trace.sh"
+ dodoc "${FILESDIR}/1.8.0/find_call_ids.sh"
+ dodoc "${FILESDIR}/1.6.2/call_data.txt"
+
+ # install logrotate snippet; bug #329281
+ #
+ insinto /etc/logrotate.d
+ newins "${FILESDIR}/1.6.2/asterisk.logrotate3" asterisk
+}
+
+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 "Please read the Asterisk 11 upgrade document:"
+ elog "https://wiki.asterisk.org/wiki/display/AST/Upgrading+to+Asterisk+11"
+}
+
+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
+}