From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 9184 invoked by alias); 12 Aug 2002 16:20:35 -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 9132 invoked from network); 12 Aug 2002 16:20:33 -0000 Received: from unknown (HELO mx1.redhat.com) (66.187.233.31) by sources.redhat.com with SMTP; 12 Aug 2002 16:20:33 -0000 Received: from int-mx2.corp.redhat.com (nat-pool-rdu.redhat.com [172.16.52.200] (may be forged)) by mx1.redhat.com (8.11.6/8.11.6) with ESMTP id g7CG70l14019; Mon, 12 Aug 2002 12:07:01 -0400 Received: from potter.sfbay.redhat.com (potter.sfbay.redhat.com [172.16.27.15]) by int-mx2.corp.redhat.com (8.11.6/8.11.6) with ESMTP id g7CGKRu00795; Mon, 12 Aug 2002 12:20:28 -0400 Received: from romulus.sfbay.redhat.com (remus.sfbay.redhat.com [172.16.27.252]) by potter.sfbay.redhat.com (8.11.6/8.11.6) with ESMTP id g7CGKQe12780; Mon, 12 Aug 2002 09:20:26 -0700 Received: (from kev@localhost) by romulus.sfbay.redhat.com (8.11.6/8.11.6) id g7CGKOB32133; Mon, 12 Aug 2002 09:20:24 -0700 Date: Mon, 12 Aug 2002 09:20:00 -0000 From: Kevin Buettner Message-Id: <1020812162023.ZM32132@localhost.localdomain> In-Reply-To: Daniel Jacobowitz "Re: gdb/633: fully qualified pathnames in solib_map_sections() and remote debugging" (Aug 12, 11:55am) References: <20020806100634.11483.qmail@sources.redhat.com> <20020806132047.GA16450@nevyn.them.org> <1020809231206.ZM11775@localhost.localdomain> <20020812032527.GA3838@nevyn.them.org> <3D57C611.4010403@ges.redhat.com> <20020812143803.GA25086@nevyn.them.org> <3D57CF1A.4070405@ges.redhat.com> <1020812154849.ZM31876@localhost.localdomain> <20020812155518.GA32130@nevyn.them.org> To: Daniel Jacobowitz , Kevin Buettner Subject: Re: gdb/633: fully qualified pathnames in solib_map_sections() and remote debugging Cc: Andrew Cagney , jorma.laaksonen@hut.fi, gdb-gnats@sources.redhat.com, gdb@sources.redhat.com MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-SW-Source: 2002-08/txt/msg00101.txt.bz2 On Aug 12, 11:55am, Daniel Jacobowitz wrote: > > > There are two approaches: have solib_open() test for a local/remote > > > target; or, add methods to the target vector that allow solib_open() to > > > be written independant of the target. > > > > At the moment, I like the first approach better because it's simpler. > > I'd prefer that we wait on the more complicated approach until a need > > is demonstrated for the additional complexity. > > I agree. But as I said above, I don't want to make this decision based > on local/remote. An i386-pc-linux-gnu debugger using gdbserver will > default to looking in the system libraries right now; that's correct, I > think. I'm wondering how frequently this particular scenario occurs. If it occurs relatively infrequently, I think it'd be better to force the user to set solib-absolute-prefix and/or solib-search-path. It certainly seems safer than incorrectly using the host's environment variables. Usually, when I do the above, I'm running the debug agent in a chroot environment which has different libraries. For a quick and dirty test of the debug agent though, I'll frequently just run it on the host in which case using the host's libraries is correct. As noted earlier in this thread (and by yourself on at least one occassion), one of the things which we sorely need is a mechanism to check to see if gdb has loaded the correct shared object. Kevin