feat(monitor): Add support for decoding output based on multiple ELF files

This commit is contained in:
Peter Dragun
2024-11-12 13:54:09 +01:00
parent bb9a2658a9
commit 28dcb9a889
3 changed files with 17 additions and 3 deletions

View File

@@ -5,6 +5,7 @@ import os
import shlex
import signal
import sys
from pathlib import Path
from typing import Any
from typing import Dict
from typing import List
@@ -170,8 +171,11 @@ def action_extensions(base_actions: Dict, project_path: str) -> Dict:
if print_filter is not None:
monitor_args += ['--print_filter', print_filter]
elf_list = [str(elf) for elf in Path(args.build_dir).rglob('*.elf')]
if elf_file:
monitor_args += [elf_file]
# prepend the main app elf file to the list; make sure it is the first one
elf_list.insert(0, elf_list.pop(elf_list.index(elf_file)))
monitor_args.extend(elf_list)
if encrypted:
monitor_args += ['--encrypted']