Which environment variable you have to setup to use shared libraries that are not in the standard search path?
Answer: LD_LIBRARY_PATH
Explanation:
See http://tldp.org/HOWTO/Program-Library-HOWTO/shared-libraries.html
You can temporarily substitute a different library for this particular execution. In Linux, the environment variable LD_LIBRARY_PATH is a colon-separated set of directories where libraries should be searched for first, before the standard set of directories; this is useful when debugging a new library or using a nonstandard library for special purposes
LD_LIBRARY_PATH