diff --git a/net-im/telegram-desktop/Makefile b/net-im/telegram-desktop/Makefile index ebb2f7000a38..989f34f35dbb 100644 --- a/net-im/telegram-desktop/Makefile +++ b/net-im/telegram-desktop/Makefile @@ -1,92 +1,92 @@ PORTNAME= telegram-desktop -DISTVERSION= 2.7.4 -PORTREVISION= 1 +DISTVERSION= 2.8.11 CATEGORIES= net-im MASTER_SITES= https://github.com/${GH_ACCOUNT}/${GH_PROJECT}/releases/download/v${DISTVERSION}/ DISTNAME= tdesktop-${DISTVERSION}-full DISTFILES= ${DISTNAME}${EXTRACT_SUFX} MAINTAINER= henry.hu.sh@gmail.com COMMENT= Telegram Desktop messaging app LICENSE= GPLv3 LICENSE_FILE= ${WRKSRC}/LICENSE BROKEN_i386= Does not build, webrtc related. NOT_FOR_ARCHS= powerpc powerpc64 powerpcspe NOT_FOR_ARCHS_REASON= Only little endian is supported BUILD_DEPENDS= alsa-lib>0:audio/alsa-lib \ microsoft-gsl>0:devel/microsoft-gsl \ pulseaudio>0:audio/pulseaudio \ range-v3>0:devel/range-v3 \ tl-expected>0:devel/tl-expected \ v4l_compat>0:multimedia/v4l_compat \ yasm:devel/yasm \ ${LOCALBASE}/lib/libtg_owt.a:net-im/tg_owt LIB_DEPENDS= libavformat.so:multimedia/ffmpeg \ libdbus-1.so:devel/dbus \ libdbusmenu-qt5.so:devel/libdbusmenu-qt \ libenchant-2.so:textproc/enchant2 \ libhunspell-1.7.so:textproc/hunspell \ libjpeg.so:graphics/jpeg-turbo \ liblz4.so:archivers/liblz4 \ libminizip.so:archivers/minizip \ + librnnoise.so:audio/rnnoise \ libopenal.so:audio/openal-soft \ libopus.so:audio/opus \ libqrcodegencpp.so:graphics/qr-code-generator \ libusrsctp.so:net/libusrsctp \ libxkbcommon.so:x11/libxkbcommon \ libxxhash.so:devel/xxhash USES= cmake compiler:c++17-lang desktop-file-utils gl \ gnome pkgconfig python:3.7+,build qt:5 ssl xorg USE_GITHUB= nodefault GH_ACCOUNT= telegramdesktop GH_PROJECT= tdesktop USE_GL= gl USE_GNOME= glib20 glibmm INSTALLS_ICONS= yes USE_QT= core dbus gui imageformats network widgets buildtools_build \ qmake_build wayland USE_XORG= x11 xcb CMAKE_ARGS= -DDESKTOP_APP_SPECIAL_TARGET="" -DTDESKTOP_LAUNCHER_BASENAME="telegramdesktop" \ -DTDESKTOP_API_ID=${TELEGRAM_API_ID} -DTDESKTOP_API_HASH=${TELEGRAM_API_HASH} \ -Ddisable_autoupdate=1 CMAKE_ON= DESKTOP_APP_USE_PACKAGED DESKTOP_APP_DISABLE_CRASH_REPORTS \ TDESKTOP_DISABLE_REGISTER_CUSTOM_SCHEME TDESKTOP_DISABLE_DESKTOP_FILE_GENERATION \ DESKTOP_APP_DISABLE_WAYLAND_INTEGRATION CMAKE_OFF= DESKTOP_APP_USE_PACKAGED_RLOTTIE DESKTOP_APP_USE_PACKAGED_VARIANT \ DESKTOP_APP_USE_GLIBC_WRAPS TDESKTOP_USE_PACKAGED_TGVOIP \ DESKTOP_APP_USE_PACKAGED_FONTS # Disable DCHECKs, otherwise video calls will crash. CXXFLAGS+= -DNDEBUG # see Bugzilla #245452 for details NO_CCACHE= yes # Telegram uses OpenAL for its audio, but libtgvoip (for voice calls) can use PulseAudio or ALSA. # It dynamically loads PulseAudio, and if this fails, it loads ALSA. # If both of them are not installed, then voice calls do not work, but other functionalities still work. OPTIONS_DEFINE= GTK OPTIONS_DEFAULT= ALSA OPTIONS_MULTI= AUDIO OPTIONS_MULTI_AUDIO= ALSA PULSEAUDIO AUDIO_DESC= Audio backend for voice calls GTK_DESC= Gtk integration (Use Gtk dialogs, etc.) ALSA_LIB_DEPENDS= libasound.so:audio/alsa-lib GTK_CMAKE_BOOL_OFF= DESKTOP_APP_DISABLE_GTK_INTEGRATION GTK_LIB_DEPENDS= libwebkit2gtk-4.0.so:www/webkit2-gtk3 GTK_USE= GNOME=gtk30 PULSEAUDIO_LIB_DEPENDS= libpulse.so:audio/pulseaudio # Telegram asks each custom build to have its own API ID and hash. TELEGRAM_API_HASH= 20a3432aab43f24bb4460fceac5ba38d TELEGRAM_API_ID= 601761 .include diff --git a/net-im/telegram-desktop/distinfo b/net-im/telegram-desktop/distinfo index c8b0bb5b5e05..be2453ce719a 100644 --- a/net-im/telegram-desktop/distinfo +++ b/net-im/telegram-desktop/distinfo @@ -1,3 +1,3 @@ -TIMESTAMP = 1620514737 -SHA256 (tdesktop-2.7.4-full.tar.gz) = 97526f0b4adf04cf86b605ae84f3efaacf58eb8f828bab8f4fe752a4fac62fb2 -SIZE (tdesktop-2.7.4-full.tar.gz) = 36894673 +TIMESTAMP = 1626644072 +SHA256 (tdesktop-2.8.11-full.tar.gz) = 168487a59a8ae6ca1fbd66ccefc9eae19344af61bfb8d4cdde3cf73c115aa9dc +SIZE (tdesktop-2.8.11-full.tar.gz) = 37105468 diff --git a/net-im/telegram-desktop/files/patch-Telegram_SourceFiles_platform_linux_specific__linux.cpp b/net-im/telegram-desktop/files/patch-Telegram_SourceFiles_platform_linux_specific__linux.cpp new file mode 100644 index 000000000000..6a5dbdc9c42c --- /dev/null +++ b/net-im/telegram-desktop/files/patch-Telegram_SourceFiles_platform_linux_specific__linux.cpp @@ -0,0 +1,11 @@ +--- Telegram/SourceFiles/platform/linux/specific_linux.cpp.orig 2021-07-17 09:47:10 UTC ++++ Telegram/SourceFiles/platform/linux/specific_linux.cpp +@@ -48,7 +48,7 @@ https://github.com/telegramdesktop/tdesktop/blob/maste + #include + #include + #include +-#include ++#include + + #include + #include diff --git a/net-im/telegram-desktop/files/patch-Telegram_ThirdParty_tgcalls_tgcalls_Manager.cpp b/net-im/telegram-desktop/files/patch-Telegram_ThirdParty_tgcalls_tgcalls_Manager.cpp new file mode 100644 index 000000000000..4ad977ab7480 --- /dev/null +++ b/net-im/telegram-desktop/files/patch-Telegram_ThirdParty_tgcalls_tgcalls_Manager.cpp @@ -0,0 +1,13 @@ +--- Telegram/ThirdParty/tgcalls/tgcalls/Manager.cpp.orig 2021-07-21 01:10:26 UTC ++++ Telegram/ThirdParty/tgcalls/tgcalls/Manager.cpp +@@ -72,10 +72,6 @@ bool Manager::ResolvedNetworkStatus::operator==(const + return true; + } + +-bool Manager::ResolvedNetworkStatus::operator!=(const ResolvedNetworkStatus &rhs) { +- return !(*this == rhs); +-} +- + Manager::Manager(rtc::Thread *thread, Descriptor &&descriptor) : + _thread(thread), + _encryptionKey(descriptor.encryptionKey), diff --git a/net-im/telegram-desktop/files/patch-Telegram_ThirdParty_tgcalls_tgcalls_Manager.h b/net-im/telegram-desktop/files/patch-Telegram_ThirdParty_tgcalls_tgcalls_Manager.h new file mode 100644 index 000000000000..9f4cdb075506 --- /dev/null +++ b/net-im/telegram-desktop/files/patch-Telegram_ThirdParty_tgcalls_tgcalls_Manager.h @@ -0,0 +1,10 @@ +--- Telegram/ThirdParty/tgcalls/tgcalls/Manager.h.orig 2021-07-21 01:10:21 UTC ++++ Telegram/ThirdParty/tgcalls/tgcalls/Manager.h +@@ -17,7 +17,6 @@ class Manager final : public std::enable_shared_from_t + bool isLowDataRequested = false; + + bool operator==(const ResolvedNetworkStatus &rhs); +- bool operator!=(const ResolvedNetworkStatus &rhs); + }; + + public: diff --git a/net-im/telegram-desktop/files/patch-Telegram_lib__webview_webview_platform_linux_webview__linux__webkit__gtk.cpp b/net-im/telegram-desktop/files/patch-Telegram_lib__webview_webview_platform_linux_webview__linux__webkit__gtk.cpp deleted file mode 100644 index bc87e7122ff5..000000000000 --- a/net-im/telegram-desktop/files/patch-Telegram_lib__webview_webview_platform_linux_webview__linux__webkit__gtk.cpp +++ /dev/null @@ -1,11 +0,0 @@ ---- Telegram/lib_webview/webview/platform/linux/webview_linux_webkit_gtk.cpp.orig 2021-04-14 05:42:51 UTC -+++ Telegram/lib_webview/webview/platform/linux/webview_linux_webkit_gtk.cpp -@@ -38,7 +38,7 @@ bool Resolve() { - && LOAD_GTK_SYMBOL(gtk, gtk_window_get_type) - && LOAD_GTK_SYMBOL(gtk, gtk_window_set_decorated) - && LOAD_GTK_SYMBOL(gtk, gdk_x11_window_get_xid) -- && base::Platform::Gtk::LoadLibrary(webkit2gtk, "libwebkit2gtk-4.0.so.37", 0) -+ && base::Platform::Gtk::LoadLibrary(webkit2gtk, "libwebkit2gtk-4.0.so.37", 37) - && LOAD_GTK_SYMBOL(webkit2gtk, webkit_web_view_new) - && LOAD_GTK_SYMBOL(webkit2gtk, webkit_web_view_get_type) - && LOAD_GTK_SYMBOL(webkit2gtk, webkit_web_view_get_user_content_manager) diff --git a/net-im/telegram-desktop/files/patch-Telegram_lib__webview_webview_platform_linux_webview__linux__webkit__gtk.h b/net-im/telegram-desktop/files/patch-Telegram_lib__webview_webview_platform_linux_webview__linux__webkit__gtk.h deleted file mode 100644 index 64864b80978b..000000000000 --- a/net-im/telegram-desktop/files/patch-Telegram_lib__webview_webview_platform_linux_webview__linux__webkit__gtk.h +++ /dev/null @@ -1,13 +0,0 @@ ---- Telegram/lib_webview/webview/platform/linux/webview_linux_webkit_gtk.h.orig 2021-04-14 05:42:51 UTC -+++ Telegram/lib_webview/webview/platform/linux/webview_linux_webkit_gtk.h -@@ -11,9 +11,9 @@ - extern "C" { - #undef signals - #include -+#include - #include - #include --#include - #define signals public - } // extern "C" - diff --git a/net-im/telegram-desktop/files/patch-cmake_external_CMakeLists.txt b/net-im/telegram-desktop/files/patch-cmake_external_CMakeLists.txt new file mode 100644 index 000000000000..e2b542cb42f4 --- /dev/null +++ b/net-im/telegram-desktop/files/patch-cmake_external_CMakeLists.txt @@ -0,0 +1,12 @@ +--- cmake/external/CMakeLists.txt.orig 2021-07-13 19:08:45 UTC ++++ cmake/external/CMakeLists.txt +@@ -37,9 +37,6 @@ if (add_hunspell_library) + add_checked_subdirectory(hunspell) + endif() + add_checked_subdirectory(iconv) +-if (LINUX) +- add_checked_subdirectory(jemalloc) +-endif() + add_checked_subdirectory(jpeg) + if (LINUX AND NOT DESKTOP_APP_DISABLE_WAYLAND_INTEGRATION) + add_checked_subdirectory(kwayland) diff --git a/net-im/telegram-desktop/files/patch-cmake_options__linux.cmake b/net-im/telegram-desktop/files/patch-cmake_options__linux.cmake new file mode 100644 index 000000000000..aa6e5e7df10e --- /dev/null +++ b/net-im/telegram-desktop/files/patch-cmake_options__linux.cmake @@ -0,0 +1,14 @@ +--- cmake/options_linux.cmake.orig 2021-07-13 19:08:45 UTC ++++ cmake/options_linux.cmake +@@ -58,11 +58,6 @@ if (DESKTOP_APP_SPECIAL_TARGET) + endif() + endif() + +-target_link_libraries(common_options +-INTERFACE +- desktop-app::external_jemalloc +-) +- + if (DESKTOP_APP_USE_PACKAGED) + find_library(ATOMIC_LIBRARY atomic) + else()