Snap support

For some unknown reason, Snap sandboxes apps (unless they use classic confinement) with /etc exposed and /lib not exposed, which leads to the apps trying to preload libinput-config but not finding it due to the system /lib replaced by the Snap's /lib. To make the matters even worse, in contrast to Flatpak, Snap offers no way to allow or forbid the apps access to a certain file or directory. Therefore, a terribly hacky workaround is used, which installs the library to /etc instead, but this is an awful way to do this, and there must be another one.

Here are some ways I could think of but not understand how to implement:

  • Rewrite the library so it replaces the libinput and then loads it instead of being preloaded before it.
  • Somehow make Snap ignore /etc/ld.so.preload or not ignore libinput-config.so.
  • Install the library to Snap's filesystem so it can be loaded properly.
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information