This is the mail archive of the cygwin mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: getting gdb I/O and progam I/O into separate windows


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

According to René Berber on 8/31/2008 10:42 PM:
> Charles D. Russell wrote:
> 
>> Can this be done?  I can't redirect program output (from ncurses) into
>> an rxvt window using the tty command in gdb.  Googling gdb+tty+cygwin
>> shows that there have been problems in the past, but I didn't find
>> anything recent.
> 
> That's what Insight is for (and ddd under X), a GUI that separates code
> from memory and the program's output (plus gdb output, breakpoints, and
> so on).

Or you can use process attaching, sticking with command-line gdb instead
of gui.  I frequently start a program in one console, then in another
console, use ps to determine its pid, then invoke 'gdp path/to/program
pid' where pid was determined from ps to break in to the program.
Depending on the program, it may be helpful to recompile with an added
sleep() in main, to give you time to attach before it does anything worth
debugging.

- --
Don't work too hard, make some time for fun as well!

Eric Blake             ebb9@byu.net
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (Cygwin)
Comment: Public key at home.comcast.net/~ericblake/eblake.gpg
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iEYEARECAAYFAki73UEACgkQ84KuGfSFAYCbjQCglKo6X9XBajjuO8h31yiYVNdF
DGMAn08iwqI2AHS+Hnd5xoKe45M5Asbh
=wdIX
-----END PGP SIGNATURE-----

--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]