about summary refs log tree commit diff
path: root/pkgs/applications/misc/rlaunch/default.nix
blob: 5622c94d427f806bbf40a79ad9f7c1d585032004 (plain) (blame)
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
{ lib
, fetchFromGitHub
, rustPlatform
, xorg
}:

rustPlatform.buildRustPackage rec {
  pname = "rlaunch";
  version = "1.3.13";

  src = fetchFromGitHub {
    owner = "PonasKovas";
    repo = pname;
    rev = version;
    sha256 = "1w8qvny72l5358wnk4dmqnrv4mrpzxrzf49svav9grzxzzf8mqy2";
  };

  cargoSha256 = "00lnw48kn97gp45lylv5c6v6pil74flzpsq9k69xgvvjq9yqjzrx";

  # The x11_dl crate dlopen()s these libraries, so we have to inject them into rpath.
  postFixup = ''
    patchelf --set-rpath ${lib.makeLibraryPath (with xorg; [ libX11 libXft libXinerama ])} $out/bin/rlaunch
  '';

  meta = with lib; {
    description = "A lightweight application launcher for X11";
    homepage = "https://github.com/PonasKovas/rlaunch";
    license = licenses.mit;
    maintainers = with maintainers; [ danc86 ];
  };
}