* Re: Redirecting Standard Input
@ 2001-01-12 10:45 Scott A. Hill
0 siblings, 0 replies; 4+ messages in thread
From: Scott A. Hill @ 2001-01-12 10:45 UTC (permalink / raw)
To: insight
Thanks for the help Tom, Fernando, and Nicholas, but your suggestions didn't
work. For clarification, I'm using
the Insight GUI on top of gdb. But after your suggestions I tried using the
setargs option in the basic gdb
debugger. No dice. I have also used the option in the Insight GUI to no
avail also. I realize that I could change
the code during debugging so that the file it's reading from is hard coded
(and I have in the past, but now I'm just
being lazy), but I was wondering why it worked in Win98 but not in NT. As
in the first e-mail, with Win98 I can
type the following command
gdb ./multivar.exe < ./multivar.inf
and the Insight GDB debugger pops up and I can step all the way through the
code. If this is more probably a
cygwin/bash issue, then I'll pop a questions over to the guys on the cygwin
list. Again, thanks for the quick replies
and help.
Scott
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: Redirecting Standard Input
2001-01-12 8:25 Scott A. Hill
2001-01-12 8:46 ` Fernando Nasser
@ 2001-01-12 9:28 ` Tom Tromey
1 sibling, 0 replies; 4+ messages in thread
From: Tom Tromey @ 2001-01-12 9:28 UTC (permalink / raw)
To: Scott A. Hill; +Cc: insight
>>>>> "Scott" == Scott A Hill <s.a.hill@larc.nasa.gov> writes:
Scott> The command I use to initiate the debugging session on
Scott> either machine is
Scott> gdb ./multivar < multivar.inf
This is wrong.
Instead invoke `gdb ./multivar', and then in gdb use `r < multivar.inf'.
Or use `set args < multivar.inf' and then plain `r'.
It would be nice if gdb could work the way you want -- I've wanted
that (plus some additional features to make it very useful) for years.
However, it doesn't work that way.
Tom
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: Redirecting Standard Input
2001-01-12 8:25 Scott A. Hill
@ 2001-01-12 8:46 ` Fernando Nasser
2001-01-12 9:28 ` Tom Tromey
1 sibling, 0 replies; 4+ messages in thread
From: Fernando Nasser @ 2001-01-12 8:46 UTC (permalink / raw)
To: Scott A. Hill; +Cc: insight
Scott, please send your messages as plain text. Not all e-mail
readers can handle HTML.
> "Scott A. Hill" wrote:
>
> I have a small Fortran project that reads a data file from standard input in order to obtain required paramaters. Normally, the code is executed with the following command
>
> ./multivar < multivar.inf
>
> During debugging sessions on my NT 4.0 box (using GDB 5.0 & cygwin 1.1.7), GDB or bash is not redirecting the input file to standard input. However, on my Win98 machine at home, the debugging session runs as anticipated. The command I use to initiate the debugging session on either machine is
>
> gdb ./multivar < multivar.inf
>
> Now for my question. Am I doing something wrong on the NT box or is NT doing something that won't allow the redirection? I did a search on the mail list archives but couldn't find anything. I'd appreciate any information. Also, please respond back to me since I'm not a member of this list. Thanks
>
Maybe you should post to the Cygwin list. You can find the list address at:
http://sources.redhat.com/cygwin/
However, can't you avoid this problem by reading your data from a separate
file instead of standard input? You can even do that while you are
debuging only.
--
Fernando Nasser
Red Hat - Toronto E-Mail: fnasser@redhat.com
2323 Yonge Street, Suite #300
Toronto, Ontario M4P 2C9
^ permalink raw reply [flat|nested] 4+ messages in thread
* Redirecting Standard Input
@ 2001-01-12 8:25 Scott A. Hill
2001-01-12 8:46 ` Fernando Nasser
2001-01-12 9:28 ` Tom Tromey
0 siblings, 2 replies; 4+ messages in thread
From: Scott A. Hill @ 2001-01-12 8:25 UTC (permalink / raw)
To: insight
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 983 bytes --]
I have a small Fortran project that reads
a data file from standard input in order to obtain required
paramaters.  Normally, the code is executed with the following
command
Â
    ./multivar <
multivar.inf
Â
During debugging sessions on my NT 4.0 box
(using GDB 5.0 & cygwin 1.1.7), GDB or bash is not redirecting
the input file to standard input. However, on my Win98 machine at
home, the debugging session runs as anticipated. The command I use to
initiate the debugging session on either machine isÂ
Â
   gdb ./multivar <
multivar.inf
Â
Now for my question. Am I doing something
wrong on the NT box or is NT doing something that won't allow the
redirection? I did a search on the mail list archives but couldn't
find anything. I'd appreciate any information. Also, please respond
back to me since I'm not a member of this list. Thanks
Â
Â
Scott Â
Â
Â
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2001-01-12 10:45 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2001-01-12 10:45 Redirecting Standard Input Scott A. Hill
-- strict thread matches above, loose matches on Subject: below --
2001-01-12 8:25 Scott A. Hill
2001-01-12 8:46 ` Fernando Nasser
2001-01-12 9:28 ` Tom Tromey
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).