summaryrefslogtreecommitdiff
path: root/net-im/telegram-desktop
diff options
context:
space:
mode:
authorV3n3RiX <venerix@koprulu.sector>2022-08-23 08:44:14 +0100
committerV3n3RiX <venerix@koprulu.sector>2022-08-23 08:44:14 +0100
commit05a34d98821265bf73820931936f86704b9002c6 (patch)
tree0695bbc0d5d5ec59f2d1d6a1a99d4717d5294fe4 /net-im/telegram-desktop
parentf019a919bf109460ee009a5f9210b99d0467db97 (diff)
gentoo auto-resync : 23:08:2022 - 08:44:14
Diffstat (limited to 'net-im/telegram-desktop')
-rw-r--r--net-im/telegram-desktop/Manifest6
-rw-r--r--net-im/telegram-desktop/files/tdesktop-3.3.0-fix-enchant.patch2
-rw-r--r--net-im/telegram-desktop/files/tdesktop-3.6.0-jemalloc-only-telegram.patch2
-rw-r--r--net-im/telegram-desktop/telegram-desktop-4.1.1.ebuild181
4 files changed, 189 insertions, 2 deletions
diff --git a/net-im/telegram-desktop/Manifest b/net-im/telegram-desktop/Manifest
index 517141f21542..a29fc4a2143d 100644
--- a/net-im/telegram-desktop/Manifest
+++ b/net-im/telegram-desktop/Manifest
@@ -1,14 +1,16 @@
-AUX tdesktop-3.3.0-fix-enchant.patch 819 BLAKE2B f827deca269c32648e438642a916383e6184ef3fbdb045c8950997b3a30c6231336fe54a3b39ae5b2b93e7c6c72d0080f00a535dcf6932bbe3740041ba79abc8 SHA512 2653dd30699633c55e590744ed1fb2104b473d43e6391ece791bf3543cac7de594a75d303dc66dd9c7b75face5e90615da261d10758e50e1c669ad0b4f27923f
+AUX tdesktop-3.3.0-fix-enchant.patch 851 BLAKE2B 11993329f16ba959516da010046c9ba0ad6f7a4c4e1ad1e2da436d3df674c0800f4136a57db14899e4ad54b32d4839714b50e82ac07f2a3bfa713d4ec19d3d8c SHA512 2b1074f6bae54ac5b58b85cff93f37c262f67c50fe0af8463d657ae04313197ffa075988590a3fbf70e44b03b618e65d6d6a40de748b98eac6005499aa02292e
AUX tdesktop-3.5.2-jemalloc-only-telegram.patch 1032 BLAKE2B 8220f745febaec55b85f64e25a860f9cfee57bf07496e0bf496857686c5bf7bdfb9c9ede94f9374dea677f1516e8dff39cae5b3a993d1c0fe32d34cf0c91015e SHA512 156a62d5d2145559828466e4c09c23cf8a0cd0cb9d844c27d50945135d854a2e0af45cb3e0dc675e21f74dc2f323574a785e259e86f4120d055aa0e34fd20ea9
AUX tdesktop-3.5.2-jemalloc-optional.patch 2924 BLAKE2B fa0c124fc38d83434eff5c2e03f815d9e32b3af62782401251905db293d8016618f9c51b333a7a4e86e9d529a1e8747495b982ad9e5d6c19c2d9c63b39391461 SHA512 de836736fdc5bcd2f581cd43223dff9ffe82042440e44f6038d2d0278fa94777054badd2870deb1f7c8285a35a5f01cfeccbd76701aeaf5ca9a573d8fbc9ed31
AUX tdesktop-3.5.2-musl.patch 890 BLAKE2B e65419eac920eb7c6929559229e50458fca0e9598b9e173f332b98235dc7d84acd01f5ceb23462b0fb53edbbeec8747e6f27e49cab8bc596b0c1ded205e6358c SHA512 57a811629749c285d3f181ad714afa322e0b65758114283f506319a076aa0410f5e9a75f6fad5642fe5611745c418b404d95a616d53ac8360fbff5cf170627ba
-AUX tdesktop-3.6.0-jemalloc-only-telegram.patch 1343 BLAKE2B bc257ee3bc3577b05a73b74c6394592b4636e605eb06c25a6749a38f2742104e1d214234524cbd5191bb397b22a4af4ba28c25c01520973a4f10e08bf3ba3bd2 SHA512 00067d388bd75adfcf7f2f460d99c283dd0110d33be5124585665b2566ef5c2b15100e8f86685bde2216083131609918861d7db845f4813ec303a13d8c423ae7
+AUX tdesktop-3.6.0-jemalloc-only-telegram.patch 1375 BLAKE2B 43d5cf05bcb7f66c32cdb9ff3bab04cbf71eba0be79623adeae521549a9d85fe06f0dd964828a4f7f9103eff9aa2bc150c6d41a298edc143367cc9511d95ef5a SHA512 8de226cfbe003899eac26bab9c0440c4e4042a11c985ea8967812961c2e89d6c7cc577bd349f12bb8470e21fdc19a044268d20606a7f1a3b9c9a1e8b9edde488
AUX tdesktop-3.6.0-support-ffmpeg5.patch 3142 BLAKE2B f05816a8b26c3061c88b8814adc2402981836ab7853be1dad9c4eb74b621e1084a2167ad5ea86d500c98d627317ffd48288bcb4df897f5ca6858516ecf86c8f0 SHA512 811f42f8372102910be20ac92030b98ad98704cb1378a90d17a01b15dc4a9aa8e9b6bb179a9dc4d09687ad7b60030f0f7367f8058674244b080748bf2c913044
AUX tdesktop-3.6.1-fix-kwayland-5.93.patch 1835 BLAKE2B dbc414e1543be96faff179288eb4bcc4acdfbe280ae51da11d254054adcc00f4c1387cdc9a24e026e06612d55765a1689b4bfc6381349b75053c4156a0cff71f SHA512 82855396f367f3669a34246a031626bba158d5361ec39e728c2d33f0d5b9ff5196c38a33551614848b5d439e25bbe45eb3795eaf7ca7442f5f27ab0bdeb0e72e
AUX tdesktop-3.6.1-fix-use-after-free.patch 1627 BLAKE2B 867dde2d1d8d6535e2305f841fe97477bd08c37e96684196563f9ce6dbfb12c7b2941ddc3e00182126e24ec08e1692ec201006d2c46548fcbf2f9bae09dca532 SHA512 e52369b6aee6c772bef56b73cf4656813614694af714eb83432ffbe7a2234dde4be9888e927c1304350c5c31a0a9cf37a53ea41df2e9b47a00de6dc4433a1c1b
AUX tdesktop-4.0.2-fix-gcc12-cstdint.patch 254 BLAKE2B f455f9878e7563ff65da62c71d495d5fb01b244f6fcc7f0e99ea6f30087c34c47be7ece315ff0cf35f2927b072a45bba3c219d15d291f2f22d50a117341a7d90 SHA512 114f3c44b0b9dfe9aa0d28617d83100859f781bca431515eed37dcaf52bb4cbc4c746d1c9c439999e65bd4fb360b72892b66da60325fe5d3c9c916d0337ff3b0
DIST tdesktop-3.6.1-full.tar.gz 41226549 BLAKE2B 6922ae015e36f86597aaedf1212ed951d6313a8f5f76a8838ab7ef9e02afe0cbc428acd991488190bafdf28faf2a69a09a5a1e963b2aa6ed27ef941602e15d88 SHA512 dd216c720ea3b1c72669805bb31319746a7ddfe746d188bf2ae0c5cdf0a10b379fc2e888a26fe755d77381fc5d9aa638cedc76b2dce1f1126a9c1ef9c02da2ba
DIST tdesktop-4.0.2-full.tar.gz 41059443 BLAKE2B da4efb15c8a2d11719d3aa56c3a40b12f70c37577d2909c43e6029e10ca0bb1f8445ed68ed9acd532009c8e0a8f48fa13d2a51573a81f58a8a83b13427ffb631 SHA512 0078b627d06dd8e655bd2bcc222ecbb3b15b7d88f858810bccdca84793ad02a60f4a4bf3808838752d65d4f6cffa3ddb5f70c5afc8e94cb6edae52101362feeb
+DIST tdesktop-4.1.1-full.tar.gz 41431505 BLAKE2B 7faf8d3a1e6d1ccb621f7a5af89c9b680fe515fbf4994f05d899ec44b8dc863440a368194a0237bef09078d14b5c670749276765da28ac6118787b6584fcbc01 SHA512 3240b9f81c3901997b1ea13fd7db7b8598b31c0faa68a2f711909ed11f33345db5a45ac99c0be77f1caeb1f571093ea42b1dbc7e7bb15e989c8756805c2ec887
EBUILD telegram-desktop-3.6.1-r1.ebuild 4886 BLAKE2B e82263eb280dbf9443beaeeaf960be7381953c69cfc6c800aae6b8d02a273350062dd42d31f85467990c71584c6f6d33ee811260ef202866cd4df9ef65e4b190 SHA512 3a700af06f41db67a8d33ed6e2def3ab38d95770b41b444921725ef00cb5fcced425adfa3bfb69942cee5539a8284fd587df495fb43b4d4673a5f62cfa2ceb27
EBUILD telegram-desktop-4.0.2.ebuild 5930 BLAKE2B 4ff1480dcfaddecc7a4dfda6f325dd41def87d1da08e0389c2db378a4fa7fac8f1a63abaecd67c1a2f9ca47f2a672b011457e2c3783d6b268d3d92636ca70a31 SHA512 6ecd4d7733639eb0d2e7ede117286ffc23f2c045eb59e6a447f855d0f15f97cbed6d3e2bfe53e18a7f8606499a4a87c8b7e672a752fdd9c3c2f5b4f6947152c0
+EBUILD telegram-desktop-4.1.1.ebuild 5814 BLAKE2B 34fad93a61526c9751561afd15377feabb1b96b622d4ffb7d5b66569c7181bd7e6c5d81bb60078336f848efca33ec87aaf4b487497ac4cd822f9eb2290bc394c SHA512 716ac189b72979e01654e1cf1e78a88b169832fb4ca8c3b8c269541b78e5a9425b7dfca35b226eac79ff8631c1f5a1341f03f7c6cff0320afd8859df64ece8c3
MISC metadata.xml 637 BLAKE2B 643abb06bad4683b713dfd6a697e13540f911aef5b55ad79c41d8076dcca5a96ae40c80131329f8240a8d382c81c788142f71e5b8f8b8b0870a1767eb8fa3c22 SHA512 bfe3f00d0f6b3b65962475ae0641f527f115baaccb6069653c31fe1f2a0096a7e90bfe58ffc037edddb8541a898def866ce6b4036b4a592d6f8ed4a8decf1fb4
diff --git a/net-im/telegram-desktop/files/tdesktop-3.3.0-fix-enchant.patch b/net-im/telegram-desktop/files/tdesktop-3.3.0-fix-enchant.patch
index 35781fda0ced..7550828ef59e 100644
--- a/net-im/telegram-desktop/files/tdesktop-3.3.0-fix-enchant.patch
+++ b/net-im/telegram-desktop/files/tdesktop-3.3.0-fix-enchant.patch
@@ -1,3 +1,5 @@
+https://bugs.gentoo.org/830180
+
--- tdesktop-3.3.0-full.orig/Telegram/lib_spellcheck/spellcheck/platform/linux/spellcheck_linux.cpp
+++ tdesktop-3.3.0-full/Telegram/lib_spellcheck/spellcheck/platform/linux/spellcheck_linux.cpp
@@ -34,7 +34,7 @@
diff --git a/net-im/telegram-desktop/files/tdesktop-3.6.0-jemalloc-only-telegram.patch b/net-im/telegram-desktop/files/tdesktop-3.6.0-jemalloc-only-telegram.patch
index 6836e6935049..18240ce522e2 100644
--- a/net-im/telegram-desktop/files/tdesktop-3.6.0-jemalloc-only-telegram.patch
+++ b/net-im/telegram-desktop/files/tdesktop-3.6.0-jemalloc-only-telegram.patch
@@ -5,6 +5,8 @@ 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.
+https://bugs.gentoo.org/802624
+
--- tdesktop-3.6.0-full.orig/Telegram/CMakeLists.txt
+++ tdesktop-3.6.0-full/Telegram/CMakeLists.txt
@@ -1376,6 +1376,14 @@
diff --git a/net-im/telegram-desktop/telegram-desktop-4.1.1.ebuild b/net-im/telegram-desktop/telegram-desktop-4.1.1.ebuild
new file mode 100644
index 000000000000..363e89f23081
--- /dev/null
+++ b/net-im/telegram-desktop/telegram-desktop-4.1.1.ebuild
@@ -0,0 +1,181 @@
+# Copyright 2020-2022 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+PYTHON_COMPAT=( python3_{8..11} )
+
+inherit xdg cmake python-any-r1 optfeature
+
+DESCRIPTION="Official desktop client for Telegram"
+HOMEPAGE="https://desktop.telegram.org"
+
+MY_P="tdesktop-${PV}-full"
+SRC_URI="https://github.com/telegramdesktop/tdesktop/releases/download/v${PV}/${MY_P}.tar.gz"
+S="${WORKDIR}/${MY_P}"
+
+LICENSE="BSD GPL-3-with-openssl-exception LGPL-2+"
+SLOT="0"
+KEYWORDS="~amd64 ~arm64 ~ppc64 ~riscv"
+IUSE="+dbus enchant +hunspell +jemalloc screencast +spell qt6 wayland +X"
+REQUIRED_USE="
+ spell? (
+ ^^ ( enchant hunspell )
+ )
+"
+
+RDEPEND="
+ !net-im/telegram-desktop-bin
+ app-arch/lz4:=
+ dev-cpp/abseil-cpp:=
+ dev-libs/libdispatch
+ dev-libs/openssl:=
+ dev-libs/xxhash
+ media-fonts/open-sans
+ media-libs/fontconfig:=
+ ~media-libs/libtgvoip-2.4.4_p20220503
+ media-libs/openal
+ media-libs/opus:=
+ media-libs/rnnoise
+ ~media-libs/tg_owt-0_pre20220507[screencast=,X=]
+ media-video/ffmpeg:=[opus]
+ sys-libs/zlib:=[minizip]
+ dbus? ( dev-cpp/glibmm:2 )
+ enchant? ( app-text/enchant:= )
+ hunspell? ( >=app-text/hunspell-1.7:= )
+ jemalloc? ( dev-libs/jemalloc:=[-lazy-lock] )
+ !qt6? (
+ >=dev-qt/qtcore-5.15:5
+ >=dev-qt/qtgui-5.15:5[dbus?,jpeg,png,wayland?,X?]
+ >=dev-qt/qtimageformats-5.15:5
+ >=dev-qt/qtnetwork-5.15:5[ssl]
+ >=dev-qt/qtsvg-5.15:5
+ >=dev-qt/qtwidgets-5.15:5[png,X?]
+ )
+ qt6? (
+ dev-qt/qtbase:6[dbus?,gui,network,opengl,widgets,X?]
+ dev-qt/qtsvg:6
+ dev-qt/qt5compat:6
+ wayland? ( dev-qt/qtwayland:6 )
+ )
+ X? ( x11-libs/libxcb:= )
+"
+DEPEND="${RDEPEND}
+ dev-cpp/range-v3
+ =dev-cpp/ms-gsl-3*
+"
+BDEPEND="
+ ${PYTHON_DEPS}
+ >=dev-util/cmake-3.16
+ virtual/pkgconfig
+"
+# dev-libs/jemalloc:=[-lazy-lock] -> https://bugs.gentoo.org/803233
+
+PATCHES=(
+ "${FILESDIR}/tdesktop-3.6.0-jemalloc-only-telegram.patch"
+ "${FILESDIR}/tdesktop-3.3.0-fix-enchant.patch"
+ "${FILESDIR}/tdesktop-3.5.2-musl.patch"
+ "${FILESDIR}/tdesktop-4.0.2-fix-gcc12-cstdint.patch"
+)
+
+# Current desktop-file-utils-0.26 does not understand Version=1.5
+QA_DESKTOP_FILE="usr/share/applications/${PN}.desktop"
+
+pkg_pretend() {
+ if has ccache ${FEATURES}; then
+ ewarn "ccache does not work with ${PN} out of the box"
+ ewarn "due to usage of precompiled headers"
+ ewarn "check bug https://bugs.gentoo.org/715114 for more info"
+ ewarn
+ fi
+ if use qt6; then
+ ewarn "Qt6 support in gentoo is experimental."
+ ewarn "Please report any issues you may find, but don't expect"
+ ewarn "everything to work correctly as of yet."
+ ewarn
+ fi
+}
+
+src_prepare() {
+ # no explicit toggle, doesn't build with the system one #752417
+ sed -i 's/DESKTOP_APP_USE_PACKAGED/NO_ONE_WILL_EVER_SET_THIS/' \
+ cmake/external/rlottie/CMakeLists.txt || die
+
+ cmake_src_prepare
+}
+
+src_configure() {
+ # DESKTOP_APP_DISABLE_JEMALLOC is heavily discouraged by upstream, as the
+ # glibc allocator results in high memory usage.
+ # https://github.com/telegramdesktop/tdesktop/issues/16084
+ # https://github.com/desktop-app/cmake_helpers/pull/91#issuecomment-881788003
+
+ # DESKTOP_APP_QT6=OFF force-enables DESKTOP_APP_DISABLE_WAYLAND_INTEGRATION
+ # This means that REQUIRED_USE="wayland? ( qt6 )", but a lot of people
+ # enable USE=wayland globally, so we instead silently disable it...
+
+ local mycmakeargs=(
+ -DTDESKTOP_LAUNCHER_BASENAME="${PN}"
+ -DCMAKE_DISABLE_FIND_PACKAGE_tl-expected=ON # header only lib, some git version. prevents warnings.
+ -DDESKTOP_APP_QT6=$(usex qt6)
+
+ -DDESKTOP_APP_DISABLE_DBUS_INTEGRATION=$(usex !dbus)
+ -DDESKTOP_APP_DISABLE_X11_INTEGRATION=$(usex !X)
+ -DDESKTOP_APP_DISABLE_WAYLAND_INTEGRATION=$(usex !wayland)
+ -DDESKTOP_APP_DISABLE_JEMALLOC=$(usex !jemalloc)
+ -DDESKTOP_APP_DISABLE_SPELLCHECK=$(usex !spell) # enables hunspell (recommended)
+ -DDESKTOP_APP_USE_ENCHANT=$(usex enchant) # enables enchant and disables hunspell
+ )
+
+ if [[ -n ${MY_TDESKTOP_API_ID} && -n ${MY_TDESKTOP_API_HASH} ]]; then
+ einfo "Found custom API credentials"
+ mycmakeargs+=(
+ -DTDESKTOP_API_ID="${MY_TDESKTOP_API_ID}"
+ -DTDESKTOP_API_HASH="${MY_TDESKTOP_API_HASH}"
+ )
+ else
+ # https://github.com/telegramdesktop/tdesktop/blob/dev/snap/snapcraft.yaml
+ # Building with snapcraft API credentials by default
+ # Custom API credentials can be obtained here:
+ # https://github.com/telegramdesktop/tdesktop/blob/dev/docs/api_credentials.md
+ # After getting credentials you can export variables:
+ # export MY_TDESKTOP_API_ID="17349""
+ # export MY_TDESKTOP_API_HASH="344583e45741c457fe1862106095a5eb"
+ # and restart the build"
+ # you can set above variables (without export) in /etc/portage/env/net-im/telegram-desktop
+ # portage will use custom variable every build automatically
+ mycmakeargs+=(
+ -DTDESKTOP_API_ID="611335"
+ -DTDESKTOP_API_HASH="d524b414d21f4d37f08684c1df41ac9c"
+ )
+ fi
+
+ cmake_src_configure
+}
+
+pkg_postinst() {
+ xdg_pkg_postinst
+ if ! use X && ! use screencast; then
+ elog "both the 'X' and 'screencast' useflags are disabled, screen sharing won't work!"
+ elog
+ fi
+ if has_version '<dev-qt/qtcore-5.15.2-r10'; then
+ ewarn "Versions of dev-qt/qtcore lower than 5.15.2-r10 might cause telegram"
+ ewarn "to crash when pasting big images from the clipboard."
+ ewarn
+ fi
+ if ! use jemalloc && use elibc_glibc; then
+ ewarn "Disabling USE=jemalloc on glibc systems may cause very high RAM usage!"
+ ewarn "Do NOT report issues about RAM usage without enabling this flag first."
+ ewarn
+ fi
+ if use wayland && ! use qt6; then
+ ewarn "Wayland-specific integrations have been deprecated with Qt5."
+ ewarn "The app will continue to function under wayland, but some"
+ ewarn "functionality may be reduced."
+ ewarn "These integrations are only supported when built with Qt6."
+ ewarn
+ fi
+ optfeature_header
+ optfeature "shop payment support (requires USE=dbus enabled)" net-libs/webkit-gtk
+}