On Wed, Mar 20, 2002 at 04:56:00PM -0800, Anthony A. D. Talltree wrote:
> >Thank you all for the advice, I got through make successfully after setting
> >LD_LIBRARY_PATH.
> 
> >However, after I've installed Amanda, there's a new problem.  When I try
> >to run any amanda executables, I get the following error:
> 
> >$ amlabel DailySet1 DailySet1-001
> >ld.so.1: amlabel: fatal: libreadline.so.4: open failed: No such file or
> >directory

The environment for LD_LIBRARY_PATH was set during the build, but is not
retained by the executables.  It has to be reset in the runtime environment.
If set in the .profile of the <amanda_user> this would allow amlabel to
succeed from the command line.  However, amcheck/amdump run from a crontab
entry does not process the .profile.  They don't use readline so this
specific library may not cause a problem.

> This is why linking with -R is the better answer.  The executables then
> know where to find the dynamic libs without LD_LIBRARY_PATH or
> LD_RUN_PATH. 

Absolutely!

> One way to do this might be
> 
> unsetenv LD_LIBRARY_PATH
> setenv LD_FLAGS "-R /usr/local/lib"

Assuming "MT" is using c-shell :)

> 
> before running configure, presuming that readline is in /usr/local/lib. 
> Use ldd on completed binaries to ensure that they can find the libs.

An alternative for Solaris users (eg "MT") is the ld.config file.  This is
created and maintained by the crle command.  It specifies what directories
the dynamic linker searches for its libraries, i.e., the default LD_LIBRARY_PATH.
If the contents of /usr/local/lib are trusted, this directory could be added
to the default dirs in ld.config.

jl
-- 
Jon H. LaBadie                  [EMAIL PROTECTED]
 JG Computing
 4455 Province Line Road        (609) 252-0159
 Princeton, NJ  08540-4322      (609) 683-7220 (fax)

Reply via email to