nixpkgs/pkgs/applications/window-managers/river/default.nix

72 lines
1.4 KiB
Nix
Raw Normal View History

{ lib
, stdenv
, fetchFromGitHub
, zig
, wayland
, pkg-config
, scdoc
, xwayland
, wayland-protocols
, wlroots
, libxkbcommon
, pixman
, udev
, libevdev
2021-06-30 03:53:05 +01:00
, libinput
, libX11
, libGL
}:
stdenv.mkDerivation rec {
pname = "river";
2022-01-21 18:59:22 +00:00
version = "0.1.2";
src = fetchFromGitHub {
2022-01-21 18:59:22 +00:00
owner = "riverwm";
repo = pname;
2021-11-03 07:10:42 +00:00
rev = "v${version}";
2022-01-21 18:59:22 +00:00
sha256 = "0mysj6fmgiwzrfzm1rk09k4xa9qiqsdwvwr59b4rs010c1gsllwk";
fetchSubmodules = true;
};
nativeBuildInputs = [ zig wayland xwayland scdoc pkg-config ];
buildInputs = [
wayland-protocols
wlroots
libxkbcommon
pixman
udev
libevdev
2021-06-30 03:53:05 +01:00
libinput
libX11
libGL
];
dontConfigure = true;
2021-05-01 17:18:33 +01:00
preBuild = ''
export HOME=$TMPDIR
'';
installPhase = ''
runHook preInstall
2021-06-01 11:53:46 +01:00
zig build -Drelease-safe -Dcpu=baseline -Dxwayland -Dman-pages --prefix $out install
runHook postInstall
'';
2022-01-21 18:59:22 +00:00
/* Builder patch install dir into river to get default config
When installFlags is removed, river becomes half broken.
See https://github.com/riverwm/river/blob/7ffa2f4b9e7abf7d152134f555373c2b63ccfc1d/river/main.zig#L56
*/
2021-05-01 17:18:33 +01:00
installFlags = [ "DESTDIR=$(out)" ];
meta = with lib; {
2021-05-01 17:18:33 +01:00
homepage = "https://github.com/ifreund/river";
description = "A dynamic tiling wayland compositor";
license = licenses.gpl3Plus;
platforms = platforms.linux;
maintainers = with maintainers; [ fortuneteller2k ];
};
}