Subject: [bug#72500] [PATCH] Add: rofi-emoji-wayland.

From: "Wamm K. D." <[email-masked]>
Date: Tue, 6 Aug 2024 19:04:47 -0500

* gnu/packages/xdisorg.scm (rofi-emoji-wayland): New variable.
---
 gnu/packages/xdisorg.scm | 19 +++++++++++++++++++
 1 file changed, 19 insertions(+)

diff --git a/gnu/packages/xdisorg.scm b/gnu/packages/xdisorg.scm
index bb95304a1f..cfcccb3e81 100644
--- a/gnu/packages/xdisorg.scm
+++ b/gnu/packages/xdisorg.scm
@@ -2139,6 +2139,25 @@ (define-public rofi-emoji
     (home-page "https://github.com/Mange/rofi-emoji")
     (license license:expat)))
 
+(define-public rofi-emoji-wayland
+  (package/inherit rofi-emoji
+    (name "rofi-emoji-wayland")
+    (arguments (substitute-keyword-arguments (package-arguments rofi-emoji)
+                 ((#:phases phases)
+                  #~(modify-phases #$phases
+                      (replace 'patch-adapter-script-xdotool
+                        (lambda* (#:key inputs #:allow-other-keys)
+                          (substitute* "clipboard-adapter.sh"
+                            (("wtype") (search-input-file inputs
+                                                          "/bin/wtype")))))))))
+  (inputs (modify-inputs (package-inputs rofi-emoji)
+            (replace "xdotool" wtype)))
+  (propagated-inputs (modify-inputs (package-propagated-inputs rofi-emoji)
+                       (replace "rofi" rofi-wayland)))
+  (description (string-append
+                (package-description rofi-pass)
+                "\nThis package provides Wayland support by default."))))
+
 (define-public tint2
   (package
     (name "tint2")
-- 
2.45.2