This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [PATCH] -nx-except-gdbtkinit option
- From: Eli Zaretskii <eliz at gnu dot org>
- To: Andrew STUBBS <andrew dot stubbs at st dot com>
- Cc: gdb-patches at sources dot redhat dot com
- Date: Thu, 17 Nov 2005 21:33:17 +0200
- Subject: Re: [PATCH] -nx-except-gdbtkinit option
- References: <437B5ED3.70805@st.com> <u64qs73r5.fsf@gnu.org> <437CB049.6060304@st.com>
- Reply-to: Eli Zaretskii <eliz at gnu dot org>
> Date: Thu, 17 Nov 2005 16:31:05 +0000
> From: Andrew STUBBS <andrew.stubbs@st.com>
> Cc: gdb-patches@sources.redhat.com
>
> > Second, please tell more about the situations when this option could
> > be useful.
>
> The specific case I use it for is in a wrapper utility which calls gdb
> as follows (roughly):
>
> gdb -nx-except-gdbtkinit -d scriptdir -x globalscript \
> -x ~/.gdbinit -x ./.gdbinit .....
>
> The purpose is (among other things) to set up transparently (to the
> user) a selection of user-defined commands (for connecting and
> configuring target boards) which are available to users in the .gdbinit
> files.
Sorry, I'm still confused. Doesn't GDB normally read ~/.gdbinit and
./.gdbinit? If so, why do you need to use -nx and then load these
init files manually?
> If -nx is used it has undesirable side effects when using Insight.
In case it wasn't clear, it's those ``undesirable side effects'' are
what I was asking to describe in some detail. I don't understand what
kind of problems it causes. Perhaps those are misfeatures or bugs we
need to fix, instead of introducing a new option.
> +@item -nx-except-gdbtkinit
> +@kindex -nx-except-gdbtkinit
> +The same as @samp{-nx} with the difference that it does not prevent
> +Insight from loading the settings file @code{.gdbtkinit}. If you are not
^^^^^
`.gdbtkinit' is a file name, so it should have the @file markup, not
@code.
Other than that, the documentation patch is approved, conditioned on
the code patch approval. Thanks.