This is the mail archive of the gdb-prs@sources.redhat.com mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: shlibs/1906: runtime LD_LIBRARY_PATH not read


The following reply was made to PR shlibs/1906; it has been noted by GNATS.

From: Daniel Jacobowitz <drow@false.org>
To: hubert.degaudenzi@cern.ch
Cc: gdb-gnats@sources.redhat.com
Subject: Re: shlibs/1906: runtime LD_LIBRARY_PATH not read
Date: Wed, 6 Apr 2005 08:26:50 -0400

 On Wed, Apr 06, 2005 at 07:35:58AM -0000, hubert.degaudenzi@cern.ch wrote:
 > The LD_LIBRARY_PATH set on the command line is not read by gdb.
 > >Instead gdb is reading the profile files like .profile, .login,
 > >.cshrc, etc. I don't know if there is a good reason for this
 > >behavior but it's troublesome with trying to debug dynamic
 > >librairies. It's undocumented and it took my months (and the help of
 > >strace) to find out why gdb could not read my .so files.
 > >How-To-Repeat:
 > - do not set your LD_LIBRARY_PATH in your login/shell conf scripts
 > - set it on the command line
 > - test your executable with ldd
 > - try to debug with gdb
 
 This is a bug in your shell startup scripts.  GDB isn't starting a new
 login shell; it's starting a new command shell.  You should get the same
 results you would if you ran a shell script using this shell.
 
 What is your setting of $SHELL?  Bash won't normally do this, although
 zsh will read .zshenv.
 
 -- 
 Daniel Jacobowitz
 CodeSourcery, LLC


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]