I have a situation where a package installs some of its own libraries,
as well as one library with the exact same name as on in /usr/lib.
However, the package's library was compiled with different flags and is
not compatible with the one in /usr/lib.
If I set LD_RUN_PATH to include the package's libraries, my executables
that link with the library in /usr/lib pick up the one in the package's
directory instead when they are run.
IIRC, SVR4.2 (e.g., UnixWare) had syntax for LD_RUN_PATH that told if
the paths in LD_RUN_PATH should be checked before or after the system
directories. Is there any such capability for Linux? I would in fact
prefer to put the package's library directory in ldconfig. However,
doing so keeps things like KDE, GNOME and YAST from running, as they
then pick up the offending/incompatible version of the library. That is
why I am even bothering with LD_RUN_PATH.