This is the mail archive of the
gdb@sourceware.cygnus.com
mailing list for the GDB project.
Problem with LD_LIBRARY_PATH and gdb 4.17, 4.18 in Solaris 2.7
- To: gdb at sourceware dot cygnus dot com
- Subject: Problem with LD_LIBRARY_PATH and gdb 4.17, 4.18 in Solaris 2.7
- From: Guangsheng Liu <gliu at eloq dot com>
- Date: Thu, 23 Dec 1999 16:38:31 -0500
Hi,
I have a test program using libec50.so which is a share lib, and I am
using the following 2 lines to build it.
gcc -g -o test.o -c test.c
gcc -g -o test test.o -lec50
pwd: home/pkg/gliu/12_15/eti/rel/DEBUG/lib/solaris/sparc
ls: libec50.so test test.c test.o
Everything is in the same directory which is current directory. I can
run the "test" under
the shell as long as the " LD_LIBRARY_PATH" points to the current
directory. Then I invoke
"gdb test". I cannot debug it in gdb. It always gave me the following error.
--------------------------------
gdb test
run
Starting program: /home/pkg/gliu/12_15/eti/rel/DEBUG/lib/solaris/sparc/test
ld.so.1: /home/pkg/gliu/12_15/eti/rel/DEBUG/lib/solaris/sparc/test:
fatal: libec50.so: open failed: No such file or directory
Program terminated with signal SIGKILL, Killed.
The program no longer exists.
---------------------------------
I used "show env LD_LIBRARY_PATH" and I can see the gdb inherit the
"LD_LIBRARY_PATH" correctly from the shell,
and including my current directory:
home/pkg/gliu/12_15/eti/rel/DEBUG/lib/solaris/sparc.
I tried gdb 4.18, it has the same problem. By the way, I am runing
Solaris2.7
Doesn't anybody have any idea?
Thanx a lot.
Merry Xmas.