From owner-freebsd-arch Fri Oct 19 2: 0:13 2001 Delivered-To: freebsd-arch@freebsd.org Received: from mailgate.originative.co.uk (mailgate.originative.co.uk [62.232.68.68]) by hub.freebsd.org (Postfix) with ESMTP id 9AE1137B407; Fri, 19 Oct 2001 02:00:06 -0700 (PDT) Received: from lobster.originative.co.uk (lobster [62.232.68.81]) by mailgate.originative.co.uk (Postfix) with ESMTP id B13191D169; Fri, 19 Oct 2001 09:59:59 +0100 (BST) Date: Fri, 19 Oct 2001 09:59:59 +0100 From: Paul Richards To: Greg Lehey , Nate Williams Cc: Dag-Erling Smorgrav , FreeBSD-arch@FreeBSD.org Subject: Re: /usr/src/sys/scripts? Message-ID: <20670000.1003481999@lobster.originative.co.uk> In-Reply-To: <20011019102425.G60412@wantadilla.lemis.com> References: <20011018101828.A88312@wantadilla.lemis.com> <15311.9266.464139.798092@nomad.yogotech.com> <20011019101722.C60412@wantadilla.lemis.com> <15311.30927.305794.574364@nomad.yogotech.com> <20011019102425.G60412@wantadilla.lemis.com> X-Mailer: Mulberry/2.1.0 (Linux/x86) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Content-Disposition: inline Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG --On Friday, October 19, 2001 10:24:26 +0930 Greg Lehey wrote: > On Thursday, 18 October 2001 at 18:50:23 -0600, Nate Williams wrote: >>>>>> BSD/OS has a directory /usr/src/sys/scripts which contains macros for >>>>>> kernel debugging. I have a number of macros here that I've >>>>>> accumulated over time, and I'd like to commit them. I'd also like to >>>>>> modify config(8) to install a .gdbinit in the kernel build directory >>>>>> if debugging has been specified; the .gdbinit would load macros from >>>>>> ../../scripts in order to help with kernel debugging. >>>>> >>>>> Wouldn't /var/crash be the logical place for .gdbinit? >>>> >>>> Yes, and no. Yes because that's where it may be useful, and no because >>>> it's a place for crashdumps, not for analyzing crashdumps. >>> >>> I've been thinking about this, and I think I agree with DES. We have >>> a basic problem that there are two different ways to use gdb, for >>> crash dumps and for remote serial debugging. The .gdbinit you use is >>> different in each case. I think it would make sense to install a >>> serial debug .gdbinit in the kernel build directory, and a dump >>> analysis .gdbinit in /var/crash (if present). >>> >>>> Most folks will probably not analyze the crashdumps, or they will copy >>>> them off somewhere else so they can free up /var/crash for the next >>>> crashdump, so I'd say stick .gdbinit somewhere else. >>> >>> If you can move the dump, you can move the .gdbinit. At least >>> /var/crash is a standard place to look for it. >> >> Only if we make it a standard place. A better place would be >> /sys/scripts/gdbinit.crash. > > Why? That's not obvious to somebody analyzing the dump in /var/crash. > One more thing to look for, one more pathname to remember. My preference would /usr/share/scripts/gdb. I'd rather have all the gdb scripts in one place a) so it's easier to remember where they all are b) it's easier to browse them together when you want to have a need to. Paul Richards FreeBSD Services Ltd http://www.freebsd-services.com To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message