btrbk: add mainProgram
[NixPkgs.git] / pkgs / by-name / xi / xiu / package.nix
blobfe5ab564e9f71a8fe1fec8758c2b2b3fbeb35ac9
1 { lib
2 , cmake
3 , darwin
4 , fetchFromGitHub
5 , libopus
6 , openssl
7 , pkg-config
8 , rustPlatform
9 , stdenv
12 rustPlatform.buildRustPackage rec {
13   pname = "xiu";
14   version = "0.13.0";
16   src = fetchFromGitHub {
17     owner = "harlanc";
18     repo = "xiu";
19     rev = "v${version}";
20     hash = "sha256-EjyvCwqcPkOe69YnDiAExtBNPhsqqGa95ao+bn6wcyA=";
21   };
23   cargoHash = "sha256-pW1VvnK7WDRvSVFOMUibtsPn+dhcFp64EpTW5beaJ+s=";
25   nativeBuildInputs = [
26     cmake
27     pkg-config
28   ];
30   buildInputs = [
31     libopus
32   ] ++ lib.optionals stdenv.hostPlatform.isLinux [
33     openssl
34   ] ++ lib.optionals stdenv.hostPlatform.isDarwin [
35     darwin.apple_sdk.frameworks.SystemConfiguration
36   ];
38   OPENSSL_NO_VENDOR = 1;
40   meta = with lib; {
41     description = "Simple, high performance and secure live media server in pure Rust (RTMP[cluster]/RTSP/WebRTC[whip/whep]/HTTP-FLV/HLS";
42     homepage = "https://github.com/harlanc/xiu";
43     changelog = "https://github.com/harlanc/xiu/releases/tag/v${version}";
44     license = licenses.mit;
45     maintainers = with maintainers; [ cafkafk ];
46     mainProgram = "xiu";
47   };