gdb with rdgb support

Andrew Sinclair andrews at
Thu Jul 31 05:31:08 UTC 2003

Hi there,

I have encountered the same issue with gdb 5.2. Has anyone resolved this 

Instead I am using an older version at the moment, installed from file 
i386-RTEMS-gdb-5.0-7.i386.rpm. (Can be found at  

It appears to work, although I am having problems loading debug symbols. I 
have been running rdgb on the http network demo using the standard makefile 
included in network-demos-4.6.0pre4.tar.bz2. I have added the following 
lines after rtems_bsdnet_initialize_network () inside init.c:


I have been unable to identify where the debug symbols have been stripped 
off from the executable. Does anyone know how to keep these symbols? I have 
tried using the http.obj file produced in the build, however I cant get 
links to source files correctly.

This is what I get when I remote debug to a machine at

[andrews at store http]$ i386-RTEMS-gdb
GNU gdb 5.0
Copyright 2000 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 "--host=i686-pc-linux-gnu --target=i386-RTEMS".
(gdb) setrpcmode sun
(gdb) setdaemontype rdbg
(gdb) target rtems
Attaching remote machine across net...
Connected to
Now the "run" command will start a remote process.
(gdb) file o-optimize/http.obj
Reading symbols from o-optimize/http.obj...done.
(gdb) attach 1
Attaching program: 
 pid 1
[Switching to process 167837703]
enterRdbg () at {standard input}:27
27      {standard input}: No such file or directory.

Does anyone know what I am doing wrong?

Kind Regards

Andrew Sinclair

-----Original Message-----
From:	Per Dalgas Jakobsen [SMTP:pdj at]
Sent:	Thursday, 24 July 2003 10:02 PM
To:	Rtems-Users (E-mail)
Subject:	gdb with rdgb support


I have some trouble compiling gdb with rdgb support.
Configuring with:
.../configure --verbose --target=i386-rtems --prefix=/usr/local/rtems
succeeds, but when entering:
$ gdb
.. yada yada ...
This GDB was configured as "--host=i686-pc-cygwin --target=i386-rtems"...
(gdb) setrpcmode sun
(gdb) setdaemontype rdbg
(gdb) target rtems target-name
fails undefined commands (and undefined target command).

I searched the archives a bit and found this thread:  

Seemed exactly like my problem, but when attempting to configure with 
--target=i386-RTEMS i get "Invalid configuration `i386-RTEMS': system 
`RTEMS' not recognized".

I have patched the gdb-5.2 source with:
gdb-5.2-rtems-cg-20030211.diff 	# not sure if this one is needed.
All successful.

Any suggestions?

While we are at the remote gdb-stuff: What is the prefered way to start an 
Ada program on the remote and make it wait for the gdb-client before 

Best regards

PS: Sorry for that #$")!/&% footer, IT is still working on it 
(idle-priority i guess).

The information contained in this e-mail is privileged and confidential 
information intended only for the use of the individual or entity named 
above. If the reader of this message is not the intended recipient, you are 
hereby notified that any dissemination, distribution or copying of this 
communication is strictly prohibited. If you have received this 
communication in error, please immediately notify us by e-mail or 
Thank you in advance.

More information about the users mailing list