Memory Report generation Python/DWARF error

Hi,

We are using nRF Connect SDK Toolchain 2.4.2. We want to make rom_reports and footprints but we get the following error:

[09:04:53] Command failed: west build -d APP_PATH/build -t footprint
Traceback (most recent call last):
  File "PROJECT_PATH/zephyr/scripts/footprint/size_report", line 803, in <module>
    main()
  File "PROJECT_PATH/zephyr/scripts/footprint/size_report", line 779, in main
    do_simple_name_matching(elf, symbol_dict, processed)
  File "PROJECT_PATH/zephyr/scripts/footprint/size_report", line 268, in do_simple_name_matching
    for compile_unit in dwarfinfo.iter_CUs():
  File "HOME_PATH/ncs/toolchains/1f9b40e71a/usr/local/lib/python3.8/site-packages/elftools/dwarf/dwarfinfo.py", line 353, in _parse_CUs_iter
    cu = self._cached_CU_at_offset(offset)
  File "HOME_PATH/ncs/toolchains/1f9b40e71a/usr/local/lib/python3.8/site-packages/elftools/dwarf/dwarfinfo.py", line 383, in _cached_CU_at_offset
    cu = self._parse_CU_at_offset(offset)
  File "HOME_PATH/ncs/toolchains/1f9b40e71a/usr/local/lib/python3.8/site-packages/elftools/dwarf/dwarfinfo.py", line 424, in _parse_CU_at_offset
    dwarf_assert(
  File "HOME_PATH/ncs/toolchains/1f9b40e71a/usr/local/lib/python3.8/site-packages/elftools/common/utils.py", line 83, in dwarf_assert
    _assert_with_exception(cond, msg, DWARFError)
  File "HOME_PATH/ncs/toolchains/1f9b40e71a/usr/local/lib/python3.8/site-packages/elftools/common/utils.py", line 114, in _assert_with_exception
    raise exception_type(msg)
elftools.common.exceptions.DWARFError: Expected supported DWARF version. Got '5'
FATAL ERROR: command exited with status 1: HOME_PATH/ncs/toolchains/1f9b40e71a/usr/local/bin/cmake --build APP_PATH/build --target footprint

This happens in the VSCode nRF Connect extension as well as in the terminal. The 2.4.2 Toolchain is installed with the extension. We have python 3.8.2 as recommended by the docs and installed nrf/scripts/requirements.txt.

Can anyone help us with this error?

Related