@@ -89,6 +89,8 @@ const char *jl_loader_probe_system_library(const char *libname, const char *symb
8989{
9090 char buf [PATH_MAX ];
9191
92+ fprintf (stderr , "scanning LD_LIBRARY_PATH\n" );
93+
9294 /**
9395 * Make a best-effort attempt to emulate the linker's use of LD_LIBRARY_PATH
9496 **/
@@ -117,6 +119,8 @@ const char *jl_loader_probe_system_library(const char *libname, const char *symb
117119 }
118120 }
119121
122+ fprintf (stderr , "scanning ld.so.cache\n" );
123+
120124 /**
121125 * Check the ld.so.cache for the library. Assuming we can find the cache,
122126 * this is by far our best chance to locate the lib successfully.
@@ -145,6 +149,8 @@ const char *jl_loader_probe_system_library(const char *libname, const char *symb
145149 munmap ((void * )cache , sz );
146150 }
147151
152+ fprintf (stderr , "scanning default libdirs\n" );
153+
148154 /**
149155 * As a last-ditch effort, try to emulate / search the "default" libdirs used
150156 * by the GLIBC dynamic linker.
@@ -156,6 +162,7 @@ const char *jl_loader_probe_system_library(const char *libname, const char *symb
156162 buf [0 ] = '\0' ;
157163 strcat (buf , default_libdirs [i ]);
158164 strcat (buf , libname );
165+ fprintf (stderr , "default libdir: \"%s\"\n" , buf );
159166 if (jl_loader_locate_symbol (buf , symbol ))
160167 return strdup (buf );
161168 }
0 commit comments