2021-05-17 03:39:35 +01:00
|
|
|
{ lib
|
|
|
|
, stdenv
|
2024-05-21 04:45:00 +01:00
|
|
|
, callPackage
|
2024-04-16 13:45:43 +01:00
|
|
|
, fetchFromGitea
|
2023-07-10 07:17:10 +01:00
|
|
|
, libGL
|
|
|
|
, libX11
|
|
|
|
, libevdev
|
|
|
|
, libinput
|
|
|
|
, libxkbcommon
|
|
|
|
, pixman
|
2021-05-17 03:39:35 +01:00
|
|
|
, pkg-config
|
|
|
|
, scdoc
|
2023-07-10 07:17:10 +01:00
|
|
|
, udev
|
|
|
|
, wayland
|
2021-05-17 03:39:35 +01:00
|
|
|
, wayland-protocols
|
2023-02-11 09:53:45 +00:00
|
|
|
, wayland-scanner
|
2024-07-30 13:02:14 +01:00
|
|
|
, wlroots_0_18
|
2023-07-10 07:17:10 +01:00
|
|
|
, xwayland
|
2024-06-16 09:36:56 +01:00
|
|
|
, zig_0_13
|
2023-07-15 06:24:36 +01:00
|
|
|
, withManpages ? true
|
2022-02-05 20:21:34 +00:00
|
|
|
, xwaylandSupport ? true
|
2021-04-14 03:33:36 +01:00
|
|
|
}:
|
|
|
|
|
2023-07-10 07:17:10 +01:00
|
|
|
stdenv.mkDerivation (finalAttrs: {
|
2021-04-14 06:30:03 +01:00
|
|
|
pname = "river";
|
2024-07-30 13:02:14 +01:00
|
|
|
version = "0.3.5";
|
2021-04-14 03:33:36 +01:00
|
|
|
|
2023-07-15 06:24:36 +01:00
|
|
|
outputs = [ "out" ] ++ lib.optionals withManpages [ "man" ];
|
|
|
|
|
2024-04-16 13:45:43 +01:00
|
|
|
src = fetchFromGitea {
|
|
|
|
domain = "codeberg.org";
|
|
|
|
owner = "river";
|
2023-07-10 07:17:10 +01:00
|
|
|
repo = "river";
|
|
|
|
rev = "refs/tags/v${finalAttrs.version}";
|
2021-04-14 03:33:36 +01:00
|
|
|
fetchSubmodules = true;
|
2024-07-30 13:02:14 +01:00
|
|
|
hash = "sha256-NUKjQOT6UgNYCebeHMxOhX08r3493IOL3qHZivEcbAg=";
|
2021-04-14 03:33:36 +01:00
|
|
|
};
|
|
|
|
|
2024-05-21 04:45:00 +01:00
|
|
|
deps = callPackage ./build.zig.zon.nix { };
|
|
|
|
|
2023-07-10 07:17:10 +01:00
|
|
|
nativeBuildInputs = [
|
|
|
|
pkg-config
|
2023-02-11 09:53:45 +00:00
|
|
|
wayland-scanner
|
2023-07-10 07:17:10 +01:00
|
|
|
xwayland
|
2024-06-16 09:36:56 +01:00
|
|
|
zig_0_13.hook
|
2023-07-15 06:24:36 +01:00
|
|
|
]
|
|
|
|
++ lib.optional withManpages scdoc;
|
2021-05-17 03:39:35 +01:00
|
|
|
|
|
|
|
buildInputs = [
|
2023-07-10 07:17:10 +01:00
|
|
|
libGL
|
|
|
|
libevdev
|
|
|
|
libinput
|
2021-05-17 03:39:35 +01:00
|
|
|
libxkbcommon
|
|
|
|
pixman
|
|
|
|
udev
|
2023-02-11 09:53:45 +00:00
|
|
|
wayland
|
2023-07-10 07:17:10 +01:00
|
|
|
wayland-protocols
|
2024-07-30 13:02:14 +01:00
|
|
|
wlroots_0_18
|
2022-01-28 13:14:38 +00:00
|
|
|
] ++ lib.optional xwaylandSupport libX11;
|
2021-04-14 03:33:36 +01:00
|
|
|
|
2021-05-09 17:32:05 +01:00
|
|
|
dontConfigure = true;
|
|
|
|
|
2024-05-21 04:45:00 +01:00
|
|
|
zigBuildFlags = [
|
|
|
|
"--system"
|
|
|
|
"${finalAttrs.deps}"
|
|
|
|
] ++ lib.optional withManpages "-Dman-pages" ++ lib.optional xwaylandSupport "-Dxwayland";
|
2021-05-17 03:39:35 +01:00
|
|
|
|
2023-07-10 07:17:10 +01:00
|
|
|
postInstall = ''
|
2022-11-28 16:19:15 +00:00
|
|
|
install contrib/river.desktop -Dt $out/share/wayland-sessions
|
2021-04-29 21:01:54 +01:00
|
|
|
'';
|
2021-04-14 03:33:36 +01:00
|
|
|
|
2024-05-21 04:45:00 +01:00
|
|
|
passthru = {
|
|
|
|
providedSessions = [ "river" ];
|
|
|
|
updateScript = ./update.nu;
|
|
|
|
};
|
2021-05-01 17:18:33 +01:00
|
|
|
|
2023-07-10 07:17:10 +01:00
|
|
|
meta = {
|
2024-04-16 13:45:43 +01:00
|
|
|
homepage = "https://codeberg.org/river/river";
|
2021-05-09 17:32:05 +01:00
|
|
|
description = "Dynamic tiling wayland compositor";
|
2023-07-10 07:17:10 +01:00
|
|
|
longDescription = ''
|
|
|
|
River is a dynamic tiling Wayland compositor with flexible runtime
|
|
|
|
configuration.
|
|
|
|
|
|
|
|
Its design goals are:
|
|
|
|
- Simple and predictable behavior, river should be easy to use and have a
|
|
|
|
low cognitive load.
|
|
|
|
- Window management based on a stack of views and tags.
|
|
|
|
- Dynamic layouts generated by external, user-written executables. A
|
|
|
|
default rivertile layout generator is provided.
|
|
|
|
- Scriptable configuration and control through a custom Wayland protocol
|
|
|
|
and separate riverctl binary implementing it.
|
|
|
|
'';
|
2024-04-16 13:45:43 +01:00
|
|
|
changelog = "https://codeberg.org/river/river/releases/tag/v${finalAttrs.version}";
|
2023-07-10 07:17:10 +01:00
|
|
|
license = lib.licenses.gpl3Plus;
|
|
|
|
maintainers = with lib.maintainers; [
|
|
|
|
adamcstephens
|
2023-11-17 10:03:27 +00:00
|
|
|
moni
|
2023-07-10 07:17:10 +01:00
|
|
|
rodrgz
|
|
|
|
];
|
2023-09-01 16:43:28 +01:00
|
|
|
mainProgram = "river";
|
2023-07-10 07:17:10 +01:00
|
|
|
platforms = lib.platforms.linux;
|
2021-04-14 03:33:36 +01:00
|
|
|
};
|
2023-07-10 07:17:10 +01:00
|
|
|
})
|