/[gentoo-x86]/net-misc/asterisk-g729/asterisk-g729-10.0.3.1.5.ebuild
Gentoo

Contents of /net-misc/asterisk-g729/asterisk-g729-10.0.3.1.5.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.4 - (show annotations) (download)
Mon Jan 14 12:17:33 2013 UTC (5 years, 6 months ago) by chainsaw
Branch: MAIN
CVS Tags: HEAD
Changes since 1.3: +1 -1 lines
FILE REMOVED
Use QA_PREBUILT instead of QA_EXECSTACK, as requested by Diego Elio "Flameeyes" Pettenò in bug #438654. Bump to Asterisk 11 compatible release and remove Asterisk 10, as requested by Vincent Brillault & Jaco Kroon in bug #447190.

(Portage version: 2.1.11.40/cvs/Linux x86_64, signed Manifest commit with key 0xB5058F9A)

1 # Copyright 1999-2012 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3 # $Header: /var/cvsroot/gentoo-x86/net-misc/asterisk-g729/asterisk-g729-10.0.3.1.5.ebuild,v 1.3 2012/09/24 00:46:53 vapier Exp $
4
5 EAPI="4"
6
7 inherit versionator multilib
8
9 DESCRIPTION="G.729 codec and supporting files for asterisk"
10 HOMEPAGE="http://store.digium.com/productview.php?product_code=G729CODEC"
11
12 BENCH_PV=1.0.8
13
14 AST_PV=10.0
15 MY_PV=$(replace_version_separator 2 _)
16
17 SRC_URI="x86? (
18 http://downloads.digium.com/pub/telephony/codec_g729/asterisk-${AST_PV}/x86-32/codec_g729a-${MY_PV}-athlon_32.tar.gz
19 http://downloads.digium.com/pub/telephony/codec_g729/asterisk-${AST_PV}/x86-32/codec_g729a-${MY_PV}-athlon_xp_32.tar.gz
20 http://downloads.digium.com/pub/telephony/codec_g729/asterisk-${AST_PV}/x86-32/codec_g729a-${MY_PV}-barcelona_32.tar.gz
21 http://downloads.digium.com/pub/telephony/codec_g729/asterisk-${AST_PV}/x86-32/codec_g729a-${MY_PV}-c3_2_32.tar.gz
22 http://downloads.digium.com/pub/telephony/codec_g729/asterisk-${AST_PV}/x86-32/codec_g729a-${MY_PV}-c3_32.tar.gz
23 http://downloads.digium.com/pub/telephony/codec_g729/asterisk-${AST_PV}/x86-32/codec_g729a-${MY_PV}-core2_32.tar.gz
24 http://downloads.digium.com/pub/telephony/codec_g729/asterisk-${AST_PV}/x86-32/codec_g729a-${MY_PV}-generic_32.tar.gz
25 http://downloads.digium.com/pub/telephony/codec_g729/asterisk-${AST_PV}/x86-32/codec_g729a-${MY_PV}-i686_32.tar.gz
26 http://downloads.digium.com/pub/telephony/codec_g729/asterisk-${AST_PV}/x86-32/codec_g729a-${MY_PV}-k6_3_32.tar.gz
27 http://downloads.digium.com/pub/telephony/codec_g729/asterisk-${AST_PV}/x86-32/codec_g729a-${MY_PV}-nocona_32.tar.gz
28 http://downloads.digium.com/pub/telephony/codec_g729/asterisk-${AST_PV}/x86-32/codec_g729a-${MY_PV}-opteron_32.tar.gz
29 http://downloads.digium.com/pub/telephony/codec_g729/asterisk-${AST_PV}/x86-32/codec_g729a-${MY_PV}-opteron_sse3_32.tar.gz
30 http://downloads.digium.com/pub/telephony/codec_g729/asterisk-${AST_PV}/x86-32/codec_g729a-${MY_PV}-pentium3m_32.tar.gz
31 http://downloads.digium.com/pub/telephony/codec_g729/asterisk-${AST_PV}/x86-32/codec_g729a-${MY_PV}-pentium4m_32.tar.gz
32 http://downloads.digium.com/pub/telephony/codec_g729/asterisk-${AST_PV}/x86-32/codec_g729a-${MY_PV}-pentium_m_32.tar.gz
33 http://downloads.digium.com/pub/telephony/codec_g729/asterisk-${AST_PV}/x86-32/codec_g729a-${MY_PV}-prescott_32.tar.gz
34 http://downloads.digium.com/pub/telephony/codec_g729/benchg729/x86-32/benchg729-${BENCH_PV}-x86_32 -> benchg729-x86_32
35 http://downloads.digium.com/pub/register/x86-32/register -> astregister-x86_32
36 http://downloads.digium.com/pub/register/x86-32/asthostid -> asthostid-x86_32
37 )
38 amd64? (
39 http://downloads.digium.com/pub/telephony/codec_g729/asterisk-${AST_PV}/x86-64/codec_g729a-${MY_PV}-barcelona_64.tar.gz
40 http://downloads.digium.com/pub/telephony/codec_g729/asterisk-${AST_PV}/x86-64/codec_g729a-${MY_PV}-core2_64.tar.gz
41 http://downloads.digium.com/pub/telephony/codec_g729/asterisk-${AST_PV}/x86-64/codec_g729a-${MY_PV}-generic_64.tar.gz
42 http://downloads.digium.com/pub/telephony/codec_g729/asterisk-${AST_PV}/x86-64/codec_g729a-${MY_PV}-nocona_64.tar.gz
43 http://downloads.digium.com/pub/telephony/codec_g729/asterisk-${AST_PV}/x86-64/codec_g729a-${MY_PV}-opteron_64.tar.gz
44 http://downloads.digium.com/pub/telephony/codec_g729/asterisk-${AST_PV}/x86-64/codec_g729a-${MY_PV}-opteron_sse3_64.tar.gz
45 http://downloads.digium.com/pub/telephony/codec_g729/benchg729/x86-64/benchg729-${BENCH_PV}-x86_64 -> benchg729-x86_64
46 http://downloads.digium.com/pub/register/x86-64/register -> astregister-x86_64
47 http://downloads.digium.com/pub/register/x86-64/asthostid -> asthostid-x86_64
48 )
49 http://g729.uls.co.za/static/g729-stats-collector/collect-g729-stats.sh"
50
51 LICENSE="Digium"
52 SLOT="0"
53 KEYWORDS="~amd64 ~x86"
54 IUSE=""
55
56 DEPEND=""
57 RDEPEND="${DEPEND} =net-misc/asterisk-10*"
58
59 RESTRICT="mirror strip"
60
61 QA_FLAGS_IGNORED_amd64="usr/lib64/codec_g729a.so usr/sbin/benchg729"
62 QA_FLAGS_IGNORED_x86="usr/lib/codec_g729a.so usr/sbin/benchg729"
63
64 QA_EXECSTACK="usr/sbin/benchg729 usr/sbin/asthostid usr/sbin/astregister"
65
66 S="${WORKDIR}"
67
68 src_prepare() {
69 local binsuffix
70 local b
71
72 if use x86; then
73 binsuffix=x86_32
74 elif use amd64; then
75 binsuffix=x86_64
76 else
77 die "Ebuild only functions for x86 and amd64."
78 fi
79
80 for b in astregister asthostid benchg729; do
81 cp "${DISTDIR}/${b}-${binsuffix}" "${WORKDIR}/${b}" || die
82 fperms 755 ${b}
83 done
84
85 cp "${DISTDIR}/collect-g729-stats.sh" "${WORKDIR}" || die
86 }
87
88 src_compile() {
89 ./benchg729 | tee benchdata
90 variant=$(sed -nre "s/^Recommended flavor for this system is '([^']*)'.*/\1/p" < benchdata)
91 [ -d codec_g729a-${MY_PV}-${variant}_${size} ] || variant=generic
92 [ -z $variant ] && variant=generic
93 }
94
95 src_install() {
96 local size
97
98 if use x86; then
99 size=32
100 elif use amd64; then
101 size=64
102 else
103 die "Ebuild only functions for x86 and amd64."
104 fi
105
106 dosbin astregister
107 dosbin asthostid
108 dosbin benchg729
109 dosbin collect-g729-stats.sh
110
111 dodoc codec_g729a-${MY_PV}-${variant}_${size}/LICENSE
112 dodoc codec_g729a-${MY_PV}-${variant}_${size}/README
113 insinto usr/$(get_libdir)/asterisk/modules/
114 doins "codec_g729a-${MY_PV}-${variant}_${size}/codec_g729a.so"
115 }
116
117 pkg_postinst() {
118 einfo "Please note that Digium's register utility has been installed as astregister"
119 einfo
120 einfo "Please consider participating in the G.729 stats collection that ULS"
121 einfo "is performing. This will assist in picking better variants for more"
122 einfo "processors as we gather more statistics. All you need to do is run"
123 einfo "the collect-g729-stats.sh command."
124 [ "${variant}" = "generic" ] && einfo "You are using the generic flavor of the codec, in order to install a more appropriate one please install a G.729 license and remerge this package (${PN})."
125 }

  ViewVC Help
Powered by ViewVC 1.1.20