Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to remove an entry from ld.so.cache?

Tags:

shell

I have just added one entry use ldconfig DIR and it worked. But now the DIR is not needed and I want to delete it but I don't know how to do it. I have read the manual of ldconfig and also googled.

Hope someone can help.

like image 556
zhangyangyu Avatar asked Oct 20 '22 10:10

zhangyangyu


1 Answers

From the man page

ldconfig creates the necessary links and cache to the most recent shared libraries found in the directories specified on the command line, in the file /etc/ld.so.conf, and in the trusted directories (/lib and /usr/lib).

This seems to imply that you can remove an entry by editing /etc/ld.so.conf manually to delete that line. Or if it was cached inside /lib and /usr/lib, you should be able to delete the links inside those trusted directories.

like image 137
merlin2011 Avatar answered Oct 24 '22 16:10

merlin2011