This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: Weird x86 Linux/GNU crashes
- From: "H. J. Lu" <hjl at lucon dot org>
- To: Mark Mitchell <mark at codesourcery dot com>
- Cc: gcc at gcc dot gnu dot org
- Date: Tue, 30 Jul 2002 15:56:13 -0700
- Subject: Re: Weird x86 Linux/GNU crashes
- References: <200207302248.g6UMmCU31451@localhost.localdomain>
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.