From: Bob Rossi <bob@brasko.net>
To: "jingzhao.ou" <jingzhao.ou@gmail.com>
Cc: gdb@sources.redhat.com
Subject: Re: Separating "shell dir" output from GDB/MI output
Date: Sun, 09 Oct 2005 12:33:00 -0000 [thread overview]
Message-ID: <20051009123326.GA436@white> (raw)
In-Reply-To: <b5706cf10510082219w52af98f3qf85a19bba7c8131e@mail.gmail.com>
On Sat, Oct 08, 2005 at 10:19:33PM -0700, jingzhao.ou wrote:
> Dear all,
>
> I am trying to see if it is possible to build a Tcl/Tk based GDB
> frontend using Bob Rossi's MI parser. For normal commands, it works
> just fine. However, if I execute "shell dir" command in gdb, the
> parser will report error. (see the end of the email)
>
> I am wondering if there is any way to separate the shell output from
> the normal GDB output. So that this problem can be solved properly.
>
> Sincerely hope that any one can give me a hand. I am using MinGW.
>
> Best regards,
> Jingzhao
>
> ===========================================
> (gdb)
> &"shell dir\n"
> Makefile gdbmi_grammar.tab.o gdbmi_pt.c main.tcl
> Makefile_orig gdbmi_grammar.txt gdbmi_pt.h tkGDB.c
> b gdbmi_grammar.y gdbmi_pt.o tkGDB.dll
> bb gdbmi_lexer.l lex.yy.c tkGDB.exe
> gdbmi_driver.c gdbmi_parser.c lex.yy.o tkGDB_bak.c
> gdbmi_grammar.tab.c gdbmi_parser.h libgdbmi_parser.a tkGDB_stub.c
> gdbmi_grammar.tab.h gdbmi_parser.o main.exe tk_gdb.tcl
> ^done
> (gdb)
> ===========================================
I think the best idea we've had so far for solving problems like this is
to add an option to GDB to have it output GDB/MI data on a file
descriptor X. For instance,
gdb -i=mi -mi-out-fd=30
and then when you fork/exec GDB you dup the 30 file descriptor so that
you can read the output.
Eli, do you know if this approach would be portable to windows nativly?
I could look into implementing this feature, since it would resolve a
*lot* of problems regarding I/O.
Thanks,
Bob Rossi
next prev parent reply other threads:[~2005-10-09 12:33 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-10-09 5:19 jingzhao.ou
2005-10-09 12:33 ` Bob Rossi [this message]
2005-10-09 17:04 ` jingzhao.ou
2005-10-09 17:12 ` Daniel Jacobowitz
2005-10-09 17:33 ` Bob Rossi
2005-10-09 20:02 ` Daniel Jacobowitz
2005-10-09 20:19 ` Bob Rossi
2005-10-09 20:26 ` Daniel Jacobowitz
[not found] ` <b5706cf10510091145v5bfa03ben44f62981f174c4a2@mail.gmail.com>
2005-10-09 18:47 ` jingzhao.ou
2005-10-09 20:04 ` Daniel Jacobowitz
2005-10-10 8:41 ` Re[2]: " Konstantin Karganov
2005-10-15 12:29 ` Eli Zaretskii
2005-10-15 12:27 ` Eli Zaretskii
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20051009123326.GA436@white \
--to=bob@brasko.net \
--cc=gdb@sources.redhat.com \
--cc=jingzhao.ou@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).