commit:     cfef50a4102a42c11c6bfadcfbd74059c679f511
Author:     Esteve Varela Colominas <esteve.varela <AT> gmail <DOT> com>
AuthorDate: Tue Mar 25 08:34:56 2025 +0000
Commit:     Yixun Lan <dlan <AT> gentoo <DOT> org>
CommitDate: Tue Mar 25 10:17:37 2025 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=cfef50a4

net-im/telegram-desktop: Fix USE=webkit

Closes: https://github.com/gentoo/gentoo/pull/41274
Signed-off-by: Esteve Varela Colominas <esteve.varela <AT> gmail.com>
Signed-off-by: Yixun Lan <dlan <AT> gentoo.org>

 .../files/tdesktop-5.12.3-fix-webview.patch        | 34 ++++++++++++++++++++++
 .../telegram-desktop-5.12.3-r2.ebuild              |  1 +
 2 files changed, 35 insertions(+)

diff --git a/net-im/telegram-desktop/files/tdesktop-5.12.3-fix-webview.patch 
b/net-im/telegram-desktop/files/tdesktop-5.12.3-fix-webview.patch
new file mode 100644
index 000000000000..fa50da2627fd
--- /dev/null
+++ b/net-im/telegram-desktop/files/tdesktop-5.12.3-fix-webview.patch
@@ -0,0 +1,34 @@
+Fix error in building with USE=webkit
+
+In file included from 
/var/tmp/portage/net-im/telegram-desktop-5.12.3-r2/work/tdesktop-5.12.3-full/Telegram/lib_webview/webview/webview_dialog.cpp:13:
+/var/tmp/portage/net-im/telegram-desktop-5.12.3-r2/work/tdesktop-5.12.3-full/Telegram/lib_ui/ui/widgets/buttons.h:276:3:
 error: unknown type name 'nullptr_t'; did you mean 'std::nullptr_t'?
+  276 |                 nullptr_t,
+      |                 ^~~~~~~~~
+      |                 std::nullptr_t
+/usr/lib/gcc/x86_64-pc-linux-gnu/14/include/g++-v14/x86_64-pc-linux-gnu/bits/c++config.h:314:29:
 note: 'std::nullptr_t' declared here
+  314 |   typedef decltype(nullptr)     nullptr_t;
+      |                                 ^
+1 error generated.
+
+--- tdesktop-5.12.3-full.orig/Telegram/lib_ui/ui/widgets/buttons.cpp
++++ tdesktop-5.12.3-full/Telegram/lib_ui/ui/widgets/buttons.cpp
+@@ -795,7 +795,7 @@
+ 
+ SettingsButton::SettingsButton(
+       QWidget *parent,
+-      nullptr_t,
++      std::nullptr_t,
+       const style::SettingsButton &st)
+ : RippleButton(parent, st.ripple)
+ , _st(st)
+--- tdesktop-5.12.3-full.orig/Telegram/lib_ui/ui/widgets/buttons.h
++++ tdesktop-5.12.3-full/Telegram/lib_ui/ui/widgets/buttons.h
+@@ -273,7 +273,7 @@
+               const style::SettingsButton &st = st::defaultSettingsButton);
+       SettingsButton(
+               QWidget *parent,
+-              nullptr_t,
++              std::nullptr_t,
+               const style::SettingsButton &st = st::defaultSettingsButton);
+       ~SettingsButton();
+ 

diff --git a/net-im/telegram-desktop/telegram-desktop-5.12.3-r2.ebuild 
b/net-im/telegram-desktop/telegram-desktop-5.12.3-r2.ebuild
index c0b0c7b8f65d..2f3cd07f8ed1 100644
--- a/net-im/telegram-desktop/telegram-desktop-5.12.3-r2.ebuild
+++ b/net-im/telegram-desktop/telegram-desktop-5.12.3-r2.ebuild
@@ -80,6 +80,7 @@ PATCHES=(
        "${FILESDIR}"/tdesktop-5.2.2-libdispatch.patch
        "${FILESDIR}"/tdesktop-5.7.2-cstring.patch
        "${FILESDIR}"/tdesktop-5.8.3-cstdint.patch
+       "${FILESDIR}"/tdesktop-5.12.3-fix-webview.patch
 )
 
 pkg_pretend() {

Reply via email to