I've read a lot of guidance that says the
LD_LIBRARY_PATH is searched before anything else, but one of my .so libraries is linking with
ldd mylib.so: ... libstdc++.so.6 => /usr/lib64/libstdc++.so.6 (0x00007f82abd18000) ...
mylib.so to link with
libstdc++.so.6 in another location, like
So I add
LD_LIBRARY_PATH, which does not have
/usr/lib64 in it, but it still doesn't find it there.
If I add:
setenv LD_PRELOAD /apps/gcc_4.8.0/lib/libstdc++.so.6
to my environment, there are no more linker errors. Yay, but that doesn't solve the problem. Users downstream aren't going to want to depend on this library being in the proper place. WHY ISN"T LD_LIBRARY_PATH BEING SEARCHED FIRST!?!