input.rs
input.rs copied to clipboard
linker cannot find -linput on Ubuntu 22.04
I tried the example, got blocked on the compiling.
Because on debian based distribution, the package libinput is called "libinput10" and just no libinput
So i had to create a symlink:
sudo ln -s /usr/lib/x86_64-linux-gnu/libinput.so.10 /usr/lib/x86_64-linux-gnu/libinput.so
And the compiling error vanished. Since i couldn't find the answer anywhere and struggled to find the solution, i had to post the solution somewhere.
The problem is the link-name specified here: https://github.com/Smithay/input.rs/blob/master/input-sys/src/lib.rs#L22
Which is very generic on purpose. I am not sure what would be the best way to make this configurable and thus more easily buildable on debian. :S
I don't know either, i believe the issue isn't on the rust call end but more on the C end. But i really don't know much how it works. The issue cannot be fixed in the packet manager either. cf. https://unix.stackexchange.com/questions/679906/why-is-libinput-packaged-as-libinput10