diff --git a/net/tdesktop/Makefile b/net/tdesktop/Makefile index 4658bcf0312..c695a32be9d 100644 --- a/net/tdesktop/Makefile +++ b/net/tdesktop/Makefile @@ -5,11 +5,10 @@ NOT_FOR_ARCHS = ${BE_ARCHS} i386 COMMENT = Telegram Desktop messenger PORTROACH = limit:-full$$ -V = 4.2.4 +V = 4.3.1 DISTNAME = tdesktop-${V}-full PKGNAME = ${DISTNAME:-full=} CATEGORIES = net -REVISION = 1 DPB_PROPERTIES = parallel @@ -27,9 +26,9 @@ PERMIT_PACKAGE = Yes WANTLIB += ${COMPILER_LIBCXX} Qt6Core Qt6Core5Compat Qt6DBus Qt6Gui Qt6Network WANTLIB += Qt6OpenGL Qt6OpenGLWidgets Qt6Svg Qt6Widgets absl_strings -WANTLIB += avcodec avformat avutil c crypto dispatch gio-2.0 giomm-2.4 -WANTLIB += glib-2.0 glibmm-2.4 gobject-2.0 hunspell-1.7 jpeg lz4 -WANTLIB += m openal qrcodegencpp rnnoise sigc-2.0 swresample swscale +WANTLIB += avcodec avformat avutil c crypto dispatch gio-2.0 giomm-2.68 +WANTLIB += glib-2.0 glibmm-2.68 gobject-2.0 hunspell-1.7 jpeg lz4 +WANTLIB += m openal qrcodegencpp rnnoise sigc-3.0 swresample swscale WANTLIB += tg_owt xcb xcb-keysyms xcb-record xcb-screensaver xxhash WANTLIB += z @@ -52,9 +51,9 @@ LIB_DEPENDS = archivers/lz4 \ audio/openal \ devel/abseil-cpp \ devel/glib2 \ - devel/glib2mm \ + devel/glibmm268 \ devel/libdispatch \ - devel/libsigc++-2 \ + devel/libsigc++30 \ graphics/ffmpeg \ graphics/qr-code-generator>=1.7.0p1 \ net/tg_owt>=0.0.0.20220909 \ diff --git a/net/tdesktop/distinfo b/net/tdesktop/distinfo index 773a5041432..d5c05ac2075 100644 --- a/net/tdesktop/distinfo +++ b/net/tdesktop/distinfo @@ -1,2 +1,2 @@ -SHA256 (tdesktop-4.2.4-full.tar.gz) = qBCfzp1VVT78vHw9k0mGnh4mcRP1utr0jPTgwlzVWdE= -SIZE (tdesktop-4.2.4-full.tar.gz) = 49210806 +SHA256 (tdesktop-4.3.1-full.tar.gz) = PB2MCbcttcn14tO0Z7RRprqUw7qClbmICEKk40lhU90= +SIZE (tdesktop-4.3.1-full.tar.gz) = 49305237 diff --git a/net/tdesktop/patches/patch-Telegram_CMakeLists_txt b/net/tdesktop/patches/patch-Telegram_CMakeLists_txt index 502736554fe..e5c8bba00f1 100644 --- a/net/tdesktop/patches/patch-Telegram_CMakeLists_txt +++ b/net/tdesktop/patches/patch-Telegram_CMakeLists_txt @@ -12,7 +12,7 @@ Index: Telegram/CMakeLists.txt include(cmake/lib_tgcalls.cmake) include(cmake/td_export.cmake) include(cmake/td_mtproto.cmake) -@@ -52,9 +51,7 @@ target_prepare_qrc(Telegram) +@@ -51,9 +50,7 @@ set_target_properties(Telegram PROPERTIES AUTOMOC ON) target_link_libraries(Telegram PRIVATE diff --git a/net/tdesktop/patches/patch-Telegram_SourceFiles_platform_linux_notifications_manager_linux_cpp b/net/tdesktop/patches/patch-Telegram_SourceFiles_platform_linux_notifications_manager_linux_cpp new file mode 100644 index 00000000000..803f70b99d5 --- /dev/null +++ b/net/tdesktop/patches/patch-Telegram_SourceFiles_platform_linux_notifications_manager_linux_cpp @@ -0,0 +1,55 @@ +Index: Telegram/SourceFiles/platform/linux/notifications_manager_linux.cpp +--- Telegram/SourceFiles/platform/linux/notifications_manager_linux.cpp.orig ++++ Telegram/SourceFiles/platform/linux/notifications_manager_linux.cpp +@@ -67,12 +67,17 @@ std::unique_ptr + try { + const auto connection = Gio::DBus::Connection::get_sync( + Gio::DBus::BusType::SESSION); ++ const auto GlibNames = ++ base::Platform::DBus::ListActivatableNames(connection); ++ const std::vector StringNames( ++ GlibNames.begin(), GlibNames.end() ++ ); + + const auto activatable = [&] { + try { + return ranges::contains( +- base::Platform::DBus::ListActivatableNames(connection), +- Glib::ustring(std::string(kService))); ++ StringNames, ++ std::string(kService)); + } catch (...) { + // avoid service restart loop in sandboxed environments + return true; +@@ -121,7 +126,7 @@ void StartServiceAsync(Fn callback) { + }; + + const auto errorName = +- Gio::DBus::ErrorUtils::get_remote_error(e); ++ Gio::DBus::ErrorUtils::get_remote_error(e).raw(); + + if (!ranges::contains(NotSupportedErrors, errorName)) { + throw e; +@@ -143,6 +148,11 @@ bool GetServiceRegistered() { + try { + const auto connection = Gio::DBus::Connection::get_sync( + Gio::DBus::BusType::SESSION); ++ const auto GlibNames = ++ base::Platform::DBus::ListActivatableNames(connection); ++ const std::vector StringNames( ++ GlibNames.begin(), GlibNames.end() ++ ); + + const auto hasOwner = [&] { + try { +@@ -157,8 +167,8 @@ bool GetServiceRegistered() { + static const auto activatable = [&] { + try { + return ranges::contains( +- DBus::ListActivatableNames(connection), +- Glib::ustring(std::string(kService))); ++ StringNames, ++ std::string(kService)); + } catch (...) { + return false; + } diff --git a/net/tdesktop/patches/patch-Telegram_lib_base_base_platform_linux_base_last_input_linux_cpp b/net/tdesktop/patches/patch-Telegram_lib_base_base_platform_linux_base_last_input_linux_cpp new file mode 100644 index 00000000000..e580b53c0a2 --- /dev/null +++ b/net/tdesktop/patches/patch-Telegram_lib_base_base_platform_linux_base_last_input_linux_cpp @@ -0,0 +1,23 @@ +XXX bring glibmm268's Glib::ustring and range-v3 together + +Index: Telegram/lib_base/base/platform/linux/base_last_input_linux.cpp +--- Telegram/lib_base/base/platform/linux/base_last_input_linux.cpp.orig ++++ Telegram/lib_base/base/platform/linux/base_last_input_linux.cpp +@@ -103,7 +103,7 @@ std::optional FreedesktopDBusLastUserInputT + "org.freedesktop.DBus.Error.AccessDenied", + }; + +- const auto errorName = Gio::DBus::ErrorUtils::get_remote_error(e); ++ const auto errorName = Gio::DBus::ErrorUtils::get_remote_error(e).raw(); + if (ranges::contains(NotSupportedErrors, errorName)) { + NotSupported = true; + return std::nullopt; +@@ -163,7 +163,7 @@ std::optional MutterDBusLastUserInputTime() + "org.freedesktop.DBus.Error.AccessDenied", + }; + +- const auto errorName = Gio::DBus::ErrorUtils::get_remote_error(e); ++ const auto errorName = Gio::DBus::ErrorUtils::get_remote_error(e).raw(); + if (ranges::contains(NotSupportedErrors, errorName)) { + NotSupported = true; + return std::nullopt;