Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

BMDebug: DWARF error. Wrong version in compilation unit header (is 5, should be 2,3 or 4) #41

Open
OevreFlataeker opened this issue Jan 20, 2024 · 3 comments

Comments

@OevreFlataeker
Copy link

No sure, if that's the proper place to report this.
I am using bmdebug.exe from this repo's releases and try to follow some examples with the Black-Magic-Probe book.
When I try to load a Blink.ino.elf from Arduino IDE 2 with enabled debug symbold, bmdebug crashes after showing this message in the message pane:

BMDebug: DWARF error. Wrong version in compilation unit header (is 5, should be 2,3 or 4) (in module )

Is this something I need to change in the Arduino IDE or is this a matter against which version BMDebug.exe has been compiled against maybe?

@OevreFlataeker
Copy link
Author

Blink2.ino.elf.zip
Example Blink2.ino.elf.zip as a reference

@compuphase
Copy link
Owner

This message appears to come from GDB (BMDebug is a front-end for GDB, so error messages from GDB are shown in the console view).
Check that BMDebug is using the correct GDB. In the configuration section (top right of the BMDebug interface), you can set the path to the GDB to use. Generally speaking, you should use the GDB that comes with the GCC compiler that you used to build the firmware with. It looks like GCC is a fairly recent version, but that the GDB launched by BMDebug is quite old.

@OevreFlataeker
Copy link
Author

Thanks! Makes perfectly sense! Yes the ARM toolchain bundled with Arduino Studio is probably much newer than the GDB from the ARM toolchain I had on another path on my system! Will try!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants