net-misc/asterisk-opus: initial version.
authorJaco Kroon <jaco@uls.co.za>
Sat, 21 Mar 2020 18:30:12 +0000 (20:30 +0200)
committerJoonas Niilola <juippis@gentoo.org>
Tue, 31 Mar 2020 08:38:59 +0000 (11:38 +0300)
This is Digium's OPUS codec implementation for asterisk.  If you're
doing WebRTC you should use this.

Closes: https://bugs.gentoo.org/655402
Package-Manager: Portage-2.3.89, Repoman-2.3.20
Signed-off-by: Jaco Kroon <jaco@uls.co.za>
Closes: https://github.com/gentoo/gentoo/pull/15044
Signed-off-by: Joonas Niilola <juippis@gentoo.org>
net-misc/asterisk-opus/Manifest [new file with mode: 0644]
net-misc/asterisk-opus/asterisk-opus-13.0.1.3.0.ebuild [new file with mode: 0644]
net-misc/asterisk-opus/metadata.xml [new file with mode: 0644]

diff --git a/net-misc/asterisk-opus/Manifest b/net-misc/asterisk-opus/Manifest
new file mode 100644 (file)
index 0000000..87a613c
--- /dev/null
@@ -0,0 +1,2 @@
+DIST codec_opus-13.0_1.3.0-x86_32.tar.gz 308059 BLAKE2B ec93fe29c030f2e63dffef882326c9f362e2a81c8de26eb04e96995c00acf965ea376555c0befa90bdf0f2592d40cc2e296abba720702a6cd7f6683f9784d533 SHA512 aa4aafa4c688a328eec81daafd0589fc3a25d22d374742a0500ca71763d4191a24b055e3eb6ecd9bd3a0556ef359ab9a8482b44e9c1633568136db4997284063
+DIST codec_opus-13.0_1.3.0-x86_64.tar.gz 343694 BLAKE2B ff43085aabbfc4f4082dc22f11b12d62ddb631b46df492baef8786a1f76cbc6b2828091867d40c77f0c268ed2ba50148fd6a1394493b595342da408d6746fe20 SHA512 0932006e8537ddee8c73b598bf04b6b552e1bf9527c65abdd6f7b8ff7ef677e251bc4fff55233e5d7e715f9ff5b928347618ed0d14a1f6bc9c6c728303593213
diff --git a/net-misc/asterisk-opus/asterisk-opus-13.0.1.3.0.ebuild b/net-misc/asterisk-opus/asterisk-opus-13.0.1.3.0.ebuild
new file mode 100644 (file)
index 0000000..43c46db
--- /dev/null
@@ -0,0 +1,48 @@
+# Copyright 1999-2020 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI="7"
+
+DESCRIPTION="OPUS codec and supporting files for asterisk"
+HOMEPAGE="https://wiki.asterisk.org/wiki/display/AST/Codec+Opus"
+
+AST_PV="$(ver_cut 1-2)"
+MY_PV="$(ver_rs 2 _)"
+
+SRC_URI="amd64? (
+       https://downloads.digium.com/pub/telephony/codec_opus/asterisk-${AST_PV}/x86-64/codec_opus-${MY_PV}-x86_64.tar.gz
+)
+x86? (
+       https://downloads.digium.com/pub/telephony/codec_opus/asterisk-${AST_PV}/x86-32/codec_opus-${MY_PV}-x86_32.tar.gz
+)"
+
+LICENSE="Digium"
+SLOT="0"
+KEYWORDS="-* ~amd64 ~x86"
+
+RDEPEND="=net-misc/asterisk-${PV%%.*}*"
+
+RESTRICT="mirror strip"
+
+S="${WORKDIR}"
+
+pkg_setup() {
+       QA_FLAGS_IGNORED="/usr/$(get_libdir)/asterisk/modules/codec_opus.so"
+}
+
+src_install() {
+       local arch
+
+       if use x86; then
+               arch=x86_32
+       elif use amd64; then
+               arch=x86_64
+       fi
+
+       dodoc codec_opus-${MY_PV}-${arch}/README
+       insinto /usr/$(get_libdir)/asterisk/modules/
+       doins "codec_opus-${MY_PV}-${arch}/codec_opus.so"
+
+       insinto /var/lib/asterisk/documentation/thirdparty
+       doins "codec_opus-${MY_PV}-${arch}/codec_opus_config-en_US.xml"
+}
diff --git a/net-misc/asterisk-opus/metadata.xml b/net-misc/asterisk-opus/metadata.xml
new file mode 100644 (file)
index 0000000..e6da82c
--- /dev/null
@@ -0,0 +1,16 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+       <maintainer type="person">
+               <email>jaco@uls.co.za</email>
+               <name>Jaco Kroon</name>
+       </maintainer>
+       <maintainer type="project">
+               <email>proxy-maint@gentoo.org</email>
+               <name>Proxy Maintainers</name>
+       </maintainer>
+       <longdescription lang="en">
+               OPUS is one of the codecs utilized for WebRTC, this one is a binary module
+               provided by Digium (royalty free) for use in asterisk for transcoding.
+       </longdescription>
+</pkgmetadata>