This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [PATCH, doc RFA] New option -B: simplify running gdb from build directory
- From: Doug Evans <dje at google dot com>
- To: Eli Zaretskii <eliz at gnu dot org>
- Cc: gdb-patches <gdb-patches at sourceware dot org>
- Date: Mon, 24 Mar 2014 18:28:04 -0700
- Subject: Re: [PATCH, doc RFA] New option -B: simplify running gdb from build directory
- Authentication-results: sourceware.org; auth=none
- References: <yjt2lhz6t716 dot fsf at ruffy dot mtv dot corp dot google dot com> <21272 dot 60289 dot 723000 dot 990365 at ruffy dot mtv dot corp dot google dot com> <834n3aqyaa dot fsf at gnu dot org> <CADPb22RKaBx1p2vF4-wGODZVe-QqdGc93Ax-bD82xb9Adr5EJw at mail dot gmail dot com> <83y50lq2b8 dot fsf at gnu dot org> <CADPb22Q6kyG7DVTzwgoJzBBgsJ8BZ9=-UCwyseTALZV=L4+__g at mail dot gmail dot com> <CADPb22R-ZyrkisXy8_JfrF3sheQRYz5r9RoSOSQ7d5DPi=M6jQ at mail dot gmail dot com> <CADPb22TCe_U8pZC2vv9tNjMu+HwET6nX=bFV5-N7ikAcKS+7wQ at mail dot gmail dot com>
On Mon, Mar 24, 2014 at 6:20 PM, Doug Evans <dje@google.com> wrote:
> On Mon, Mar 24, 2014 at 6:02 PM, Doug Evans <dje@google.com> wrote:
>> I just want to stop having to type --data-directory all the time when
>> I run gdb under gdb in emacs (without doing hacks like having a
>> special emacs command just for debugging gdb). It's unlikely ISTM the
>> community is going to agree on a heuristic for determining whether gdb
>> is being run from the build directory any time soon, so let's just let
>> it go for now. Typing "./gdb -B" is fine by me. I can think of
>> alternatives (eg., name the binary in the build directory as xgdb and
>> have gdb check argv[0]) but I prefer -B.
>
> Hah! Gotta love the crystalization of thinking that happens after one
> clicks Send.
>
> For the moment running from the build directory only requires passing
> --data-directory.
> I'm going to add a -D shortcut for --data-directory and make gdb
> expand out relative paths for data-directory (it's kinda a bug that it
> doesn't now).
>
> That way I can type ./gdb -D .
> which is good enough. :-)
Bleah.
That would have to be typed as ./gdb -D da<TAB>
or ../gdb -D ../da<TAB> if run from the testsuite directory
which maybe I can live with.