From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 32573 invoked by alias); 17 Jan 2012 16:44:47 -0000 Received: (qmail 32564 invoked by uid 22791); 17 Jan 2012 16:44:46 -0000 X-SWARE-Spam-Status: No, hits=-3.0 required=5.0 tests=AWL,BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,RCVD_IN_DNSWL_LOW,T_RP_MATCHES_RCVD X-Spam-Check-By: sourceware.org Received: from mail-vw0-f41.google.com (HELO mail-vw0-f41.google.com) (209.85.212.41) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Tue, 17 Jan 2012 16:44:33 +0000 Received: by vbbfa15 with SMTP id fa15so2140413vbb.0 for ; Tue, 17 Jan 2012 08:44:32 -0800 (PST) Received: by 10.52.155.196 with SMTP id vy4mr2775498vdb.12.1326818672910; Tue, 17 Jan 2012 08:44:32 -0800 (PST) MIME-Version: 1.0 Received: by 10.52.155.196 with SMTP id vy4mr2775490vdb.12.1326818672834; Tue, 17 Jan 2012 08:44:32 -0800 (PST) Received: by 10.220.229.1 with HTTP; Tue, 17 Jan 2012 08:44:32 -0800 (PST) In-Reply-To: <20120117162621.GA3883@host2.jankratochvil.net> References: <20120117095552.GA6141@host2.jankratochvil.net> <20120117162621.GA3883@host2.jankratochvil.net> Date: Tue, 17 Jan 2012 16:48:00 -0000 Message-ID: Subject: Re: [patch] New set auto-load-local-gdbinit + disable it by default From: Doug Evans To: Jan Kratochvil Cc: gdb-patches@sourceware.org X-System-Of-Record: true Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-IsSubscribed: yes Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org X-SW-Source: 2012-01/txt/msg00603.txt.bz2 On Tue, Jan 17, 2012 at 8:26 AM, Jan Kratochvil wrote: >> Another way to go is to enhance gdb's .gdbinit to check for which >> binary is being debugged and only do those things when it's gdb (and >> if necessary enhance the scripting language to support such a check). >> Seems generally useful, we should add support for it anyway. > > When one wants to debug gdb in gdb the file gdb/.gdbinit is really= the > most destructive as all its various commands succeed making the debugging > session completely unusable. ??? I don't understand. I also don't understand the reference to making the debugging session completely unusable. >> Well, there is make (and I'm sure others). =A0E.g., >> echo "default:; @echo Gotcha." > GNUmakefile && make >> :-) > > I was even thinking about make but I do not find it as a valid case. > The primary goal of `make' is to read local Makefile - therefore one cann= ot be > surprised by it. The user will be surprised if s/he has been using "Makefile" and not noticing that someone slipped in "GNUmakefile". S/he might see it and not even know that it trumps his/her own Makefile.