I have several versions of the same library to which my program is dynamically linked. Sometimes I would like to change the version used.
I read that newer versions of Ubuntu no longer support LD_LIBRARY_PATHfor security reasons. I could add the path to /etc/ld.so.confand run ldconfig, but I will not always have root privileges on the system.
Does anyone know how to make changes to the library search path that a simple user can do? Suppose this happens often enough that updating configuration files is the last.
Edit: this is how I test what I expect to see and so on: I run lddin the program and see libfoo.so => /some/path/to/lib/libfoo.so. I add /path/to/different/version/lib(which contains a file called libfoo.so) to LD_LIBRARY_PATHand rerun ldd. The path for libfoo.so is the same as before when I expect to see libfoo.so => /path/to/different/version/lib/libfoo.so.
Thank,
Andrew
source
share