3
0
Fork 0
forked from mirrors/nixpkgs
nixpkgs/pkgs/tools/inputmethods/keyd/default.nix

45 lines
871 B
Nix
Raw Normal View History

2022-07-13 14:05:29 +01:00
{ stdenv
, lib
, fetchFromGitHub
, cmake
, pkg-config
, systemd
}:
stdenv.mkDerivation rec {
pname = "keyd";
version = "2.4.1";
src = fetchFromGitHub {
owner = "rvaiya";
repo = "keyd";
rev = "v" + version;
hash = "sha256-p0f8iGT4QtyWAnlcG4SfOhD94ySNNkQrnVjnGCmQwAk=";
};
postPatch = ''
substituteInPlace Makefile \
--replace DESTDIR= DESTDIR=${placeholder "out"} \
--replace /usr "" \
--replace /var/log/keyd.log /var/log/keyd/keyd.log
substituteInPlace keyd.service \
--replace /usr/bin $out/bin
'';
buildInputs = [ systemd ];
enableParallelBuilding = true;
postInstall = ''
rm -rf $out/etc
'';
meta = with lib; {
2022-07-13 14:09:58 +01:00
description = "A key remapping daemon for linux.";
license = licenses.mit;
2022-07-13 14:05:29 +01:00
maintainers = with maintainers; [ peterhoeg ];
2022-07-13 14:09:58 +01:00
platforms = platforms.linux;
2022-07-13 14:05:29 +01:00
};
}