I used LD_LIBRARY_PATH on Solaris, as it seems that some libraries are missing when scripts are sometimes kicked. Having this variable set at the beginning of the script is simply a safer way to work it.
Something worth mentioning (maybe you're looking):
ldd /path/to/narnia export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/path/to/dir/containing/lib
(make sure not to lose the previously installed directory)
Should work when reusing the command:
ldd /path/to/narnia librt.so.1 => /lib/librt.so.1 (0x00002b4eca08e000) libc.so.6 => /lib/libc.so.6 (0x00002b4eca49f000) libpthread.so.0 => /lib/libpthread.so.0 (0x00002b4eca7df000) /lib64/ld-linux-x86-64.so.2 (0x00002b4ec9e72000) libmylib.so.1 => ~/myprogdir/lib/libmylib.so.1 (0x00002b4eca9fa000)
This will lead to an error, if you can not find lib, do not forget to add the settings to your user profile:
source share