This is the mail archive of the
gdb@sources.redhat.com
mailing list for the GDB project.
remote debugging over TCP/IP on x86 target
- From: "mseffar"<mseffar at actia dot fr>
- To: <gdb at sources dot redhat dot com>
- Date: Mon, 14 Apr 2003 11:33:56 +0200
- Subject: remote debugging over TCP/IP on x86 target
hello,
I'm trying to remote debug programs running on x86/windows XP target from cygwin
host using TCP/IP.But problems occured.
here's what I did:
I linked my program with i386-stub.c on host machine (I supplied exception
handling subroutine and putdebugchar and getdebugchar subroutines using winsock
API) . I put on top of my program set_debug_traps and socket settings then my
program waits for a connection from GDB.
I first start my program(hello.exe) on the target (it takes as argument port
number), it stops at waiting for a GDB incoming connection
Secondly I run GDB on the host : gdb hello.exe
then: target remote target:port_number
On the target my program resumes and terminates
On the host : gdb output is :
target remote Poste563:9888
Remote debugging using Poste563:9888
Couldn't establish connection to remote target
Remote communication error: Connection reset by peer.
It seems that GDB doesn't take control over the program.
Any help would be precious, thanks.