From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 29290 invoked by alias); 20 Feb 2003 20:10:42 -0000 Mailing-List: contact gdb-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sources.redhat.com Received: (qmail 29272 invoked from network); 20 Feb 2003 20:10:42 -0000 Received: from unknown (HELO crack.them.org) (65.125.64.184) by 172.16.49.205 with SMTP; 20 Feb 2003 20:10:42 -0000 Received: from nevyn.them.org ([66.93.61.169] ident=mail) by crack.them.org with asmtp (Exim 3.12 #1 (Debian)) id 18lyus-0001d9-00; Thu, 20 Feb 2003 16:11:42 -0600 Received: from drow by nevyn.them.org with local (Exim 3.36 #1 (Debian)) id 18lx1d-0005fW-00; Thu, 20 Feb 2003 15:10:33 -0500 Date: Thu, 20 Feb 2003 20:10:00 -0000 From: Daniel Jacobowitz To: Paul Koning Cc: kevinb@redhat.com, kewarken@qnx.com, gdb@sources.redhat.com Subject: Re: GDB honouring RPATH in binaries. Message-ID: <20030220201032.GA21694@nevyn.them.org> Mail-Followup-To: Paul Koning , kevinb@redhat.com, kewarken@qnx.com, gdb@sources.redhat.com References: <0db801c2d914$78f80a50$0202040a@catdog> <1030220193301.ZM10611@localhost.localdomain> <20030220194049.GA19653@nevyn.them.org> <001301c2d918$894ef1d0$0202040a@catdog> <20030220194852.GA20424@nevyn.them.org> <002701c2d919$d07edce0$0202040a@catdog> <1030220195833.ZM10783@localhost.localdomain> <15957.17196.501000.893848@gargle.gargle.HOWL> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <15957.17196.501000.893848@gargle.gargle.HOWL> User-Agent: Mutt/1.5.1i X-SW-Source: 2003-02/txt/msg00446.txt.bz2 On Thu, Feb 20, 2003 at 04:05:48PM -0500, Paul Koning wrote: > >>>>> "Kevin" == Kevin Buettner writes: > > Kevin> For remote targets, you must have solib-absolute-prefix set. > Kevin> Searching host libraries (whether found via RPATH or some > Kevin> other means) is almost invariably wrong. > > I'd omit "almost". In fact, it would be useful if gdb could complain > for a remote debug when solib-absolute-prefix isn't set. That would > eliminate a lot of confusion when people forget to set it. When > debugging MIPS code, gdb is perfectly happy to load shared file symbol > tables from /usr/lib, even though those are x86 binaries! The result > is utter chaos, of course. It would be helpful if gdb prevented that > sort of simple user error. (I suppose another way to avoid that is to > have gdb check that the shared library it's examining is at least > meant for the same processor family, and I suppose the same > endianness...) Yeah, I used to see this a lot too (until we made solib-absolute-prefix automatic in our tools). Unfortunately there is no clear hook to figure out if a target is remote or local; and a lot of people actually do use gdbserver to talk to localhost... and then there's no way to know if it's the same root or not. -- Daniel Jacobowitz MontaVista Software Debian GNU/Linux Developer