Skip to content

Commit a182aba

Browse files
authored
feat(bluefin): add ydotool input automation (#1258)
Build ydotool v1.0.4 from source, ship its opt-in user daemon, and provide uinput module and uaccess rules for Wayland input injection.\n\nCloses #1217\n\nAssisted-by: GPT-5.6 Luna via GitHub Copilot\nCo-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Co-authored-by: castrojo <castrojo@users.noreply.github.com>
1 parent 5ca1d9b commit a182aba

3 files changed

Lines changed: 45 additions & 0 deletions

File tree

docs/skills/add-package.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -173,3 +173,11 @@ junction. If a Shell extension needs the GTK3 introspection ABI, build with `-Dg
173173
(depends on `gnome-build-meta.bst:sdk/gtk+-3.bst`); upstream's VTE is GTK4-only. Push demo
174174
binaries and unversioned `.so` linker symlinks to the `devel` split so `bluefin-runtime`'s
175175
compose (which excludes `devel`) keeps only the `.typelib` + versioned `.so.N`.
176+
177+
### User services that require `/dev/uinput` need both module loading and uaccess (2026-07-31)
178+
179+
For a user-level daemon that opens `/dev/uinput`, installing the upstream unit
180+
alone is insufficient. Ship a modules-load entry for `uinput` and a udev rule
181+
with `TAG+="uaccess"` so the active desktop user receives device ACL access
182+
without manual `chmod` or group edits. Keep the user unit present but unenabled
183+
unless the feature is explicitly opt-in.

elements/bluefin/deps.bst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ depends:
1919

2020
- bluefin/gum.bst
2121
- bluefin/tealdeer.bst
22+
- bluefin/ydotool.bst
2223
- bluefin/umotd.bst
2324

2425
- bluefin/common.bst

elements/bluefin/ydotool.bst

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
# ydotool provides input injection for Wayland sessions through /dev/uinput.
2+
# Keep the daemon unit disabled by default; users opt in with systemctl --user.
3+
kind: cmake
4+
5+
sources:
6+
- kind: git_repo
7+
url: github:ReimuNotMoe/ydotool.git
8+
track: v1.0.4
9+
ref: v1.0.4-0-g57ba7d0af525e82da2de0e275d169477f293b197
10+
11+
build-depends:
12+
- freedesktop-sdk.bst:public-stacks/buildsystem-cmake.bst
13+
- freedesktop-sdk.bst:components/scdoc.bst
14+
- freedesktop-sdk.bst:components/systemd.bst
15+
16+
depends:
17+
- freedesktop-sdk.bst:public-stacks/runtime-minimal.bst
18+
19+
variables:
20+
cmake-local: >-
21+
-DCMAKE_INSTALL_MANDIR=%{mandir}
22+
23+
config:
24+
install-commands:
25+
(>):
26+
- |
27+
install -Dm644 /dev/null "%{install-root}%{indep-libdir}/udev/rules.d/80-ydotool.rules"
28+
cat > "%{install-root}%{indep-libdir}/udev/rules.d/80-ydotool.rules" <<'EOF'
29+
KERNEL=="uinput", GROUP="input", MODE="0660", TAG+="uaccess", OPTIONS+="static_node=uinput"
30+
EOF
31+
- |
32+
install -Dm644 /dev/null "%{install-root}%{indep-libdir}/modules-load.d/ydotool.conf"
33+
printf '%s\n' uinput > "%{install-root}%{indep-libdir}/modules-load.d/ydotool.conf"
34+
- |
35+
install -d "%{install-root}%{indep-libdir}/systemd/user"
36+
ln -s ydotool.service "%{install-root}%{indep-libdir}/systemd/user/ydotoold.service"

0 commit comments

Comments
 (0)