nickguletskii / GLXOSD

GLXOSD is an extensible on-screen display (OSD)/overlay for OpenGL applications running on Linux with X11 which aims to provide similar functionality to MSI Afterburner/RivaTuner OSD. It can show FPS, frame timings, temperatures and more in OpenGL games and applications. It can also be used to benchmark games, much like voglperf.
https://glxosd.nickguletskii.com
MIT License
123 stars 20 forks source link

undefined symbol: XLookupKeysym #106

Open biggles5107 opened 6 years ago

biggles5107 commented 6 years ago

GLXOSD works fine in my testing with glxgears, but it doesn't work with basically any game I've tried. It'll spit out an error like this:

$ glxosd java -jar Minecraft.jar
java: symbol lookup error: /usr/local//lib64//glxosd/libglxosd-glinject.so: undefined symbol: XLookupKeysym

I'm running on Solus and I compiled GLXOSD from source. I had all the dependencies I needed at build time, and the only modification I made to the scripts is in paths.lua to reflect the path of libnvidia-ml.so.1 in Solus (which is a bit different from other distros). Could you point me in the right direction as to what I might be missing here (i.e., some library, an environment variable, etc.)?

nickguletskii commented 6 years ago

I apologise for the late reply, but I think the problem is the path to libX11 is incorrect. I am not sure where it is located on Solus, but you should be able to change it in paths.lua.

biggles5107 commented 6 years ago

I changed all the paths in paths.lua (pastebin if it's helpful) to their absolute paths in Solus. Nothing changed. Was some dependency missing at build time perhaps? I doubt the X11 library was missing - obviously something works because I at least got glxgears to work with it.

I was also unable to build a 32-bit binary because Solus is an x86_64-only distro (it has multilib of course). Is there some way to build a 32-bit binary without using a chroot or am I SOL?

nickguletskii commented 6 years ago

This is a shot in the dark, but maybe libX11.so.6 is a symlink and that causes issues? GLXOSD doesn't resolve X symbols like glxgears, so glxgears may work while GLXOSD might not.

There's no way to build a 32-bit binary without a chroot at the moment, but you could try using the binaries for other distros.

biggles5107 commented 6 years ago

Changed libX11.so.6 to libX11.so.6.3.0, no effect.

ghost commented 6 years ago

I am also receiving this error message. I am also using the absolute path for each library in paths.lua, I have double checked making sure they all linked to the right file. Also glxgears works fine as well for me.

Here is my paths.lua file: hastebin

I'm running Arch Linux, so maybe it's a problem with the libraries in Arch.

ProgrammierPatrick commented 6 years ago

I have the same error message. I am running Arch Linux and used glxosd 3.2.2-1 (from AUR). The error occured in a x86_64 build from Unity3D Linux Edition (Version 2017.3.0p2), but when starting a 32bit build I get:

$ glxosd ./LinuxBuild32.x86 
ERROR: ld.so: object 'libglxosd-glinject.so' from LD_PRELOAD cannot be preloaded (wrong ELF class: ELFCLASS64): ignored.

Maybe it has something to do with the launcher? because both minecraft and a standard unity build first start into a launcher which then starts the game.