I am working on a bootloader / kernel written in an assembly and running on the qemu emulator. I can run qemu with the -s -S and debug with gdb using the remote target, but I don't have any debug symbols loaded with gdb. How can I generate a character file from my assembly?
I use nasm to create a binary image for qemu to run from my build file, but I still could not find debugging information in the image itself (I'm not sure if that even makes sense). I also found that gdb allows you to load a separate symbol file for debugging, so now my problem is how to generate the symbol file from my assembly code.
I saw suggestions to use objcopy , but I believe that it only works with elf files, not binary ones. I tried to get nasm to generate an elf, but it saves barfing due to my (necessary) org directive in the build file.
source share