하지만 위의 명령어는 현재 설치하려고 하면 찾을 수 없는 패키지이다. 그냥 gdb-multiarch 를 설치하면 된다!
QEMU 실행
tanagy@DESKTOP-3IQ83O6:/mnt/c/Folder/study/EmbededOS/chapter_3/boot$ qemu-system-arm -M realview-pb-a8 -kernel navilos.axf -S -gdb tcp::1234,ipv4
shared memfd open() failed: Function not implemented
pulseaudio: pa_context_connect() failed
pulseaudio: Reason: Connection refused
pulseaudio: Failed to initialize PA contextaudio: Could not init `pa' audio driver
...
gdb 실행
tanagy@DESKTOP-3IQ83O6:/mnt/c/Folder/study/EmbededOS/chapter_3/boot$ gdb-multiarch
GNU gdb (Ubuntu 8.1-0ubuntu3.2) 8.1.0.20180409-git
Copyright (C) 2018 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law. Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64-linux-gnu".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>.
Find the GDB manual and other documentation resources online at:
<http://www.gnu.org/software/gdb/documentation/>.
For help, type "help".
Type "apropos word" to search for commands related to "word".
(gdb) target remote:1234
Remote debugging using :1234
warning: No executable has been specified and target does not support
determining executable automatically. Try using the "file" command.
0x00000000 in ?? ()
(gdb) x/4x 0
0x0: 0xe1a00001 0x00000000 0x00000000 0x00000000
(gdb)