From 84c7cb77b7d3f6d8af7433fa44ae7c868b4f55e4 Mon Sep 17 00:00:00 2001 From: Donovan Glover Date: Sun, 4 Jun 2023 10:26:52 -0400 Subject: [PATCH] pkgs: Add waycorner This works, and is a result of the work done by NotAShelf. --- packages/waycorner/default.nix | 40 ++++++++++++++++++++++++++++++++++ 1 file changed, 40 insertions(+) create mode 100644 packages/waycorner/default.nix diff --git a/packages/waycorner/default.nix b/packages/waycorner/default.nix new file mode 100644 index 00000000..dfb1e094 --- /dev/null +++ b/packages/waycorner/default.nix @@ -0,0 +1,40 @@ +{ lib +, makeWrapper +, rustPlatform +, pkg-config +, fetchFromGitHub +, wayland +, +}: +rustPlatform.buildRustPackage rec { + pname = "waycorner"; + version = "0.2.1"; + src = fetchFromGitHub { + owner = "AndreasBackx"; + repo = "waycorner"; + rev = version; + hash = "sha256-xvmvtn6dMqt8kUwvn5d5Nl1V84kz1eWa9BSIN/ONkSQ="; + }; + cargoHash = "sha256-Dl+GhJywWhaC4QMS70klazPsFipGVRW+6jrXH2XsEAI="; + buildInputs = [ + wayland + ]; + nativeBuildInputs = [ + pkg-config + makeWrapper + ]; + postFixup = '' + # the program looks for libwayland-client.so at runtime + wrapProgram $out/bin/waycorner \ + --prefix LD_LIBRARY_PATH : ${lib.makeLibraryPath [wayland]} + ''; + + meta = with lib; { + description = "Hot corners for Wayland"; + changelog = "https://github.com/AndreasBackx/waycorner/blob/main/CHANGELOG.md"; + homepage = "https://github.com/AndreasBackx/waycorner"; + platforms = platforms.linux; + license = licenses.mit; + maintainers = with maintainers; [ NotAShelf ]; + }; +}