commit:     1e74d5871b7aff2cd35b2fce381aa65b7df39fac
Author:     Esteve Varela Colominas <esteve.varela <AT> gmail <DOT> com>
AuthorDate: Fri Aug 13 07:41:55 2021 +0000
Commit:     Georgy Yakovlev <gyakovlev <AT> gentoo <DOT> org>
CommitDate: Fri Aug 13 23:29:50 2021 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=1e74d587

net-im/telegram-desktop: Fix building with tg_owt[-screencast]

Removed a patch from tg_owt forgetting it actually refused to build
without. Upstream's current solution is a patch in telegram-desktop
itself.

Closes: https://bugs.gentoo.org/807907
Thanks-to: Teun Blok <gomezloper <AT> msn.com>
Signed-off-by: Esteve Varela Colominas <esteve.varela <AT> gmail.com>
Closes: https://github.com/gentoo/gentoo/pull/21974
Signed-off-by: Georgy Yakovlev <gyakovlev <AT> gentoo.org>

 ...desktop-2.8.11-fix-build-without-pipewire.patch | 26 ++++++++++++++++++++++
 .../telegram-desktop-2.8.11-r2.ebuild              |  1 +
 2 files changed, 27 insertions(+)

diff --git 
a/net-im/telegram-desktop/files/tdesktop-2.8.11-fix-build-without-pipewire.patch
 
b/net-im/telegram-desktop/files/tdesktop-2.8.11-fix-build-without-pipewire.patch
new file mode 100644
index 00000000000..ecfc63abeb5
--- /dev/null
+++ 
b/net-im/telegram-desktop/files/tdesktop-2.8.11-fix-build-without-pipewire.patch
@@ -0,0 +1,26 @@
+Fix build without pipewire
+
+set_allow_pipewire isn't available if WEBRTC_USE_PIPEWIRE isn't set
+
+--- 
tdesktop-2.8.11-full.orig/Telegram/ThirdParty/tgcalls/tgcalls/desktop_capturer/DesktopCaptureSourceHelper.cpp
++++ 
tdesktop-2.8.11-full/Telegram/ThirdParty/tgcalls/tgcalls/desktop_capturer/DesktopCaptureSourceHelper.cpp
+@@ -286,7 +286,7 @@
+     options.set_allow_use_magnification_api(false);
+ #elif defined WEBRTC_MAC
+     options.set_allow_iosurface(true);
+-#elif defined WEBRTC_LINUX
++#elif defined WEBRTC_USE_PIPEWIRE
+     options.set_allow_pipewire(true);
+ #endif // WEBRTC_WIN || WEBRTC_MAC
+ 
+--- 
tdesktop-2.8.11-full.orig/Telegram/ThirdParty/tgcalls/tgcalls/desktop_capturer/DesktopCaptureSourceManager.cpp
++++ 
tdesktop-2.8.11-full/Telegram/ThirdParty/tgcalls/tgcalls/desktop_capturer/DesktopCaptureSourceManager.cpp
+@@ -33,7 +33,7 @@
+     result.set_allow_use_magnification_api(false);
+ #elif defined WEBRTC_MAC
+     result.set_allow_iosurface(type == DesktopCaptureType::Screen);
+-#elif defined WEBRTC_LINUX
++#elif defined WEBRTC_USE_PIPEWIRE
+     result.set_allow_pipewire(true);
+ #endif // WEBRTC_WIN || WEBRTC_MAC
+     result.set_detect_updated_region(true);

diff --git a/net-im/telegram-desktop/telegram-desktop-2.8.11-r2.ebuild 
b/net-im/telegram-desktop/telegram-desktop-2.8.11-r2.ebuild
index becc983ec4b..940c5b1aed2 100644
--- a/net-im/telegram-desktop/telegram-desktop-2.8.11-r2.ebuild
+++ b/net-im/telegram-desktop/telegram-desktop-2.8.11-r2.ebuild
@@ -79,6 +79,7 @@ PATCHES=(
        "${FILESDIR}/tdesktop-2.8.10-jemalloc-only-telegram.patch"
        # Already upstream
        "${FILESDIR}/tdesktop-2.8.11-load-gtk-with-qlibrary.patch"
+       "${FILESDIR}/tdesktop-2.8.11-fix-build-without-pipewire.patch"
 )
 
 pkg_pretend() {

Reply via email to