6d4aeb4377
GitOrigin-RevId: 0f213d0fee84280d8c3a97f7469b988d6fe5fcdf
51 lines
989 B
Nix
51 lines
989 B
Nix
{ lib
|
|
, stdenv
|
|
, fetchFromGitHub
|
|
, zig
|
|
, wayland
|
|
, pkg-config
|
|
, scdoc
|
|
, wayland-protocols
|
|
, libxkbcommon
|
|
, pam
|
|
}:
|
|
stdenv.mkDerivation rec {
|
|
pname = "waylock";
|
|
version = "0.6.0";
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "ifreund";
|
|
repo = pname;
|
|
rev = "v${version}";
|
|
hash = "sha256-AujBvDy10e5HhezCQcXpBUVlktRKNseLxRKdI+gtH6w=";
|
|
fetchSubmodules = true;
|
|
};
|
|
|
|
nativeBuildInputs = [ zig wayland scdoc pkg-config ];
|
|
|
|
buildInputs = [
|
|
wayland-protocols
|
|
libxkbcommon
|
|
pam
|
|
];
|
|
|
|
dontConfigure = true;
|
|
|
|
preBuild = ''
|
|
export HOME=$TMPDIR
|
|
'';
|
|
|
|
installPhase = ''
|
|
runHook preInstall
|
|
zig build -Drelease-safe -Dman-pages -Dcpu=baseline --prefix $out install
|
|
runHook postInstall
|
|
'';
|
|
|
|
meta = with lib; {
|
|
homepage = "https://github.com/ifreund/waylock";
|
|
description = "A small screenlocker for Wayland compositors";
|
|
license = licenses.isc;
|
|
platforms = platforms.linux;
|
|
maintainers = with maintainers; [ jordanisaacs ];
|
|
};
|
|
}
|