comp.lang.ada
 help / color / mirror / Atom feed
* GDB w/GNAT 3.11p w/NT4.0 Question
@ 1999-03-11  0:00 Jackie & Barry Schiff
  1999-03-12  0:00 ` Martin C. Carlisle
  0 siblings, 1 reply; 7+ messages in thread
From: Jackie & Barry Schiff @ 1999-03-11  0:00 UTC (permalink / raw)


I recently installed GNAT 3.11p.  Its been awhile since I used GNAT and
I must say I was very impressed with how it has progressed. Ok now for
the question:

I am using it under NT 4.0, and so far am using the AdaGIDE editor
environment installed with it (used to use EMACS and maybe will switch
again but just giving this a try).  Anyhow I have a program with text_io
input/output. When I go to run it under the debugger, which I do by
hitting the debug button inside of AdaGIDE, the output seems to get
correctly redirected to an MSDOS command window but it appears that the
input does not. Thus the program bombs once it gets to an input
statement (eg. Text_io.Get_Line).  Surely I must be doing something
wrong I just have not dug it out yet. If anybody knows the answer I
would surely appreciate it.

Thanks in advance,

--Barry Schiff





^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: GDB w/GNAT 3.11p w/NT4.0 Question
  1999-03-11  0:00 GDB w/GNAT 3.11p w/NT4.0 Question Jackie & Barry Schiff
@ 1999-03-12  0:00 ` Martin C. Carlisle
  1999-03-12  0:00   ` Steve Doiel
  1999-03-13  0:00   ` Jackie & Barry Schiff
  0 siblings, 2 replies; 7+ messages in thread
From: Martin C. Carlisle @ 1999-03-12  0:00 UTC (permalink / raw)


I have not experienced this problem, but I suggest the following to
narrow it down:

1) Reinstall and see if it goes away.  (Unfortunately, this happens 
far too often on Windows).

2) run GDB from a DOS prompt (gdb myprogram.exe)
and see if it exhibits the same behavior.  

If so, then you've isolated the problem to be outside the editor.  The
GNAT chat list may be a good source of expert advice.  Email 
chat-request@gnat.com to join.

If not, then I suppose it becomes my problem.  Email me at carlislem@acm.org
Please include a copy of the smallest program that behaves poorly.

--Martin

In article <36E81651.5B91E3D3@netspace.net.au>,
Jackie & Barry Schiff  <schiff@netspace.net.au> wrote:
>I am using it under NT 4.0, and so far am using the AdaGIDE editor
>environment installed with it (used to use EMACS and maybe will switch
>again but just giving this a try).  Anyhow I have a program with text_io
>input/output. When I go to run it under the debugger, which I do by
>hitting the debug button inside of AdaGIDE, the output seems to get
>correctly redirected to an MSDOS command window but it appears that the
>input does not. Thus the program bombs once it gets to an input
>statement (eg. Text_io.Get_Line).  Surely I must be doing something
>wrong I just have not dug it out yet. If anybody knows the answer I
>would surely appreciate it.


-- 
Martin C. Carlisle, Asst Prof of Computer Science, US Air Force Academy
mcc@cs.usafa.af.mil, http://www.usafa.af.mil/dfcs/bios/carlisle.html
DISCLAIMER:  This content in no way reflects the opinions, standards or 
policy of the US Air Force Academy or the United States Government.




^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: GDB w/GNAT 3.11p w/NT4.0 Question
  1999-03-12  0:00 ` Martin C. Carlisle
@ 1999-03-12  0:00   ` Steve Doiel
  1999-03-13  0:00     ` Jackie & Barry Schiff
  1999-03-13  0:00   ` Jackie & Barry Schiff
  1 sibling, 1 reply; 7+ messages in thread
From: Steve Doiel @ 1999-03-12  0:00 UTC (permalink / raw)


FYI: I experiece the same behaviour.  My answer?  I run the debugger from a
command line in a console window.

SteveD
>I am using it under NT 4.0, and so far am using the AdaGIDE editor
>>environment installed with it (used to use EMACS and maybe will switch
>>again but just giving this a try).  Anyhow I have a program with text_io
>>input/output. When I go to run it under the debugger, which I do by
>>hitting the debug button inside of AdaGIDE, the output seems to get
>>correctly redirected to an MSDOS command window but it appears that the
>>input does not. Thus the program bombs once it gets to an input
>>statement (eg. Text_io.Get_Line).  Surely I must be doing something
>>wrong I just have not dug it out yet. If anybody knows the answer I
>>would surely appreciate it.







