On 10/25/2009 09:04 PM, Bob Friesenhahn wrote:

The conditions in the code can simply be reversed so that the shared
library extension is tested first. Does anyone know a reason for the
current order?


It's been a while since I've looked at libltdl, so the following may not be correct.

It tries the .a first for the preopen loaders, as you guessed, but, of course, the other loaders don't know that and look for it anyway, failing, and flailing along, until the preopen loader has a chance, and (in most cases) fails.

Changing the search order would "break" things that use the preopen loader if there is a shared module also available. I don't think such a change is acceptable.

I would suggest that libltdl explicitly limit the searching for the .a archive to the preopen loader(s) to stop the filesystem getting involved there.

If lt_dlopen is passed an absolute path, it shouldn't really be searching at all. I'd call that a different bug though.

Feel free to delve in and propose patches.

Peter
--
Peter O'Gorman
http://pogma.com


_______________________________________________
http://lists.gnu.org/mailman/listinfo/libtool

Reply via email to