extest icon indicating copy to clipboard operation
extest copied to clipboard

Title: LD_PRELOAD path hardcoded to /usr/lib/ breaks 64-bit SteamRT3c client on x86_64

Open tanukikabu opened this issue 6 months ago • 0 comments

Summary

The extest-steam package patches steam.desktop to set LD_PRELOAD=/usr/lib/extest/libextest.so. On Fedora x86_64, /usr/lib/extest/ contains the i686 build of libextest, and the x86_64 build lives at /usr/lib64/extest/libextest.so. This worked while Steam's main client binary was 32-bit, but the new SteamRT3c client (~/.local/share/Steam/steamrt64/steam) is 64-bit. ld.so then refuses to load the 32-bit library and logs:

ERROR: ld.so: object '/usr/lib/extest/libextest.so' from LD_PRELOAD cannot be preloaded (wrong ELF class: ELFCLASS32): ignored.

extest never initializes, no virtual uinput mouse is created, and downstream features that rely on it break — in my case the Steam Controller Puck trackpad stops working as a mouse on Wayland.

Environment

  • Fedora 44, x86_64
  • Steam client: SteamRT3c (steamrt64/steam, 64-bit ELF)
  • extest-steam from the Fedora repo
  • Wayland session (Niri compositor)

Reproduction

  1. Install extest-steam on a 64-bit Fedora system.
  2. Launch Steam via the patched .desktop (or via the systemd user service with the same LD_PRELOAD=).
  3. grep "wrong ELF class" ~/.local/share/Steam/logs/console-linux.txt — you'll see the preload rejection.
  4. No /dev/input/eventN virtual mouse appears from extest.

Proposed fix

Use glibc's $LIB dynamic-linker token instead of a hardcoded path. It expands to lib for 32-bit children and lib64 for 64-bit processes, so both arch variants resolve correctly:

LD_PRELOAD=/usr/$LIB/extest/libextest.so

The patching script (override_steam_desktop_file.sh or equivalent) should emit /usr/$LIB/ rather than /usr/lib/. This is a one-character change that fixes the 64-bit client without breaking the legacy 32-bit one.

Note for systemd users: Environment= does not perform shell expansion, so $LIB is forwarded literally to the child process and ld.so substitutes it there — this is the desired behavior.

Workaround

Replace /usr/lib/ with /usr/$LIB/ in every Exec= line of the user-local ~/.local/share/applications/steam.desktop override (and ~/.config/systemd/user/steam.service if used).

Also please bear in mind that i have generated this using Claude code as i have no coding skills myself but the issue should be addressed nonetheless and the fix seems to be functional on my system

tanukikabu avatar May 17 '26 16:05 tanukikabu