Unverified Commit b7af891b authored by Tom van Dijk's avatar Tom van Dijk
Browse files

telegram-desktop: 5.15.4 -> 5.16.4

parent bf15e6ca
Loading
Loading
Loading
Loading
+13 −2
Original line number Diff line number Diff line
@@ -5,6 +5,10 @@
  fetchpatch,
  libsForQt5,
  yasm,
  alsa-lib,
  jemalloc,
  libopus,
  libpulseaudio,
  withWebkit ? true,
}:

@@ -38,7 +42,7 @@ in
telegram-desktop.override {
  pname = "kotatogram-desktop";
  inherit withWebkit;
  unwrapped = (telegram-desktop.unwrapped.override { inherit tg_owt; }).overrideAttrs {
  unwrapped = (telegram-desktop.unwrapped.override { inherit tg_owt; }).overrideAttrs (old: {
    pname = "kotatogram-desktop-unwrapped";
    version = "${version}-unstable-2024-09-27";

@@ -60,6 +64,13 @@ telegram-desktop.override {
      })
    ];

    buildInputs = (old.buildInputs or [ ]) ++ [
      alsa-lib
      jemalloc
      libopus
      libpulseaudio
    ];

    meta = {
      description = "Kotatogram – experimental Telegram Desktop fork";
      longDescription = ''
@@ -74,5 +85,5 @@ telegram-desktop.override {
      maintainers = with lib.maintainers; [ ilya-fedin ];
      mainProgram = if stdenv.hostPlatform.isLinux then "kotatogram-desktop" else "Kotatogram";
    };
  };
  });
}
+2 −19
Original line number Diff line number Diff line
@@ -20,14 +20,10 @@
  protobuf,
  openalSoft,
  minizip,
  libopus,
  alsa-lib,
  libpulseaudio,
  range-v3,
  tl-expected,
  hunspell,
  gobject-introspection,
  jemalloc,
  rnnoise,
  microsoft-gsl,
  boost,
@@ -46,25 +42,16 @@

stdenv.mkDerivation (finalAttrs: {
  pname = "telegram-desktop-unwrapped";
  version = "5.15.4";
  version = "5.16.4";

  src = fetchFromGitHub {
    owner = "telegramdesktop";
    repo = "tdesktop";
    rev = "v${finalAttrs.version}";
    fetchSubmodules = true;
    hash = "sha256-C7mUV/Jc0OJnVXxRGVx/l2T7APOsY05t5MLW8laIwnA=";
    hash = "sha256-yU2Ai2JgxDlaTK5GsL+yWkwtFbk14tPRAj1Rdt+gmmQ=";
  };

  postPatch = lib.optionalString stdenv.hostPlatform.isLinux ''
    substituteInPlace Telegram/ThirdParty/libtgvoip/os/linux/AudioInputALSA.cpp \
      --replace-fail '"libasound.so.2"' '"${lib.getLib alsa-lib}/lib/libasound.so.2"'
    substituteInPlace Telegram/ThirdParty/libtgvoip/os/linux/AudioOutputALSA.cpp \
      --replace-fail '"libasound.so.2"' '"${lib.getLib alsa-lib}/lib/libasound.so.2"'
    substituteInPlace Telegram/ThirdParty/libtgvoip/os/linux/AudioPulse.cpp \
      --replace-fail '"libpulse.so.0"' '"${lib.getLib libpulseaudio}/lib/libpulse.so.0"'
  '';

  nativeBuildInputs =
    [
      pkg-config
@@ -87,7 +74,6 @@ stdenv.mkDerivation (finalAttrs: {
      ffmpeg_6
      openalSoft
      minizip
      libopus
      range-v3
      tl-expected
      rnnoise
@@ -101,10 +87,7 @@ stdenv.mkDerivation (finalAttrs: {
      protobuf
      qtwayland
      kcoreaddons
      alsa-lib
      libpulseaudio
      hunspell
      jemalloc
    ]
    ++ lib.optionals stdenv.hostPlatform.isDarwin [
      apple-sdk_15
+11 −0
Original line number Diff line number Diff line
@@ -4,6 +4,10 @@
  fetchFromGitHub,
  fetchpatch,
  telegram-desktop,
  alsa-lib,
  jemalloc,
  libopus,
  libpulseaudio,
  withWebkit ? true,
}:

@@ -32,6 +36,13 @@ telegram-desktop.override {
      })
    ];

    buildInputs = (old.buildInputs or [ ]) ++ [
      alsa-lib
      jemalloc
      libopus
      libpulseaudio
    ];

    cmakeFlags = (old.cmakeFlags or [ ]) ++ [
      (lib.cmakeBool "DESKTOP_APP_DISABLE_AUTOUPDATE" true)
    ];