x11/libxkbcommon: fix issue with version-script and recently linker
The test used in the meson file is valid on linux but invalid on FreeBSD
it tested while building a binary instead of a DSO.
Adding -shared to the argument of the tests makes it pass properly
Note: that this is invisible on current due to a change in the base which
is probably a bug and under investigation
PR: 285325
Reported by: many