Can't link library: libGui.so.6.22: cannot open shared object file: No such file or directory

Dear ROOT community,

I’ve been trying to link a library (let’s call it “mylibary.so”) with root to correctly open a .root file which contains special classes. I tried running

root -e ".L ./mylibary.so" myrootfile.root

and

root

.L mylibary.so

as well as

root

gSystem->Load("mylibary")

all of which yield the error

cling::DynamicLibraryManager::loadLibrary(): libGui.so.6.22: cannot open shared object file: No such file or directory

(with an (int) -1 for the last one)

Since I had installed root (v6.24/04) using pacman, I assumed something was wrong with the package, so I installed a root version from source (the latest v6.24/06) separately but the error persisted. Does anyone have an idea for a fix ?

ROOT Version: 6.24/04 & 06
Platform: Manjaro Linux 21.0
Compiler: Not Provided


It looks like your “mylibary.so” was built with ROOT 6.22, and you try to use it with ROOT 6.24.