From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 3966 invoked by alias); 4 Oct 2004 16:27:33 -0000 Mailing-List: contact gdb-patches-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sources.redhat.com Received: (qmail 3956 invoked from network); 4 Oct 2004 16:27:32 -0000 Received: from unknown (HELO mx1.redhat.com) (66.187.233.31) by sourceware.org with SMTP; 4 Oct 2004 16:27:32 -0000 Received: from int-mx1.corp.redhat.com (int-mx1.corp.redhat.com [172.16.52.254]) by mx1.redhat.com (8.12.11/8.12.10) with ESMTP id i94GRRwY023090 for ; Mon, 4 Oct 2004 12:27:27 -0400 Received: from localhost.redhat.com (porkchop.devel.redhat.com [172.16.58.2]) by int-mx1.corp.redhat.com (8.11.6/8.11.6) with ESMTP id i94GRRr32336; Mon, 4 Oct 2004 12:27:27 -0400 Received: from gnu.org (localhost [127.0.0.1]) by localhost.redhat.com (Postfix) with ESMTP id A460428D2; Mon, 4 Oct 2004 12:27:10 -0400 (EDT) Message-ID: <416179DE.70401@gnu.org> Date: Mon, 04 Oct 2004 16:27:00 -0000 From: Andrew Cagney User-Agent: Mozilla/5.0 (X11; U; NetBSD macppc; en-GB; rv:1.4.1) Gecko/20040831 MIME-Version: 1.0 To: Daniel Jacobowitz Cc: Mark Kettenis , gdb-patches@sources.redhat.com Subject: Re: [patch/rfc] Build inf-ptrace.o when ptrace available References: <415DC09D.2070407@gnu.org> <200410012154.i91Ls6lE001359@elgar.sibelius.xs4all.nl> <41615D1E.8070007@gnu.org> <20041004143416.GA6653@nevyn.them.org> In-Reply-To: <20041004143416.GA6653@nevyn.them.org> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-SW-Source: 2004-10/txt/msg00055.txt.bz2 > On Mon, Oct 04, 2004 at 10:24:30AM -0400, Andrew Cagney wrote: > >>>> > Date: Fri, 01 Oct 2004 16:39:57 -0400 >>>> > From: Andrew Cagney >>>> > >>>> > Hello, >>>> > >>>> > This modifies GDB's configure to build inf-ptrace.o whenever the ptrace >>>> > call is available. Thoughts? >>>> > >>>> >I'm not sure. On the one hand, yes, inf-ptrace should compile & link >>>> >on any system that has ptrace. On the other hand, actually using this >>>> >stuff is still a per-target decision, and there are quite a few >>>> >targets that have ptrace, but dont use it (Solaris, OSF/1, HP-UX). >> >>> >>> FYI, it isn't _linked_, except on GDB executables that use it. >>> >> >>>> >I'm also thinking about the ultimate replacement of the makefile >>>> >fragments in config/*/. I think we should move towards a configure >>>> >script where we can use wildcards to set some sensible defaults. >>>> >There we'd have something like: >>>> > >>>> >*-*-*bsd*) >>>> > native_sources="inf-ptrace.c bsd-nat.c" >>>> > ;; >>>> > >>>> >*-*-linux*) >>>> > native_sources="inf-ptrace.c linux-nat.c" >>>> > ;; > > > This is just a style change. Functionally, it is _exactly_ the same as > having a makefile fragment. Personally, I prefer the makefile > fragments. As mark noted: > >I'm also thinking about the ultimate replacement of the makefile > >fragments in config/*/. I think we should move towards a configure > >script where we can use wildcards to set some sensible defaults. > >There we'd have something like: and I have to agree - having to add the same file to all those nat files sux. >>> Going forward we need to get GNU/Linux and other systems using procfs >>> and an obvious migration path for that is to build support for both >>> procfs and ptrace into a single GDB. The default being to use ptrace. > > > Huh? We don't "need" to do this, and in fact it's not even clearly > desirable. I don't get where you're coming from. It's also 100% > orthogonal to this issue. Er, linux-nat already contains all sort of [snip] manipulating /proc. As more features get added we'll be forced to add still more. Shouldn't we cut our losses? Why is it orthogonal? If we assume that configure determines when /proc and ptrace() and provides both to the user it certainly isn't. Idea's such as Mark's and mine would make it easier. Andrew