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
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
|
{ lib
, stdenv
, fetchFromGitHub
, cmake
, pkg-config
, wayland-scanner
, makeWrapper
, wrapQtAppsHook
, hyprland-protocols
, hyprlang
, libdrm
, mesa
, pipewire
, qtbase
, qttools
, qtwayland
, sdbus-cpp
, systemd
, wayland
, wayland-protocols
, hyprland
, hyprpicker
, slurp
}:
stdenv.mkDerivation (self: {
pname = "xdg-desktop-portal-hyprland";
version = "1.3.1";
src = fetchFromGitHub {
owner = "hyprwm";
repo = "xdg-desktop-portal-hyprland";
rev = "v${self.version}";
hash = "sha256-wP611tGIWBA4IXShWbah7TxqdbvhfcfT2vnXalX/qzk=";
};
nativeBuildInputs = [
cmake
pkg-config
wayland-scanner
makeWrapper
wrapQtAppsHook
];
buildInputs = [
hyprland-protocols
hyprlang
libdrm
mesa
pipewire
qtbase
qttools
qtwayland
sdbus-cpp
systemd
wayland
wayland-protocols
];
dontWrapQtApps = true;
postInstall = ''
wrapProgramShell $out/bin/hyprland-share-picker \
"''${qtWrapperArgs[@]}" \
--prefix PATH ":" ${lib.makeBinPath [slurp hyprland]}
wrapProgramShell $out/libexec/xdg-desktop-portal-hyprland \
--prefix PATH ":" ${lib.makeBinPath [(placeholder "out") hyprpicker]}
'';
meta = with lib; {
homepage = "https://github.com/hyprwm/xdg-desktop-portal-hyprland";
description = "xdg-desktop-portal backend for Hyprland";
license = licenses.bsd3;
maintainers = with maintainers; [ fufexan ];
platforms = platforms.linux;
};
})
|