Date: Wed, 26 Apr 1995 03:11:13 -0700 From: asami@cs.berkeley.edu (Satoshi Asami | =?ISO-2022-JP?B?GyRCQHUbKEI=?= =?ISO-2022-JP?B?GyRCOCsbKEIgGyRCOC0bKEI=?=) To: nwestfal@orion.csci.csusb.edu Cc: jkh@freefall.cdrom.com, ports@FreeBSD.org Subject: Re: Building Fvwm... Message-ID: <199504261011.DAA09997@silvia.HIP.Berkeley.EDU> In-Reply-To: <Pine.SOL.3.91.950426024059.6125A-100000@orion> (message from Neal Westfall on Wed, 26 Apr 1995 02:43:33 -0700 (PDT))
next in thread | previous in thread | raw e-mail | index | archive | help
* Ok, the problem went away when I tried your suggestion. Thanks. You're welcome. * Now I feel quite silly for asking such a no-brainer question. :-) No kidding. We've been banging our heads to the wall over this for years. ;) I think we need to clear this up, it is very confusing to users that their program doesn't work even after a successful installation. I suspect this isn't reported very often because it works after rebooting and people just say "duh, gremlins?". One solution is to ask the user to set LD_LIBRARY_PATH to something like "/usr/lib:/usr/X11R6/lib:/usr/local/lib". This way ld.so will be able to find the library even when it's not in the hints file. I think this is kinda silly, though. Another is to find a way to run ldconfig "safely" from the installation step. By "safe", I mean so that it won't lose anything that's already in the hints file. I'm not aware of the problems that can be caused by executing ldconfig on a running system, so if someone knows more about this, please speak up. Offhand, I can think of two solutions: (1) Examine the output of "ldconfig -r" and cut out all the directory parts, and give it to ldconfig. For instance, ldconfig -r | sed -e "1d" -e "s/.*=> //" -e "s@/lib[^./]*\.so\..*@@" | \ sort | uniq will give us the list of directories. The knock on this approach is that we will lose information on the "order" of the directories, so if there are different shared libraries with same version numbers in distinct directories (how can that happen anyway? ;), we might pick up the wrong one. (2) Add a new flag to ldconfig saying "run yourself on the same path as the previous invocation". This is safe, right? We can make it create a new file alongside /var/run/ld.so.hints to store the "path" information. I think this is a much better solution. What do people think? Satoshi
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199504261011.DAA09997>