![]() Line 14 CFLAGS =-Wall -O2 -fomit-frame-pointer,Ĭhange to CFLAGS =-Wall -O -g linux-0.11-060618-gcc4]# make Line 87 #elif syntax error, change to linux-0.11-060618-gcc4]# gedit Makefile This is the normal version we can find closest to the current environment: Compile Linux 0.11 kernel with debugging informationĭownload a kernel version that can be compiled and run normally under gcc4.0 from the link below. +++++++++++linux Read the linux 0.11 kernel source code belowĢ. If you modify 0.11 For the kernel source code, repeat 1 to 5 to verify whether it meets your functional requirements. linux-gdb-rh9]# bochs -q -f bochsrc-fd1-gdb.bxrcĦ. Copy the modified Image and System.map to linux-gdb-rh9/linuxĥ. Decompress and compile the kernel, generate Image, and linux]# vim Image -bĬhange 1d02 55aa to 0000 55aa//floppy disk file systemĤ. To the first line Remarks, namely: # gdbstub: enabled=1, port=1234, text_base=0, data_base=0, bss_base=0ģ. Symbol-file tools/system (load symbol table information)Īctually the code is executed on the remote host (bochs), gdb running on the local host, It only needs the symbol table information to be OK. Target remote localhost:1234 (set remote host) You can use the following series of commands to execute, which may be easier to understand. The Image file is a kernel image file and does not contain symbol information. The main purpose of the gdb tools/system command is to load the symbol table, and the symbol information only exists in the system object file. ![]() Press enter to load the corresponding data into the memory and it will pass. The message is:Īnswer: The page fault interrupt is a normal process. Now all the steps are executed correctly, gdb can connect with bochs, but when linux0.11 is running, a page fault occurs during the startup process. The solution, in the (gdb) command line, keep pressing the ENTER key. Will 1d02 55aa to hard disk file system 0103 55aa// The 1d02 55aa to 0000 55aa//disk file system Please refer to " vim+xxd= powerful hexadecimal editor bxrc~ Image-org README runīochsrc~ bootimage-0.11-20040305 linux linux-gdb-rh9]# bochs -q -f bochsrc-fd1-gdb.bxrc The Note: Bochs emulator window switching and other windows, the mouse must not use ALT + TAB key combination to switchįirst terminal bogon the root-GDB-Linux RH9] # pwdīochsout.txt bochsrc-fd1-gdb.bxrc bootroot-0.11 parport.out rootimage-0.11-for-origīochsrc bochsrc-fd1-gdb.
0 Comments
Leave a Reply. |