How to build a GDB stub for x86 target.

Dmitry Kargapolov dk at gentex.ru
Thu Oct 5 06:32:28 UTC 2000


Wednesday, October 04, 2000, 8:03:06 PM, you wrote:

Lw> Dear sir,
Lw> Could you give me some help? How to build a GDB stub for x86 target.Because
Lw> I am a Newbie on RTEMS.Any help be appreciated!

Lw> Thanks!

Lw> Yours
Lw> Lichow

for example you can (in pc386 bsp):

#include <uart.h>

rtems_task InitTask(rtems_task_argument a)
{
  ...
  i386_stub_glue_init(BSP_UART_COM2);
  set_debug_traps();
  i386_stub_glue_init_breakin();
  breakpoint();
  ...
}

example of starting debuger:
i386-rtemself-gdb -b 38400 -s o-debug/test.exe -x rdbg.com

where rdbg.com can consist of:
...
target remote /dev/ttyS0
breakpoint measure.c:288
continue
...

-- 
Sincerely,
Dmitry Kargapolov, ICQ 54000305, dk at gentex.ru





More information about the users mailing list