I stopped at section "Making GDB useful". I want to add fastfat.sys to debug:
- Code: Select all
(dbg)add-symbol-file E:/ros/trunk/reactos/output-i386/drivers/filesystems/fastfat/fastfat.nostrip.sys
The address where E:/ros/trunk/reactos/output-i386/drivers/filesystems/fastfat/fastfat.nostrip.sys has been loaded is missing
1. ntoskrnl/ldr/loader.c was removed from trunk in r25886
"Remove /ldr ntoskrnl directory, since this module is finally gone."
2. http://www.reactos.org/wiki/Rossym.gdb doesn't help:
- Code: Select all
(dbg)source E:/ros/trunk/reactos/lib/rossym/rossym.gdb
(dbg)load-all-modules
No symbol "KDB_MODULE_INFO" in current context.
PS my previous steps:
1.Remove obj-i386, output-i386, makefile-i386.auto.
2.Copy config.template.rbuild to config.rbuild and set:
<property name="GDB" value="1" />
3.make ROS_BUILDNOSTRIP=yes bootcd
4.Start qemu with command line option "-gdb tcp::5022":
qemu -L bios -m 1024 -cdrom ..\trunk\reactos\ReactOS.iso -boot d -hda ..\hdd\rgdb-5g.vmdk -serial file:log\rgdb-5g.txt -gdb tcp::5022
5.Install ros.
6.Add /DEBUGPORT=GDB to [ReactOS_Debug] options in freeldr.ini.
7.Reboot and choose "ReactOS (Debug)". Now i see "Waiting for GDB to attach"
8.Start gdb without parameters.
- Code: Select all
(dbg)directory E:/ros/trunk/reactos
Source directories searched: E:/ros/trunk/reactos;$cdir;$cwd
(dbg)symbol-file E:/ros/trunk/reactos/output-i386/ntoskrnl/ntoskrnl.nostrip.exe
BFD: E:/ros/trunk/reactos/output-i386/ntoskrnl/ntoskrnl.nostrip.exe: Warning: Ignoring section flag IMAGE_SCN_MEM_NOT_PAGED in section .text
BFD: E:/ros/trunk/reactos/output-i386/ntoskrnl/ntoskrnl.nostrip.exe: Warning: Ignoring section flag IMAGE_SCN_MEM_NOT_PAGED in section .data
BFD: E:/ros/trunk/reactos/output-i386/ntoskrnl/ntoskrnl.nostrip.exe: Warning: Ignoring section flag IMAGE_SCN_MEM_NOT_PAGED in section .idata
BFD: E:/ros/trunk/reactos/output-i386/ntoskrnl/ntoskrnl.nostrip.exe: Warning: Ignoring section flag IMAGE_SCN_MEM_NOT_PAGED in section .bss
Reading symbols from E:/ros/trunk/reactos/output-i386/ntoskrnl/ntoskrnl.nostrip.exe...done.
(dbg)set remotebaud 115200
(dbg)target remote localhost:5022
Remote debugging using localhost:5022
0x8087b7a9 in KdbpTryGetCharKeyboard (ScanCode=0x8095db90, Retry=0)
at ntoskrnl/kdbg/kdb_keyboard.c:115
115 while (kbd_read_status() & KBD_STAT_OBF)
(dbg)add-symbol-file E:/ros/trunk/reactos/output-i386/drivers/filesystems/fastfat/fastfat.nostrip.sys
The address where E:/ros/trunk/reactos/output-i386/drivers/filesystems/fastfat/fastfat.nostrip.sys has been loaded is missing
PSS "-gdb tcp::5022" option taken from this manual: http://dc0d32.blogspot.com/2010/03/debu ... d-gdb.html
Host - winxp sp3
Qemu-0.13.0-rc0-windows-Lite.zip: http://lassauge.free.fr/qemu
gdb-7.2-1-mingw32-bin.tar.lzma: http://sourceforge.net/projects/mingw/f ... DB/GDB-7.2