This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
Re: SIGSEGV in insert to global container in shared lib
- To: Matthew Benjamin <MBenjamin at comshare dot com>
- Subject: Re: SIGSEGV in insert to global container in shared lib
- From: Todd Vierling <tv at pobox dot com>
- Date: Wed, 1 Jul 1998 16:16:19 -0400 (EDT)
- cc: egcs-bugs at cygnus dot com
On Wed, 24 Jun 1998, Matthew Benjamin wrote:
: First, when I try to use the latest GNU ld to link this code (with -fPIC and
: --shared options, of course), ld
: dumps core.
Well, that's a bug. :>
: I found that the Sun linker will link the code (-G option, of course). But,
: I get a SIGSEGV on the first attempt to insert a value into the container.
Did you remember to use collect2 - NOT just ld? The Sun linker won't work
because constructors will not be run unless collect2 is used to call the
linker. For this arrangement, configure egcs without "--with-gnu-ld" and
let it use the system linker.
--
-- Todd Vierling (Personal tv@pobox.com; Bus. todd_vierling@xn.xerox.com)