gdb errors with b17.1

R. Britt Freund
Fri Apr 18 11:52:00 GMT 1997

Thanks in advance for your help...

I am trying to get the Cygnus b17.1 all.tar.gz distribution to work
correctly on Windows NT Workstation 4.0 with service pack #2.  I am a
professor of OR at the University of Texas at Austin and I would dearly
like to use the GNU compiler to write some optimization programs for my
research.  I am a decent coder (not great) but I am not an expert at the
intricacies of compilers.  I simply use C++ to solve some relatively
specific optimization problems.  I believe I have installed the
distribution correctly (ie. relatively complex programs are compiling fine)
but I keep on running into problems using the GNU gdb debugger.  To ensure
that some "strangeness" to my coding isn't the problem, I have written a
simple hello, world program, compiled it with the debugging options on, and
then attempted to debug it.  A transcript follows:

********** a very simple program **********
/Temp [21] cat hello.cpp
// hello.cpp  (-*- C++ -*-)

#include <iostream.h>

  cout << "Hello, world!\n";

********** that compiles without complaint **********
/Temp [22] gcc -o hello hello.cpp -lstdc++ -g

********** but doesn't seem to like gdb **********
/Temp [23] gdb hello.exe
GNU gdb 4.16.1
Copyright 1996 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you
welcome to change it and/or distribute copies of it under certain
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for details.
This GDB was configured as "i386-cygwin32"...
(gdb) list
1       // hello.cpp  (-*- C++ -*-)
3       #include <iostream.h>
5       main()
6       {
7         cout << "Hello, world!\n";
8       }
(gdb) b 7
Breakpoint 1 at 0x40102c: file hello.cpp, line 7.
(gdb) run
Starting program: /Temp/hello.exe

[failed reading symbols from DLL]
"/Mount/C/WINNT/system32/kernel32.dll": error reading line numbers

[failed reading symbols from DLL]
"/Mount/C/WINNT/system32/advapi32.dll": error reading line numbers


[failed reading symbols from DLL]
"/Mount/C/WINNT/System32/WS2_32.dll": error reading line numbers


[failed reading symbols from DLL]
"/Mount/C/WINNT/System32/WS2HELP.dll": error reading line numbers


Breakpoint 1, main () at hello.cpp:7
7         cout << "Hello, world!\n";

These DLL read/line-number errors crop up under every condition I can try
(ie., bash, emacs lisp file) and I don't know enough to track
down the problem.  I believe I have installed everything correctly.  My
system drive is C: (ie. C:\WINNT) and all of my GNU stuff in on drive E:
(ie. E:\Cygnus, E:\GStools, E:\Emacs,...).  I also believe I have set the
environmental variables correctly:


E:\Bin\sh.exe does exist, and I believe I have mounted things ok:

/Temp [24] mount
Device           Directory           Type        Flags
\\.\tape1:       /dev/st1            native      no-mixed,text!=binary
\\.\tape0:       /dev/st0            native      no-mixed,text!=binary
\\.\b:           /dev/fd1            native      no-mixed,text!=binary
\\.\a:           /dev/fd0            native      no-mixed,text!=binary
d:               /Mount/D            native      no-mixed,text!=binary
c:               /Mount/C            native      no-mixed,text!=binary
e:               /                   native      no-mixed,text!=binary

I am at a complete loss as to where to go from here....  The last thing I
want to do is purchase a Microsoft compiler, but I may be forced to since I
can't spend much more time on this...  Do you have any suggestions at all? 
It seems like this is a simple problem and that I am simply screwing up
somewhere...  Please help if you can.

Thanks again,

For help on using this list (especially unsubscribing), send a message to
"" with one line of text: "help".

More information about the Cygwin mailing list