What is ldconfig?
I had a program which wasn't working because it was looking for the so files in /usr/lib but when I looked at /etc/ld.so.conf it had /usr/local/lib in there already. So I ran /sbin/ldconfig and the program worked.
What is ldconfig, and why didn't this work initially? Shouldn't this be established when the computer starts? |
"I had a program which wasn't working because it was looking for the so files in /usr/lib but when I looked at /etc/ld.so.conf it had /usr/local/lib in there already. So I ran /sbin/ldconfig and the program worked."
/etc/ld.so.conf is the library where you set up the list of libraries to be included in the dynamic link libraries. But /etc/ld.so.conf is not the list that the kernel actually uses for a dynamic link library list. The kernel uses /etc/ld.so.cache. ldconfig is the program which takes /etc/ld.so.conf and builds /etc/ld.so.cache. "What is ldconfig, and why didn't this work initially? Shouldn't this be established when the computer starts?" You were probably in the situation that /usr/local/lib was in /etc/ld.so.conf but was not in /etc/ld.so.cache until after you ran ldconfig. --------------------- Steve Stites |
Thanks! :)
|
All times are GMT -5. The time now is 10:27 PM. |