My custom ld.so.conf doesn't work

I built vcmi from source and it installed some libs in /usr/local/lib64/vcmi

I created vcmi.conf in /etc/ld.so.conf.d/ with the path.

$ cat /etc/ld.so.conf.d/vcmi.conf 
/usr/local/lib64/vcmi

After rebooting the system I tried run the vcmi client but I’m still getting library error.

$ vcmiclient 
vcmiclient: error while loading shared libraries: libvcmi.so: cannot open shared object file: No such file or directory

When I try to include the library path it works.

$ LD_LIBRARY_PATH=/usr/local/lib64/vcmi vcmiclient
Starting... 

So there has to be something wrong with the ld.so.conf but I have no idea how to investigate further.

I made no changes to /etc/ld.so.conf

$ cat /etc/ld.so.conf
include ld.so.conf.d/*.conf
1 Like
# Fix SELinux labels
sudo restorecon -R /etc/ld.so.*

# Update cache
sudo ldconfig

# Check cached libs
ldconfig -p | grep -e libvcmi.so
ls -l /usr/local/lib64/vcmi/libvcmi.so*

https://man.cx/ldconfig