Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
at domenkozar-patch-1 34 lines 904 B view raw
1{ stdenv, lib, fetchFromGitLab, pkg-config, libyamlcpp, libevdev }: 2 3stdenv.mkDerivation rec { 4 pname = "dual-function-keys"; 5 version = "1.4.0"; 6 7 src = fetchFromGitLab { 8 group = "interception"; 9 owner = "linux/plugins"; 10 repo = pname; 11 rev = version; 12 sha256 = "sha256-xlplbkeptXMBlRnSsc5NgGJfT8aoZxTRgTwTOd7aiWg="; 13 }; 14 15 nativeBuildInputs = [ pkg-config ]; 16 17 buildInputs = [ libevdev libyamlcpp ]; 18 19 prePatch = '' 20 substituteInPlace config.mk --replace \ 21 '/usr/include/libevdev-1.0' \ 22 "$(pkg-config --cflags libevdev | cut -c 3-)" 23 ''; 24 25 installFlags = [ "DESTDIR=$(out)" "PREFIX=" ]; 26 27 meta = with lib; { 28 homepage = "https://gitlab.com/interception/linux/plugins/dual-function-keys"; 29 description = "Tap for one key, hold for another."; 30 license = licenses.mit; 31 maintainers = with maintainers; [ svend ]; 32 platforms = platforms.linux; 33 }; 34}