From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 10333 invoked by alias); 10 Apr 2007 21:35:21 -0000 Received: (qmail 10324 invoked by uid 22791); 10 Apr 2007 21:35:21 -0000 X-Spam-Check-By: sourceware.org Received: from return.false.org (HELO return.false.org) (66.207.162.98) by sourceware.org (qpsmtpd/0.31) with ESMTP; Tue, 10 Apr 2007 22:35:17 +0100 Received: from return.false.org (localhost [127.0.0.1]) by return.false.org (Postfix) with ESMTP id 6CE4A4B267; Tue, 10 Apr 2007 16:35:16 -0500 (CDT) Received: from caradoc.them.org (dsl093-172-095.pit1.dsl.speakeasy.net [66.93.172.95]) by return.false.org (Postfix) with ESMTP id 412254B262; Tue, 10 Apr 2007 16:35:16 -0500 (CDT) Received: from drow by caradoc.them.org with local (Exim 4.63) (envelope-from ) id 1HbNzf-0001nV-9F; Tue, 10 Apr 2007 17:35:15 -0400 Date: Tue, 10 Apr 2007 21:35:00 -0000 From: Daniel Jacobowitz To: Joel Brobecker Cc: gdb@sourceware.org Subject: Re: [sparc-solaris] unexpected warning when starting program Message-ID: <20070410213515.GA6338@caradoc.them.org> Mail-Followup-To: Joel Brobecker , gdb@sourceware.org References: <20070312051646.GI14401@adacore.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20070312051646.GI14401@adacore.com> User-Agent: Mutt/1.5.15 (2007-04-09) X-IsSubscribed: yes Mailing-List: contact gdb-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sourceware.org X-SW-Source: 2007-04/txt/msg00055.txt.bz2 Looking at this again... On Sun, Mar 11, 2007 at 10:16:46PM -0700, Joel Brobecker wrote: > Slightly later, GDB tries to update its list of shared libraries again, > and this time finds that base address. So it now scans a different > memory region for that list of shared libraries. And in addition to > that, there is the following code that was recently added: > > /* On Solaris, the dynamic linker is not in the normal list of > shared objects, so make sure we pick it up too. Having > symbol information for the dynamic linker is quite crucial > for skipping dynamic linker resolver code. */ > if (lm == 0 && ldsomap == 0) > lm = ldsomap = solib_svr4_r_ldsomap (); > > The information extracted from this entry gives us the following path > to the loader: /lib/ld.so.1. The paths are different!!! ... > I am not sure how to fix it either. On solaris 2.8 and 2.9, the two > files are identical but distinct - one is not a link to the other. > On solaris 2.10, however, one is a link of the other, so we could > presumably check the fullpath instead of doing a direct name comparison. > But that would be pretty expensive for just one type of host, no? xfullpath isn't really that expensive. We could even do it only for ld.so.1; I think that's not totally unreasonable. Are you sure the files are distinct on your Solaris 2.8 / 2.9? I have a symlink /lib -> ./usr/lib on 2.8, and a symlink /usr/lib/ld.so.1 -> ../../lib/ld.so.1 on 2.10. -- Daniel Jacobowitz CodeSourcery