From f6c5598f54ebe442debef526b6baf9fdbeb4d1da Mon Sep 17 00:00:00 2001 From: Michael Weiss Date: Fri, 23 Jul 2021 13:27:41 +0200 Subject: [PATCH] tdesktop: Cleanup/refactor Drop old/outdated comments and some reordering for consistency. --- .../telegram/tdesktop/default.nix | 22 +++++-------------- .../telegram/tdesktop/tg_owt.nix | 4 ++-- pkgs/top-level/all-packages.nix | 4 +++- 3 files changed, 10 insertions(+), 20 deletions(-) diff --git a/pkgs/applications/networking/instant-messengers/telegram/tdesktop/default.nix b/pkgs/applications/networking/instant-messengers/telegram/tdesktop/default.nix index 31aec0a4678..1eb4b222f20 100644 --- a/pkgs/applications/networking/instant-messengers/telegram/tdesktop/default.nix +++ b/pkgs/applications/networking/instant-messengers/telegram/tdesktop/default.nix @@ -1,11 +1,13 @@ { mkDerivation, lib, fetchFromGitHub, callPackage, fetchpatch , pkg-config, cmake, ninja, python3, wrapGAppsHook, wrapQtAppsHook +, extra-cmake-modules , qtbase, qtimageformats, gtk3, libsForQt5, lz4, xxHash , ffmpeg, openalSoft, minizip, libopus, alsa-lib, libpulseaudio, range-v3 , tl-expected, hunspell, glibmm, webkitgtk, jemalloc -, rnnoise, extra-cmake-modules +, rnnoise # Transitive dependencies: -, pcre, xorg, util-linuxMinimal, libselinux, libsepol, epoxy +, util-linuxMinimal +, pcre, libpthreadstubs, libXdmcp, libselinux, libsepol, epoxy , at-spi2-core, libXtst, libthai, libdatrie , xdg-utils, libsysprof-capture, libpsl, brotli }: @@ -72,7 +74,7 @@ in mkDerivation rec { tg_owt # Transitive dependencies: util-linuxMinimal # Required for libmount thus not nativeBuildInputs. - pcre xorg.libpthreadstubs xorg.libXdmcp libselinux libsepol epoxy + pcre libpthreadstubs libXdmcp libselinux libsepol epoxy at-spi2-core libXtst libthai libdatrie libsysprof-capture libpsl brotli ]; @@ -85,20 +87,6 @@ in mkDerivation rec { "-DDESKTOP_APP_USE_PACKAGED_FONTS=OFF" ]; - # Note: The following packages could be packaged system-wide, but it's - # probably best to use the bundled ones from tdesktop (Arch does this too): - # rlottie: - # - Sources (problem: there are no stable releases!): - # - desktop-app (tdesktop): https://github.com/desktop-app/rlottie - # - upstream: https://github.com/Samsung/rlottie - # libtgvoip: - # - Sources (problem: the stable releases might be too old!): - # - tdesktop: https://github.com/telegramdesktop/libtgvoip - # - upstream: https://github.com/grishka/libtgvoip - # Both of these packages are included in this PR (kotatogram-desktop): - # https://github.com/NixOS/nixpkgs/pull/75210 - # TODO: Package mapbox-variant - postFixup = '' # This is necessary to run Telegram in a pure environment. # We also use gappsWrapperArgs from wrapGAppsHook. diff --git a/pkgs/applications/networking/instant-messengers/telegram/tdesktop/tg_owt.nix b/pkgs/applications/networking/instant-messengers/telegram/tdesktop/tg_owt.nix index 363650dae5a..e553c95990e 100644 --- a/pkgs/applications/networking/instant-messengers/telegram/tdesktop/tg_owt.nix +++ b/pkgs/applications/networking/instant-messengers/telegram/tdesktop/tg_owt.nix @@ -1,9 +1,9 @@ -{ lib, stdenv, fetchFromGitHub, fetchpatch +{ lib, stdenv, fetchFromGitHub , pkg-config, cmake, ninja, yasm , libjpeg, openssl, libopus, ffmpeg, alsa-lib, libpulseaudio, protobuf , openh264, usrsctp, libevent, libvpx +, libX11, libXtst, libXcomposite, libXdamage, libXext, libXrender, libXrandr, libXi , glib, abseil-cpp, pcre, util-linuxMinimal, libselinux, libsepol, pipewire -, xorg, libX11, libXtst, libXcomposite, libXdamage, libXext, libXrender, libXrandr, libXi }: stdenv.mkDerivation { diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 5180fef9b2b..80eebdeb35f 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -27340,7 +27340,9 @@ in taskopen = callPackage ../applications/misc/taskopen { }; - tdesktop = qt5.callPackage ../applications/networking/instant-messengers/telegram/tdesktop { }; + tdesktop = qt5.callPackage ../applications/networking/instant-messengers/telegram/tdesktop { + inherit (xorg) libpthreadstubs libXdmcp; + }; tektoncd-cli = callPackage ../applications/networking/cluster/tektoncd-cli { };