Gentoo Archives: gentoo-commits

From: "Tony Vroon (chainsaw)" <chainsaw@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo-x86 commit in net-misc/asterisk: metadata.xml ChangeLog asterisk-11.0.0.ebuild
Date: Tue, 30 Oct 2012 00:30:46
Message-Id: 20121030003035.5D8F321600@flycatcher.gentoo.org
1 chainsaw 12/10/30 00:30:35
2
3 Modified: metadata.xml ChangeLog
4 Added: asterisk-11.0.0.ebuild
5 Log:
6 Initial release on 11 (LTS) branch. Distro patchset & ebuild menuselect logic ported by Oliver Jaksch. Build system tamed and parallelised by Erik Wallin. Closes bug #432894. Patch from Pacho Ramos inverts logic in gmime detection and facilitates the pending removal of 2.4 from the portage tree, closes bug #439846. This is currently masked and not recommended for deployment.
7
8 (Portage version: 2.1.11.31/cvs/Linux x86_64, unsigned Manifest commit)
9
10 Revision Changes Path
11 1.19 net-misc/asterisk/metadata.xml
12
13 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-misc/asterisk/metadata.xml?rev=1.19&view=markup
14 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-misc/asterisk/metadata.xml?rev=1.19&content-type=text/plain
15 diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-misc/asterisk/metadata.xml?r1=1.18&r2=1.19
16
17 Index: metadata.xml
18 ===================================================================
19 RCS file: /var/cvsroot/gentoo-x86/net-misc/asterisk/metadata.xml,v
20 retrieving revision 1.18
21 retrieving revision 1.19
22 diff -u -r1.18 -r1.19
23 --- metadata.xml 11 Oct 2011 15:22:21 -0000 1.18
24 +++ metadata.xml 30 Oct 2012 00:30:35 -0000 1.19
25 @@ -16,5 +16,7 @@
26 <flag name="ais">Support clustering using the Application Interface Specification framework</flag>
27 <flag name="osplookup">Support secure peering using the Open Settlement Protocol</flag>
28 <flag name="http">Enable embedded web server</flag>
29 + <flag name="cluster">Enable high-availability support through the Corosync Cluster Engine</flag>
30 + <flag name="ilbc">Enable the Internet Low Bitrate Codec (iLBC)</flag>
31 </use>
32 </pkgmetadata>
33
34
35
36 1.418 net-misc/asterisk/ChangeLog
37
38 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-misc/asterisk/ChangeLog?rev=1.418&view=markup
39 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-misc/asterisk/ChangeLog?rev=1.418&content-type=text/plain
40 diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-misc/asterisk/ChangeLog?r1=1.417&r2=1.418
41
42 Index: ChangeLog
43 ===================================================================
44 RCS file: /var/cvsroot/gentoo-x86/net-misc/asterisk/ChangeLog,v
45 retrieving revision 1.417
46 retrieving revision 1.418
47 diff -u -r1.417 -r1.418
48 --- ChangeLog 9 Oct 2012 08:38:23 -0000 1.417
49 +++ ChangeLog 30 Oct 2012 00:30:35 -0000 1.418
50 @@ -1,6 +1,16 @@
51 # ChangeLog for net-misc/asterisk
52 # Copyright 1999-2012 Gentoo Foundation; Distributed under the GPL v2
53 -# $Header: /var/cvsroot/gentoo-x86/net-misc/asterisk/ChangeLog,v 1.417 2012/10/09 08:38:23 chainsaw Exp $
54 +# $Header: /var/cvsroot/gentoo-x86/net-misc/asterisk/ChangeLog,v 1.418 2012/10/30 00:30:35 chainsaw Exp $
55 +
56 +*asterisk-11.0.0 (30 Oct 2012)
57 +
58 + 30 Oct 2012; Tony Vroon <chainsaw@g.o> +asterisk-11.0.0.ebuild,
59 + metadata.xml:
60 + Initial release on 11 (LTS) branch. Distro patchset & ebuild menuselect logic
61 + ported by Oliver Jaksch. Build system tamed and parallelised by Erik Wallin.
62 + Closes bug #432894. Patch from Pacho Ramos inverts logic in gmime detection
63 + and facilitates the pending removal of 2.4 from the portage tree, closes bug
64 + #439846. This is currently masked and not recommended for deployment.
65
66 *asterisk-10.9.0 (09 Oct 2012)
67 *asterisk-1.8.17.0 (09 Oct 2012)
68
69
70
71 1.1 net-misc/asterisk/asterisk-11.0.0.ebuild
72
73 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-misc/asterisk/asterisk-11.0.0.ebuild?rev=1.1&view=markup
74 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-misc/asterisk/asterisk-11.0.0.ebuild?rev=1.1&content-type=text/plain
75
76 Index: asterisk-11.0.0.ebuild
77 ===================================================================
78 # Copyright 1999-2012 Gentoo Foundation
79 # Distributed under the terms of the GNU General Public License v2
80 # $Header: /var/cvsroot/gentoo-x86/net-misc/asterisk/asterisk-11.0.0.ebuild,v 1.1 2012/10/30 00:30:35 chainsaw Exp $
81
82 EAPI=4
83 inherit autotools base eutils linux-info multilib
84
85 MY_P="${PN}-${PV/_/-}"
86
87 DESCRIPTION="Asterisk: A Modular Open Source PBX System"
88 HOMEPAGE="http://www.asterisk.org/"
89 SRC_URI="http://downloads.asterisk.org/pub/telephony/asterisk/releases/${MY_P}.tar.gz
90 mirror://gentoo/gentoo-asterisk-patchset-3.0.tar.bz2"
91 LICENSE="GPL-2"
92 SLOT="0"
93 KEYWORDS="~amd64 ~x86"
94
95 IUSE_VOICEMAIL_STORAGE="
96 +voicemail_storage_file
97 voicemail_storage_odbc
98 voicemail_storage_imap
99 "
100 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"
101 IUSE_EXPAND="VOICEMAIL_STORAGE"
102 REQUIRED_USE="gtalk? ( jabber )
103 ^^ ( ${IUSE_VOICEMAIL_STORAGE/+/} )
104 voicemail_storage_odbc? ( odbc )
105 "
106
107 EPATCH_SUFFIX="patch"
108 PATCHES=( "${WORKDIR}/asterisk-patchset" )
109
110 RDEPEND="dev-db/sqlite:3
111 dev-libs/popt
112 dev-libs/libxml2
113 dev-libs/openssl
114 sys-libs/ncurses
115 sys-libs/zlib
116 alsa? ( media-libs/alsa-lib )
117 bluetooth? ( net-wireless/bluez )
118 calendar? ( net-libs/neon
119 dev-libs/libical
120 dev-libs/iksemel )
121 caps? ( sys-libs/libcap )
122 cluster? ( sys-cluster/corosync )
123 curl? ( net-misc/curl )
124 dahdi? ( >=net-libs/libpri-1.4.12_beta2
125 net-misc/dahdi-tools )
126 freetds? ( dev-db/freetds )
127 gtalk? ( dev-libs/iksemel )
128 http? ( dev-libs/gmime:2.4 )
129 iconv? ( virtual/libiconv )
130 ilbc? ( dev-libs/ilbc-rfc3951 )
131 jabber? ( dev-libs/iksemel )
132 ldap? ( net-nds/openldap )
133 libedit? ( dev-libs/libedit )
134 lua? ( dev-lang/lua )
135 mysql? ( virtual/mysql )
136 newt? ( dev-libs/newt )
137 odbc? ( dev-db/unixODBC )
138 osplookup? ( net-libs/osptoolkit )
139 portaudio? ( media-libs/portaudio )
140 postgres? ( dev-db/postgresql-base )
141 radius? ( net-dialup/radiusclient-ng )
142 selinux? ( sec-policy/selinux-asterisk )
143 snmp? ( net-analyzer/net-snmp )
144 span? ( media-libs/spandsp )
145 speex? ( media-libs/speex )
146 srtp? ( net-libs/libsrtp )
147 vorbis? ( media-libs/libvorbis )"
148
149 DEPEND="${RDEPEND}
150 !net-libs/openh323
151 voicemail_storage_imap? ( virtual/imap-c-client )
152 "
153
154 RDEPEND="${RDEPEND}
155 syslog? ( virtual/logger )"
156
157 PDEPEND="net-misc/asterisk-core-sounds
158 net-misc/asterisk-extra-sounds
159 net-misc/asterisk-moh-opsound"
160
161 S="${WORKDIR}/${MY_P}"
162
163 pkg_setup() {
164 CONFIG_CHECK="~!NF_CONNTRACK_SIP"
165 local WARNING_NF_CONNTRACK_SIP="SIP (NAT) connection tracking is enabled. Some users
166 have reported that this module dropped critical SIP packets in their deployments. You
167 may want to disable it if you see such problems."
168 check_extra_config
169
170 enewgroup asterisk
171 enewgroup dialout 20
172 enewuser asterisk -1 -1 /var/lib/asterisk "asterisk,dialout"
173 }
174
175 src_prepare() {
176 base_src_prepare
177 AT_M4DIR=autoconf eautoreconf
178 }
179
180 src_configure() {
181 local vmst
182
183 econf \
184 --libdir="/usr/$(get_libdir)" \
185 --localstatedir="/var" \
186 --with-crypto \
187 --with-gsm=internal \
188 --with-popt \
189 --with-ssl \
190 --with-z \
191 $(use_with caps cap) \
192 $(use_with http gmime) \
193 $(use_with newt) \
194 $(use_with portaudio)
195
196 # Blank out sounds/sounds.xml file to prevent
197 # asterisk from installing sounds files (we pull them in via
198 # asterisk-{core,extra}-sounds and asterisk-moh-opsound.
199 >"${S}"/sounds/sounds.xml
200
201 # Compile menuselect binary for optional components
202 emake menuselect.makeopts
203
204 # Broken functionality is forcibly disabled (bug #360143)
205 menuselect/menuselect --disable chan_misdn menuselect.makeopts
206 menuselect/menuselect --disable chan_ooh323 menuselect.makeopts
207
208 # Utility set is forcibly enabled (bug #358001)
209 menuselect/menuselect --enable smsq menuselect.makeopts
210 menuselect/menuselect --enable streamplayer menuselect.makeopts
211 menuselect/menuselect --enable aelparse menuselect.makeopts
212 menuselect/menuselect --enable astman menuselect.makeopts
213
214 # this is connected, otherwise it would not find
215 # ast_pktccops_gate_alloc symbol
216 menuselect/menuselect --enable chan_mgcp menuselect.makeopts
217 menuselect/menuselect --enable res_pktccops menuselect.makeopts
218
219 # SSL is forcibly enabled, IAX2 & DUNDI are expected to be available
220 menuselect/menuselect --enable pbx_dundi menuselect.makeopts
221 menuselect/menuselect --enable func_aes menuselect.makeopts
222 menuselect/menuselect --enable chan_iax2 menuselect.makeopts
223
224 # SQlite3 is now the main database backend, enable related features
225 menuselect/menuselect --enable cdr_sqlite3_custom menuselect.makeopts
226 menuselect/menuselect --enable cel_sqlite3_custom menuselect.makeopts
227
228 # The others are based on USE-flag settings
229 use_select() {
230 local state=$(use "$1" && echo enable || echo disable)
231 shift # remove use from parameters
232
233 while [[ -n $1 ]]; do
234 menuselect/menuselect --${state} "$1" menuselect.makeopts
235 shift
236 done
237 }
238
239 use_select alsa chan_alsa
240 use_select bluetooth chan_mobile
241 use_select calendar res_calendar res_calendar_{caldav,ews,exchange,icalendar}
242 use_select cluster res_corosync
243 use_select curl func_curl res_config_curl res_curl
244 use_select dahdi app_dahdibarge app_dahdiras chan_dahdi codec_dahdi res_timing_dahdi
245 use_select freetds {cdr,cel}_tds
246 use_select gtalk chan_motif
247 use_select http res_http_post
248 use_select iconv func_iconv
249 use_select jabber res_xmpp
250 use_select ilbc codec_ilbc format_ilbc
251 use_select ldap res_config_ldap
252 use_select lua pbx_lua
253 use_select mysql app_mysql cdr_mysql res_config_mysql
254 use_select odbc cdr_adaptive_odbc res_config_odbc {cdr,cel,res,func}_odbc
255 use_select osplookup app_osplookup
256 use_select oss chan_oss
257 use_select postgres {cdr,cel}_pgsql res_config_pgsql
258 use_select radius {cdr,cel}_radius
259 use_select snmp res_snmp
260 use_select span res_fax_spandsp
261 use_select speex {codec,func}_speex
262 use_select srtp res_srtp
263 use_select syslog cdr_syslog
264 use_select vorbis format_ogg_vorbis
265
266 # Voicemail storage ...
267 for vmst in ${IUSE_VOICEMAIL_STORAGE/+/}; do
268 if use ${vmst}; then
269 menuselect/menuselect --enable $(echo ${vmst##*_} | tr '[:lower:]' '[:upper:]')_STORAGE menuselect.makeopts
270 fi
271 done
272 }
273
274 src_compile() {
275 ASTLDFLAGS="${LDFLAGS}" emake
276 }
277
278 src_install() {
279 mkdir -p "${D}"usr/$(get_libdir)/pkgconfig || die
280 emake DESTDIR="${D}" installdirs
281 emake DESTDIR="${D}" install
282
283 if use radius; then
284 insinto /etc/radiusclient-ng/
285 doins contrib/dictionary.digium
286 fi
287 if use samples; then
288 emake DESTDIR="${D}" samples
289 for conffile in "${D}"etc/asterisk/*.*
290 do
291 chown asterisk:asterisk $conffile
292 chmod 0660 $conffile
293 done
294 einfo "Sample files have been installed"
295 else
296 einfo "Skipping installation of sample files..."
297 rm -f "${D}"var/lib/asterisk/mohmp3/* || die
298 rm -f "${D}"var/lib/asterisk/sounds/demo-* || die
299 rm -f "${D}"var/lib/asterisk/agi-bin/* || die
300 rm -f "${D}"etc/asterisk/* || die
301 fi
302 rm -rf "${D}"var/spool/asterisk/voicemail/default || die
303
304 # keep directories
305 diropts -m 0770 -o asterisk -g asterisk
306 keepdir /etc/asterisk
307 keepdir /var/lib/asterisk
308 keepdir /var/run/asterisk
309 keepdir /var/spool/asterisk
310 keepdir /var/spool/asterisk/{system,tmp,meetme,monitor,dictate,voicemail}
311 diropts -m 0750 -o asterisk -g asterisk
312 keepdir /var/log/asterisk/{cdr-csv,cdr-custom}
313
314 newinitd "${FILESDIR}"/1.8.0/asterisk.initd3 asterisk
315 newconfd "${FILESDIR}"/1.8.0/asterisk.confd asterisk
316
317 # install the upgrade documentation
318 #
319 dodoc README UPGRADE* BUGS CREDITS
320
321 # install extra documentation
322 #
323 if use doc
324 then
325 dodoc doc/*.txt
326 dodoc doc/*.pdf
327 fi
328
329 # install SIP scripts; bug #300832
330 #
331 dodoc "${FILESDIR}/1.6.2/sip_calc_auth"
332 dodoc "${FILESDIR}/1.8.0/find_call_sip_trace.sh"
333 dodoc "${FILESDIR}/1.8.0/find_call_ids.sh"
334 dodoc "${FILESDIR}/1.6.2/call_data.txt"
335
336 # install logrotate snippet; bug #329281
337 #
338 insinto /etc/logrotate.d
339 newins "${FILESDIR}/1.6.2/asterisk.logrotate3" asterisk
340 }
341
342 pkg_postinst() {
343 #
344 # Announcements, warnings, reminders...
345 #
346 einfo "Asterisk has been installed"
347 echo
348 elog "If you want to know more about asterisk, visit these sites:"
349 elog "http://www.asteriskdocs.org/"
350 elog "http://www.voip-info.org/wiki-Asterisk"
351 echo
352 elog "http://www.automated.it/guidetoasterisk.htm"
353 echo
354 elog "Gentoo VoIP IRC Channel:"
355 elog "#gentoo-voip @ irc.freenode.net"
356 echo
357 echo
358 elog "Please read the Asterisk 11 upgrade document:"
359 elog "https://wiki.asterisk.org/wiki/display/AST/Upgrading+to+Asterisk+11"
360 }
361
362 pkg_config() {
363 einfo "Do you want to reset file permissions and ownerships (y/N)?"
364
365 read tmp
366 tmp="$(echo $tmp | tr '[:upper:]' '[:lower:]')"
367
368 if [[ "$tmp" = "y" ]] ||\
369 [[ "$tmp" = "yes" ]]
370 then
371 einfo "Resetting permissions to defaults..."
372
373 for x in spool run lib log; do
374 chown -R asterisk:asterisk "${ROOT}"var/${x}/asterisk
375 chmod -R u=rwX,g=rwX,o= "${ROOT}"var/${x}/asterisk
376 done
377
378 chown -R root:asterisk "${ROOT}"etc/asterisk
379 chmod -R u=rwX,g=rwX,o= "${ROOT}"etc/asterisk
380
381 einfo "done"
382 else
383 einfo "skipping"
384 fi
385 }