This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC 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: Weird x86 Linux/GNU crashes


On Tue, Jul 30, 2002 at 03:48:12PM -0700, Mark Mitchell wrote:
> 
> I've got some changes to the C++ front end that I've tested pretty
> well (make check-g++).  Then, I updated the compiler and rebuilt from
> scratch in preparation for final testing and check-in.  Now, every
> dynamically linked C++ binary crashes, but statically linked ones are
> OK.
> 
> The behavior is somewhat odd; GDB seems to get confused:
> 
> bash-2.05$ LD_LIBRARY_PATH=/home/mitchell/dev/gcc-mainline/objdir/i686-pc-linux-gnu//libstdc++-v3/src/.libs:. ./bitfield1.exe 
> Segmentation fault
> 
> bash-2.05$ LD_LIBRARY_PATH=/home/mitchell/dev/gcc-mainline/objdir/i686-pc-linux-gnu//libstdc++-v3/src/.libs:. gdb ./bitfield1.exe 
> (gdb) run
> Starting program: /home/mitchell/dev/gcc-mainline/objdir/gcc/./bitfield1.exe 
> /home/mitchell/dev/gcc-mainline/objdir/gcc/./bitfield1.exe: error while loading shared libraries: libstdc++.so.5: cannot open shared object file: No such file or directory
> (gdb) show env LD_LIBRARY_PATH
> LD_LIBRARY_PATH = /home/mitchell/dev/gcc-mainline/objdir/i686-pc-linux-gnu//libstdc++-v3/src/.libs:.
> 
> So, GDB has the right LD_LIBRARY_PATH, but somehow cannot load the
> libraries.  From outside GDB, the libraries are loaded OK, but the
> binaries crash.

Try:

(gdb) set env LD_DEBUG=libs
(gdb) run


H.J.


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