This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [RFC] usage of environment variable from the command line
- From: Daniel Jacobowitz <drow at false dot org>
- To: Denis PILAT <denis dot pilat at st dot com>
- Cc: gdb-patches at sourceware dot org
- Date: Fri, 21 Sep 2007 18:55:27 -0400
- Subject: Re: [RFC] usage of environment variable from the command line
- References: <46F13F2A.8010507@st.com>
On Wed, Sep 19, 2007 at 05:24:26PM +0200, Denis PILAT wrote:
> Hi,
>
> I have a patch that allows to use environment variable when typing commands.
> Environment variable must be surrounded by "%%" string.
> (Ex: "file %%REPOSITORY%%/obj/a.out" would be supported.)
>
>
> Is there any chance that such a patch could be accepted ?
> I've read from the gdb mailing list that I'm not the only one who wants to
> handle environment variable from the command line.
I think it would probably be useful to allow if we can find a way that
won't break something else.
I think that syntax is really ugly :-( Before we go ahead with this
can anyone think of a better one that won't conflict with source
language expressions?
Another problem is escaping. Right now, you're supposed to be able to
give either quoted strings or raw text to most commands (it
varies, I posted a summary a while back). Front ends won't know how
to escape the string if you have e.g. %% in your $PWD or want to
print a string containing %%.
--
Daniel Jacobowitz
CodeSourcery