From mboxrd@z Thu Jan  1 00:00:00 1970
Return-Path: <gentoo-commits+bounces-1297270-garchives=archives.gentoo.org@lists.gentoo.org>
Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80])
	(using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
	(No client certificate requested)
	by finch.gentoo.org (Postfix) with ESMTPS id 20ACC139336
	for <garchives@archives.gentoo.org>; Mon, 28 Jun 2021 08:38:53 +0000 (UTC)
Received: from pigeon.gentoo.org (localhost [127.0.0.1])
	by pigeon.gentoo.org (Postfix) with SMTP id 32FA0E08A8;
	Mon, 28 Jun 2021 08:38:52 +0000 (UTC)
Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183])
	(using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits))
	(No client certificate requested)
	by pigeon.gentoo.org (Postfix) with ESMTPS id 19C0EE08A8
	for <gentoo-commits@lists.gentoo.org>; Mon, 28 Jun 2021 08:38:52 +0000 (UTC)
Received: from oystercatcher.gentoo.org (unknown [IPv6:2a01:4f8:202:4333:225:90ff:fed9:fc84])
	(using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits))
	(No client certificate requested)
	by smtp.gentoo.org (Postfix) with ESMTPS id A49B9335DB2
	for <gentoo-commits@lists.gentoo.org>; Mon, 28 Jun 2021 08:38:50 +0000 (UTC)
Received: from localhost.localdomain (localhost [IPv6:::1])
	by oystercatcher.gentoo.org (Postfix) with ESMTP id 40DC27BD
	for <gentoo-commits@lists.gentoo.org>; Mon, 28 Jun 2021 08:38:49 +0000 (UTC)
From: "Georgy Yakovlev" <gyakovlev@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Content-Transfer-Encoding: 8bit
Content-type: text/plain; charset=UTF-8
Reply-To: gentoo-dev@lists.gentoo.org, "Georgy Yakovlev" <gyakovlev@gentoo.org>
Message-ID: <1624869514.e17cfc3afda880e35680657ea8d01437a285817c.gyakovlev@gentoo>
Subject: [gentoo-commits] repo/gentoo:master commit in: media-libs/libtgvoip/
X-VCS-Repository: repo/gentoo
X-VCS-Files: media-libs/libtgvoip/libtgvoip-2.4.4_p20210302-r2.ebuild
X-VCS-Directories: media-libs/libtgvoip/
X-VCS-Committer: gyakovlev
X-VCS-Committer-Name: Georgy Yakovlev
X-VCS-Revision: e17cfc3afda880e35680657ea8d01437a285817c
X-VCS-Branch: master
Date: Mon, 28 Jun 2021 08:38:49 +0000 (UTC)
Precedence: bulk
List-Post: <mailto:gentoo-commits@lists.gentoo.org>
List-Help: <mailto:gentoo-commits+help@lists.gentoo.org>
List-Unsubscribe: <mailto:gentoo-commits+unsubscribe@lists.gentoo.org>
List-Subscribe: <mailto:gentoo-commits+subscribe@lists.gentoo.org>
List-Id: Gentoo Linux mail <gentoo-commits.gentoo.org>
X-BeenThere: gentoo-commits@lists.gentoo.org
X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply
X-Archives-Salt: 6ca81f8c-ca66-4ea9-ba96-08444c4e8dd5
X-Archives-Hash: 46e754f05d3c2a3be988ba26c9cdb876

commit:     e17cfc3afda880e35680657ea8d01437a285817c
Author:     Esteve Varela Colominas <esteve.varela <AT> gmail <DOT> com>
AuthorDate: Sun Jun 27 22:01:57 2021 +0000
Commit:     Georgy Yakovlev <gyakovlev <AT> gentoo <DOT> org>
CommitDate: Mon Jun 28 08:38:34 2021 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=e17cfc3a

media-libs/libtgvoip: Revbump 2.4.4_p20210302-r2

Added slotted dependency for media-libs/tg_owt, so this package is
rebuilt when appropriate without bumping in the future.

Signed-off-by: Esteve Varela Colominas <esteve.varela <AT> gmail.com>
Signed-off-by: Georgy Yakovlev <gyakovlev <AT> gentoo.org>

 .../libtgvoip/libtgvoip-2.4.4_p20210302-r2.ebuild  | 61 ++++++++++++++++++++++
 1 file changed, 61 insertions(+)

diff --git a/media-libs/libtgvoip/libtgvoip-2.4.4_p20210302-r2.ebuild b/media-libs/libtgvoip/libtgvoip-2.4.4_p20210302-r2.ebuild
new file mode 100644
index 00000000000..96b273ee47f
--- /dev/null
+++ b/media-libs/libtgvoip/libtgvoip-2.4.4_p20210302-r2.ebuild
@@ -0,0 +1,61 @@
+# Copyright 2020-2021 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+inherit flag-o-matic autotools
+
+DESCRIPTION="VoIP library for Telegram clients"
+HOMEPAGE="https://github.com/telegramdesktop/libtgvoip"
+
+LIBTGVOIP_COMMIT="0c0a6e476df58ee441490da72ca7a32f83e68dbd"
+SRC_URI="https://github.com/telegramdesktop/libtgvoip/archive/${LIBTGVOIP_COMMIT}.tar.gz -> ${P}.tar.gz"
+S="${WORKDIR}/${PN}-${LIBTGVOIP_COMMIT}"
+
+LICENSE="Unlicense"
+SLOT="0"
+KEYWORDS="~amd64 ~ppc64"
+IUSE="+dsp +alsa pulseaudio"
+
+DEPEND="
+	media-libs/opus:=
+	alsa? ( media-libs/alsa-lib )
+	dsp? ( media-libs/tg_owt:= )
+	pulseaudio? ( media-sound/pulseaudio )
+"
+RDEPEND="${DEPEND}"
+BDEPEND="virtual/pkgconfig"
+REQUIRED_USE="
+	|| ( alsa pulseaudio )
+"
+
+src_prepare() {
+	# Will be controlled by us
+	sed -i -e '/^CFLAGS += -DTGVOIP_NO_DSP/d' Makefile.am || die
+	# https://bugs.gentoo.org/717210
+	echo 'libtgvoip_la_LIBTOOLFLAGS = --tag=CXX' >> Makefile.am || die
+	default
+	eautoreconf
+}
+
+src_configure() {
+	local myconf=(
+		--disable-static
+		--disable-dsp  # WebRTC is linked from tg_owt
+		$(use_with alsa)
+		$(use_with pulseaudio pulse)
+	)
+	if use dsp; then
+		append-cppflags '-I/usr/include/tg_owt'
+		append-cppflags '-I/usr/include/tg_owt/third_party/abseil-cpp'
+		append-libs '-ltg_owt'
+	else
+		append-cppflags '-DTGVOIP_NO_DSP'
+	fi
+	econf "${myconf[@]}"
+}
+
+src_install() {
+	default
+	find "${D}" -name '*.la' -delete || die
+}