nixpkgs mirror (for testing)
github.com/NixOS/nixpkgs
nix
1{ fetchFromSourcehut
2, lib
3, meson
4, ninja
5, pkg-config
6, scdoc
7, stdenv
8, systemdSupport ? lib.meta.availableOn stdenv.hostPlatform systemd, systemd
9}:
10
11stdenv.mkDerivation rec {
12 pname = "seatd";
13 version = "0.7.0";
14
15 src = fetchFromSourcehut {
16 owner = "~kennylevinsen";
17 repo = "seatd";
18 rev = version;
19 sha256 = "sha256-m8xoL90GI822FTgCXuVr3EejLAMUStkPKVoV7w8ayIE=";
20 };
21
22 outputs = [ "bin" "out" "dev" "man" ];
23
24 depsBuildBuild = [ pkg-config ];
25
26 nativeBuildInputs = [ meson ninja pkg-config scdoc ];
27
28 buildInputs = lib.optionals systemdSupport [ systemd ];
29
30 mesonFlags = [
31 "-Dlibseat-logind=${if systemdSupport then "systemd" else "disabled"}"
32 "-Dlibseat-builtin=enabled"
33 "-Dserver=enabled"
34 ];
35
36 meta = with lib; {
37 description = "A universal seat management library";
38 changelog = "https://git.sr.ht/~kennylevinsen/seatd/refs/${version}";
39 homepage = "https://sr.ht/~kennylevinsen/seatd/";
40 license = licenses.mit;
41 platforms = with platforms; freebsd ++ linux ++ netbsd;
42 maintainers = with maintainers; [ emantor ];
43 };
44}