summaryrefslogtreecommitdiffstats
path: root/pkgs/by-name/mt/mtproxy/package.nix
blob: aea7ba1d370fc1d487d708dacbda1e0e671dce2e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
{
  lib,
  stdenv,
  fetchFromGitHub,
  openssl,
  zlib,
}:
stdenv.mkDerivation {
  pname = "mtproxy";
  version = "1-unstable-2025-11-04";
  src = fetchFromGitHub {
    owner = "TelegramMessenger";
    repo = "MTProxy";
    rev = "cafc3380a81671579ce366d0594b9a8e450827e9";
    hash = "sha256-tY2iwNAQIL8sCUuddy9Lm/d/W1notL27HhRtOa25VsE=";
  };
  buildInputs = [
    openssl
    zlib
  ];
  installPhase = ''
    runHook preInstall
    mkdir -p $out/bin
    cp objs/bin/mtproto-proxy $out/bin/
    runHook postInstall
  '';
  meta = {
    description = "Simple MT-Proto proxy";
    mainProgram = "mtproto-proxy";
    homepage = "https://github.com/TelegramMessenger/MTProxy";
    license = lib.licenses.gpl2Plus;
    maintainers = with lib.maintainers; [ nix-julia ];
    platforms = [ "x86_64-linux" ];
  };
}