This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [patch] New set auto-load-local-gdbinit + disable it by default
On Tue, Jan 17, 2012 at 8:26 AM, Jan Kratochvil
<jan.kratochvil@redhat.com> 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.
>
> <bite> 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. </bite>
<bite> ??? 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). ?E.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 cannot 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.