summaryrefslogtreecommitdiff
path: root/net-im/telegram-desktop/files
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2021-09-25 20:21:45 +0100
committerV3n3RiX <venerix@redcorelinux.org>2021-09-25 20:21:45 +0100
commitc719fdcee603a5a706a45d10cb598762d56a727d (patch)
tree620cbf137661399a3fb1eff92914204f9a970713 /net-im/telegram-desktop/files
parentcc4618c9ba3d974948ebf340b542d8cb01db2f55 (diff)
gentoo resync : 25.09.2021
Diffstat (limited to 'net-im/telegram-desktop/files')
-rw-r--r--net-im/telegram-desktop/files/tdesktop-3.1.0-fix-openssl3.patch19
-rw-r--r--net-im/telegram-desktop/files/tdesktop-3.1.0-jemalloc-only-telegram.patch35
2 files changed, 54 insertions, 0 deletions
diff --git a/net-im/telegram-desktop/files/tdesktop-3.1.0-fix-openssl3.patch b/net-im/telegram-desktop/files/tdesktop-3.1.0-fix-openssl3.patch
new file mode 100644
index 000000000000..2b92e8adce4f
--- /dev/null
+++ b/net-im/telegram-desktop/files/tdesktop-3.1.0-fix-openssl3.patch
@@ -0,0 +1,19 @@
+Fix openssl 3.x compatibility
+
+FIPS_mode_set was merely used to clean up resources. This isn't necessary
+anymore on the newer openssl version.
+
+There's still a lot of functions that are used that were deprecated. I hope
+upstream can fix those, as I'm unsure what to do with them.
+
+--- tdesktop-3.1.0-full.orig/Telegram/SourceFiles/core/utils.cpp
++++ tdesktop-3.1.0-full/Telegram/SourceFiles/core/utils.cpp
+@@ -124,7 +124,7 @@
+
+ void finish() {
+ CRYPTO_cleanup_all_ex_data();
+-#ifndef LIBRESSL_VERSION_NUMBER
++#if !defined(LIBRESSL_VERSION_NUMBER) && OPENSSL_VERSION_NUMBER < 0x20000000L
+ FIPS_mode_set(0);
+ #endif
+ ENGINE_cleanup();
diff --git a/net-im/telegram-desktop/files/tdesktop-3.1.0-jemalloc-only-telegram.patch b/net-im/telegram-desktop/files/tdesktop-3.1.0-jemalloc-only-telegram.patch
new file mode 100644
index 000000000000..7ad3e75e49ba
--- /dev/null
+++ b/net-im/telegram-desktop/files/tdesktop-3.1.0-jemalloc-only-telegram.patch
@@ -0,0 +1,35 @@
+Only link jemalloc for the Telegram binary
+
+Some combination of factors is making the different codegen tools hang when
+jemalloc is linked for those, and they're ran under portage's sandbox. Since
+this is only used during build-time, and jemalloc is merely necessary to
+improve runtime memory use, it's unnecessary to use it for anything else.
+
+--- tdesktop-3.1.0-full.orig/Telegram/CMakeLists.txt
++++ tdesktop-3.1.0-full/Telegram/CMakeLists.txt
+@@ -1256,6 +1256,11 @@
+ endif()
+ endif()
+ else()
++ target_link_libraries(Telegram
++ PRIVATE
++ desktop-app::external_jemalloc
++ )
++
+ if (NOT DESKTOP_APP_DISABLE_DBUS_INTEGRATION)
+ target_link_libraries(Telegram
+ PRIVATE
+--- tdesktop-3.1.0-full.orig/cmake/options_linux.cmake
++++ tdesktop-3.1.0-full/cmake/options_linux.cmake
+@@ -45,11 +45,6 @@
+ target_link_options(common_options INTERFACE $<IF:$<CONFIG:Debug>,,-g -flto -fuse-linker-plugin>)
+ endif()
+
+-target_link_libraries(common_options
+-INTERFACE
+- desktop-app::external_jemalloc
+-)
+-
+ if (DESKTOP_APP_USE_ALLOCATION_TRACER)
+ target_link_options(common_options
+ INTERFACE