^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: GDB w/GNAT 3.11p w/NT4.0 Question
  1999-03-13  0:00   ` Jackie & Barry Schiff
@ 1999-03-13  0:00     ` David C. Hoos, Sr.
  0 siblings, 0 replies; 7+ messages in thread
From: David C. Hoos, Sr. @ 1999-03-13  0:00 UTC (permalink / raw)



-----Original Message-----
From: Jackie & Barry Schiff <schiff@netspace.net.au>
Newsgroups: comp.lang.ada
To: Martin C. Carlisle <mcc@entropy.cs.princeton.edu>
Date: Saturday, March 13, 1999 8:50 AM
Subject: Re: GDB w/GNAT 3.11p w/NT4.0 Question


>Here is a small program that will show this behavior.
>
<snip>
Unfortunately, the program you supplied would not compile.
There is no Text_IO.Put_Line procedure with a parameter
with the formal name "Last."

I slightly reworked your program as follows:


procedure Show_Debugger_Problem is
    Line : String (1 .. 100);
    Length : Natural;
begin
    Ada.Text_Io.Put ("Enter Line : ");
    Ada.Text_Io.Get_Line (Item => Line, Last => Length);
    Ada.Text_Io.Put_Line ("You Entered """ & Line (1 .. Length) & """");
end Show_Debugger_Problem;

And, to answer the previous post....
-----Original Message-----
From: Jackie & Barry Schiff <schiff@netspace.net.au>
Newsgroups: comp.lang.ada
To: Steve Doiel <nospam_steved@pacifier.com>
Date: Saturday, March 13, 1999 8:47 AM
Subject: Re: GDB w/GNAT 3.11p w/NT4.0 Question

>Thanks for your reply. Just a quick question. How do you run from a
>console? When I type "gdb program.exe" in console window  it brings up
>the GUI debugger and I get the same behavior. Must be a switch I give to
>GDB telling it not be GUI debugger?
>
As with almost all GNU programs, typing the command name with the
single argument --help yields information about command line switches.

For gdb:

[d:/gnat_examples]$ gdb --help
GDB 4.16.gnat.3.11b-1 (i686-pc-mingw32),
Copyright 1996 Free Software Foundation, Inc.
This is the GNU debugger.  Usage:
    gdb [options] [executable-file [core-file or process-id]]
Options:
  --help             Print this message.
  --quiet            Do not print version number on startup.
  --fullname         Output information used by emacs-GDB interface.
  --emacs-gdbtk      Enable emacs-GDBTK interface.
  --epoch            Output information used by epoch emacs-GDB interface.
  --batch            Exit after processing options.
  --nx               Do not read .gdbinit file.
  --tty=TTY          Use TTY for input/output by the program being debugged.
  --cd=DIR           Change current directory to DIR.
  --directory=DIR    Search for source files in DIR.
  --command=FILE     Execute GDB commands from FILE.
  --symbols=SYMFILE  Read symbols from SYMFILE.
  --exec=EXECFILE    Use EXECFILE as the executable.
  --se=FILE          Use FILE as symbol file and executable file.
  --core=COREFILE    Analyze the core dump COREFILE.
  -b BAUDRATE        Set serial port baud rate used for remote debugging.
  --mapped           Use mapped symbol files if supported on this system.
  --readnow          Fully read symbol files on first access.
  --nw               Do not use a window interface.

For more information, type "help" from within GDB, or consult the
GDB manual (available as on-line info or a printed manual).
[d:/gnat_examples]$

The other method which answers a significant portion of the questions
posed about GNAT on this newsgroup is to read the wealth of documentation
provided with GNAT.

This method would have also told you about the -nw switch (which is quite
common for GNU programs, by the way).








^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: GDB w/GNAT 3.11p w/NT4.0 Question
  1999-03-13  0:00     ` Jackie & Barry Schiff
@ 1999-03-13  0:00       ` Sune Falck
  0 siblings, 0 replies; 7+ messages in thread
From: Sune Falck @ 1999-03-13  0:00 UTC (permalink / raw)


use "gdb -nw" to start gdb in non window mode.

/Sune Falck

Jackie & Barry Schiff skrev i meddelandet
<36EA7A91.59D3A118@netspace.net.au>...
>Steve
>
>Thanks for your reply. Just a quick question. How do you run from a
>console? When I type "gdb program.exe" in console window  it brings up
>the GUI debugger and I get the same behavior. Must be a switch I give to
>GDB telling it not be GUI debugger?







^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: GDB w/GNAT 3.11p w/NT4.0 Question
  1999-03-12  0:00   ` Steve Doiel
@ 1999-03-13  0:00     ` Jackie & Barry Schiff
  1999-03-13  0:00       ` Sune Falck
  0 siblings, 1 reply; 7+ messages in thread
From: Jackie & Barry Schiff @ 1999-03-13  0:00 UTC (permalink / raw)
  To: Steve Doiel

Steve

Thanks for your reply. Just a quick question. How do you run from a
console? When I type "gdb program.exe" in console window  it brings up
the GUI debugger and I get the same behavior. Must be a switch I give to
GDB telling it not be GUI debugger?

--Barry Schiff

Steve Doiel wrote:

> FYI: I experiece the same behaviour.  My answer?  I run the debugger
> from a
> command line in a console window.
>
> SteveD
> >I am using it under NT 4.0, and so far am using the AdaGIDE editor
> >>environment installed with it (used to use EMACS and maybe will
> switch
> >>again but just giving this a try).  Anyhow I have a program with
> text_io
> >>input/output. When I go to run it under the debugger, which I do by
> >>hitting the debug button inside of AdaGIDE, the output seems to get
> >>correctly redirected to an MSDOS command window but it appears that
> the
> >>input does not. Thus the program bombs once it gets to an input
> >>statement (eg. Text_io.Get_Line).  Surely I must be doing something
> >>wrong I just have not dug it out yet. If anybody knows the answer I
> >>would surely appreciate it.







^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: GDB w/GNAT 3.11p w/NT4.0 Question
  1999-03-12  0:00 ` Martin C. Carlisle
  1999-03-12  0:00   ` Steve Doiel
@ 1999-03-13  0:00   ` Jackie & Barry Schiff
  1999-03-13  0:00     ` David C. Hoos, Sr.
  1 sibling, 1 reply; 7+ messages in thread
From: Jackie & Barry Schiff @ 1999-03-13  0:00 UTC (permalink / raw)
  To: Martin C. Carlisle

Here is a small program that will show this behavior.

with Text_Io;
procedure Show_Debugger_Problem is
    Line : String(1..100);
    Length : Natural;
begin
    Text_Io.Put("Enter Line : ");
    Text_Io.Put_Line(Item => Line, Last => Length);
    Text_Io.Put_Line("You Entered " & Line(1..Length));
end Show_Debugger_Problem;

--Barry Schiff



Martin C. Carlisle wrote:

> I have not experienced this problem, but I suggest the following to
> narrow it down:
>
> 1) Reinstall and see if it goes away.  (Unfortunately, this happens
> far too often on Windows).
>
> 2) run GDB from a DOS prompt (gdb myprogram.exe)
> and see if it exhibits the same behavior.
>
> If so, then you've isolated the problem to be outside the editor.  The
>
> GNAT chat list may be a good source of expert advice.  Email
> chat-request@gnat.com to join.
>
> If not, then I suppose it becomes my problem.  Email me at
> carlislem@acm.org
> Please include a copy of the smallest program that behaves poorly.
>
> --Martin
>
> In article <36E81651.5B91E3D3@netspace.net.au>,
> Jackie & Barry Schiff  <schiff@netspace.net.au> wrote:
> >I am using it under NT 4.0, and so far am using the AdaGIDE editor
> >environment installed with it (used to use EMACS and maybe will
> switch
> >again but just giving this a try).  Anyhow I have a program with
> text_io
> >input/output. When I go to run it under the debugger, which I do by
> >hitting the debug button inside of AdaGIDE, the output seems to get
> >correctly redirected to an MSDOS command window but it appears that
> the
> >input does not. Thus the program bombs once it gets to an input
> >statement (eg. Text_io.Get_Line).  Surely I must be doing something
> >wrong I just have not dug it out yet. If anybody knows the answer I
> >would surely appreciate it.
>
> --
> Martin C. Carlisle, Asst Prof of Computer Science, US Air Force
> Academy
> mcc@cs.usafa.af.mil, http://www.usafa.af.mil/dfcs/bios/carlisle.html
> DISCLAIMER:  This content in no way reflects the opinions, standards
> or
> policy of the US Air Force Academy or the United States Government.







^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~1999-03-13  0:00 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1999-03-11  0:00 GDB w/GNAT 3.11p w/NT4.0 Question Jackie & Barry Schiff
1999-03-12  0:00 ` Martin C. Carlisle
1999-03-12  0:00   ` Steve Doiel
1999-03-13  0:00     ` Jackie & Barry Schiff
1999-03-13  0:00       ` Sune Falck
1999-03-13  0:00   ` Jackie & Barry Schiff
1999-03-13  0:00     ` David C. Hoos, Sr.

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox