I followed the steps on how to load and debug application on Cortex-M.
On my Ubuntu 22.04 VM I downloaded exactly the same toolchain gcc-arm-11.2-2022.02-x86_64-arm-none-eabi.tar.xz but the problem is that ./arm-none-eabi-gdb --version
returns ./arm-none-eabi-gdb: error while loading shared libraries: libncursesw.so.5: cannot open shared object file: No such file or directory
Following that topic you can find the “solution”
Thank you for pointing out the issues around python incompatibility.
For Ubuntu 20.04, Python 3.6 could be installed through the PPA route as mentioned in 5842 – arm-none-eabi-gdb 11.2 doesn't start on Ubuntu 20.04 host, however, this might not work for Ubuntu 22.04.
For the next release, we are working on updating the version of Python that is used in GDB, so that there will be better compatibility for the newer linux distros. Following on from that, we do want to take a look at other approaches, such as the two binary approach or static linking approach, to improve on the compatibility.
Yes, it was me. This issue is related to a python library unavailable on Ubuntu 22.04. So instead we need to compile this library ourselves and point out to GDB where it’s located. The steps that I’ve done are described in this article: Cortex-M JTAG Debugging | Toradex Developer Center, on this part:
Apparently, the ARM GDB developers didn’t update their python libraries yet, so instead, we need to do this workaround. Can you please check if that solves your issue?
I followed the exact same steps and it compiled successfully. I’m not sure where this error is coming from, but regardless of this error, are you able to run the GDB with the LD_LIBRARY_PATH now?