Skip to content

Linux packages run on Ubuntu 22.04 - #113

Merged
KnifeLemon merged 2 commits into
mainfrom
feature/ubuntu-2204
Oct 18, 2026
Merged

KnifeLemon merged 2 commits into
mainfrom
feature/ubuntu-2204

Conversation

@KnifeLemon

@KnifeLemon KnifeLemon commented Oct 18, 2026 •

Copy link
Copy Markdown
Owner

Closes #102.

Linux packages now run on Ubuntu 22.04 (glibc 2.35). Two native pieces needed newer glibc: SharpHook 8.0.0's X11 hook backends (2.38, __isoc23_sscanf) and the rhwp release binary (2.39).

Changes

  • New linux-native CI job (ubuntu-22.04 / ubuntu-22.04-arm) builds them from source with build/build-linux-native.py:
    • libuiohook at the commit SharpHook v8.0.0 pins (a41658fb, checked with git ls-tree), with SharpHook's own flags. It builds only the xrecord/x11 backends and runs uiohook_tests --headless.
    • rhwp v0.8.7 (1a76570e) with Rust 1.93.1, --locked.
    • check fails when Directory.Packages.props or engines.json move to versions the script doesn't pin.
  • build-portable.ps1 gets -RhwpOverride / -UiohookOverride (Linux only). Local builds are unchanged.
  • glibc audit (build/check-elf-glibc.py): fails if any ELF in the package needs a GLIBC newer than 2.35.
  • Smoke tests moved to scripts (smoke-portable.ps1, smoke-launch-app.py). They add a TXT → HWPX → HWP → PDF round trip through rhwp, a check that the hook backend loads, and a check for ErrorLinuxLoadBackend in the app log.
  • New ubuntu-22-04 job (x64 + arm64) runs those smoke tests on the 24.04-built package with only 22.04 runtime packages installed.
  • App: when the hook backend can't load on Linux, the Triggers page explains it (X11 session, sudo apt install libxtst6 libxt6) instead of showing a raw code.
  • Docs: INSTALL.txt (22.04 commands, libxt6), READMEs, THIRD-PARTY-NOTICES (libuiohook LGPL-3.0, rhwp MIT), ENGINES.md, CONTRIBUTING.md.

Not verified locally

The Linux builds and the 22.04 smoke run for the first time in this PR's CI. Watch for:

  • libuiohook with GCC 11 -std=gnu2x and CMake 4.2.3 with extra-cmake-modules 5.92.
  • rhwp --locked and build time.
  • pwsh and pip on the 22.04-arm image.

Update: SharpHook 8.0.1

SharpHook 8.0.1 (released after this PR was opened, TolikPylypchuk/SharpHook#177) builds libuiohook for older glibc again. All twelve Linux libraries in its package (linux-x64/arm64/arm: libuiohook.so, -x11, -xrecord, -wayland) need GLIBC_2.34 at most (build/check-elf-glibc.py --max 2.35).

This PR now bumps SharpHook to 8.0.1 and drops the libuiohook source build:

  • the uiohook command of build/build-linux-native.py
  • the libuiohook build step and its CMake/X11/Wayland dependencies in the linux-native job
  • -UiohookOverride in build/build-portable.ps1

The Linux packages ship SharpHook's own native libraries again. Only rhwp (its release binary needs GLIBC_2.39) is still built from pinned source on Ubuntu 22.04 and passed in with -RhwpOverride.

The ELF glibc audit and the Ubuntu 22.04 x64/arm64 smoke job are unchanged. They still load the X11 hook back end on 22.04, so CI fails if a later SharpHook or engine update raises the glibc requirement again. docs/ENGINES.md says what to do then.

🤖 Generated with Claude Code

SharpHook's libuiohook-xrecord.so and libuiohook-x11.so need GLIBC_2.38
(__isoc23_sscanf, built on Ubuntu 26.04) and rhwp's Linux release needs
GLIBC_2.39, so neither starts on Ubuntu 22.04 (#102).

- portable.yml: a linux-native job builds both from pinned, unmodified
  source on ubuntu-22.04 and ubuntu-22.04-arm (build/build-linux-native.py:
  libuiohook at SharpHook 8.0.0's submodule commit with SharpHook's CMake
  flags and unit tests; rhwp v0.8.7 with cargo +1.93.1 --locked), cached.
  The Linux package jobs pass them to build-portable.ps1 (-RhwpOverride,
  -UiohookOverride); local builds keep using the downloads.
- build-linux-native.py check fails when Directory.Packages.props or
  engines.json move to another SharpHook or rhwp version than it builds.
- build/check-elf-glibc.py (standard library ELF reader) lists the newest
  GLIBC version of every ELF file and fails above 2.35, on the native builds
  and on every Linux package.
- The package smoke steps move to build/smoke-portable.ps1 and
  build/smoke-launch-app.py, add TXT -> HWPX -> HWP -> PDF through rhwp, load
  libuiohook-xrecord.so and fail on ErrorLinuxLoadBackend in the app log.
  A new job runs them on Ubuntu 22.04 (x64 and arm64) with its own packages.
- The Shortcuts page explains a Linux back end that doesn't load (X11
  session, libxtst6 and libxt6) instead of the raw error; the log keeps the
  libuiohook result.
- INSTALL.txt has the Ubuntu 22.04 and 24.04 dependency commands with
  libxt6; READMEs say Ubuntu 22.04+; notices and docs describe the builds.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
SharpHook 8.0.1 builds libuiohook for older glibc again: all of its Linux
back ends (x64, arm64, arm) need GLIBC_2.34 at most. The Linux packages use
SharpHook's own libraries again, so the libuiohook source build, its CI
dependencies and -UiohookOverride are gone. rhwp is still built from source
on Ubuntu 22.04. The glibc audit and the Ubuntu 22.04 smoke job stay and fail
if a SharpHook or engine update raises the requirement again.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@KnifeLemon
KnifeLemon merged commit 5438a36 into main Oct 18, 2026
9 checks passed
@KnifeLemon
KnifeLemon deleted the feature/ubuntu-2204 branch October 19, 2026 12:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add/support Ubuntu 22.04 for Linux global gestures

1 participant