GDB/Mingw make problem

Gerrit van Niekerk gerritvn@gpvno.co.za
Tue Jan 15 07:33:00 GMT 2008


On 14 Jan 2008 at 16:12, DJ Delorie wrote:

> 
> > ?? I'd expect --target=djgpp do that automatically (it's a
> > cross-compilation, right?)
> 
> It's the difference between a cygwin-x-djgpp cross compiler and a
> mingw-x-djgpp cross compiler.  If --host is mingw, you're actually
> doing a canadian (although configure doesn't realize it, so it's not
> the traditional build/host/target canadian), so you need to ensure
> that CC is set right.
> 
> Otherwise, in the example given, you're trying to build cygwin
> programs using mingw headers, or something like that.  Subtle bugs
> ensue.

The idea is to get a cross debugger to debug a remote DJGPP system using a MinGw GDB and a TCP/IP 
connection. The stock MinGW GDB works fine, except that it expects a PE target and fails to do 
address to symbol conversions correctly. The other way round works fine and one can do debugging, 
but a backtrace gives completely wrong results.

I have managed to move on from the last reported problem which was caused by configure/make 
specifying the wrong include path for libintl.h. I solved that one by copying libintl.h to the 
specified directory. Now I am having a problem with conflicts between winsock2.h and unistd.h both 
declaring Winsock functions like gethostname(). It seems that the makefile uses Cygwin headers 
rather than MinGW headers.






More information about the Gdb mailing list