diff --git a/tools/projmgr/include/ProjMgrRunDebug.h b/tools/projmgr/include/ProjMgrRunDebug.h index 4013bd89d..3e7c9f1bd 100644 --- a/tools/projmgr/include/ProjMgrRunDebug.h +++ b/tools/projmgr/include/ProjMgrRunDebug.h @@ -103,6 +103,7 @@ struct FilesType { std::string load; std::string offset; std::string pname; + std::string project; }; /** diff --git a/tools/projmgr/schemas/common.schema.json b/tools/projmgr/schemas/common.schema.json index 82c4f9261..47a906c73 100644 --- a/tools/projmgr/schemas/common.schema.json +++ b/tools/projmgr/schemas/common.schema.json @@ -2187,6 +2187,7 @@ "info": { "type": "string", "description": "Brief description of the file." }, "load": { "$ref": "#/definitions/TargetSetLoadType" }, "load-offset": { "type": "number", "description": "Offset applied in *.csolution.yml when loading the image file." }, + "project": { "type": "string", "description": "Project context that generated the output artifact." }, "pname": { "type": "string", "description": "Image belongs to processor in a multi-core system." } }, "additionalProperties": false, diff --git a/tools/projmgr/src/ProjMgrCbuildRun.cpp b/tools/projmgr/src/ProjMgrCbuildRun.cpp index 0ff5c9c13..5b5edcd0d 100644 --- a/tools/projmgr/src/ProjMgrCbuildRun.cpp +++ b/tools/projmgr/src/ProjMgrCbuildRun.cpp @@ -121,6 +121,7 @@ void ProjMgrCbuildRun::SetFilesNode(YAML::Node node, const std::vector& contexts, cons item.load = item.type == RteConstants::OUTPUT_TYPE_ELF ? LOAD_IMAGE_SYMBOLS : item.type == RteConstants::OUTPUT_TYPE_LIB ? LOAD_NONE : LOAD_IMAGE; } - m_runDebug.outputs.push_back({ item.image, item.info, item.type, item.load, item.offset, item.pname }); + m_runDebug.outputs.push_back({ item.image, item.info, item.type, item.load, item.offset, item.pname, RteUtils::EMPTY_STRING }); } } @@ -726,6 +726,7 @@ void ProjMgrRunDebug::AddGeneratedImage(const ContextItem* context, const string image.type = type; image.load = load; image.pname = context->deviceItem.pname; + image.project = context->cproject->name; image.offset = type == RteConstants::OUTPUT_TYPE_BIN ? context->loadOffset : RteUtils::EMPTY_STRING; m_runDebug.outputs.push_back(image); } diff --git a/tools/projmgr/test/data/TestRunDebug/ref/custom+TestHW.cbuild-run.yml b/tools/projmgr/test/data/TestRunDebug/ref/custom+TestHW.cbuild-run.yml index 202857136..b7d18059a 100644 --- a/tools/projmgr/test/data/TestRunDebug/ref/custom+TestHW.cbuild-run.yml +++ b/tools/projmgr/test/data/TestRunDebug/ref/custom+TestHW.cbuild-run.yml @@ -11,6 +11,7 @@ cbuild-run: - file: custom/TestHW/custom.axf info: generate by custom+TestHW type: elf + project: custom load: image+symbols system-resources: memory: diff --git a/tools/projmgr/test/data/TestRunDebug/ref/run-debug+TestHW.cbuild-run.yml b/tools/projmgr/test/data/TestRunDebug/ref/run-debug+TestHW.cbuild-run.yml index d0a472b62..3920a6b98 100644 --- a/tools/projmgr/test/data/TestRunDebug/ref/run-debug+TestHW.cbuild-run.yml +++ b/tools/projmgr/test/data/TestRunDebug/ref/run-debug+TestHW.cbuild-run.yml @@ -14,14 +14,17 @@ cbuild-run: - file: run-debug/TestHW/run-debug.axf info: generate by run-debug+TestHW type: elf + project: run-debug load: none - file: run-debug/TestHW/run-debug.hex info: generate by run-debug+TestHW type: hex + project: run-debug load: none - file: run-debug/TestHW/run-debug.bin info: generate by run-debug+TestHW type: bin + project: run-debug load: image load-offset: 0x0000A000 - file: ../../data/TestRunDebug/customImage.bin diff --git a/tools/projmgr/test/data/TestRunDebug/ref/run-debug+TestHW2.cbuild-run.yml b/tools/projmgr/test/data/TestRunDebug/ref/run-debug+TestHW2.cbuild-run.yml index ab9eb179d..08af1029e 100644 --- a/tools/projmgr/test/data/TestRunDebug/ref/run-debug+TestHW2.cbuild-run.yml +++ b/tools/projmgr/test/data/TestRunDebug/ref/run-debug+TestHW2.cbuild-run.yml @@ -14,14 +14,17 @@ cbuild-run: - file: run-debug/TestHW2/run-debug.axf info: generate by run-debug+TestHW2 type: elf + project: run-debug load: symbols - file: run-debug/TestHW2/run-debug.hex info: generate by run-debug+TestHW2 type: hex + project: run-debug load: image - file: run-debug/TestHW2/run-debug.bin info: generate by run-debug+TestHW2 type: bin + project: run-debug load: none - file: ../../data/TestRunDebug/customLibrary.x type: lib diff --git a/tools/projmgr/test/data/TestRunDebug/ref/run-debug+TestHW3.cbuild-run.yml b/tools/projmgr/test/data/TestRunDebug/ref/run-debug+TestHW3.cbuild-run.yml index 332ec86f1..9a174fff4 100644 --- a/tools/projmgr/test/data/TestRunDebug/ref/run-debug+TestHW3.cbuild-run.yml +++ b/tools/projmgr/test/data/TestRunDebug/ref/run-debug+TestHW3.cbuild-run.yml @@ -11,21 +11,25 @@ cbuild-run: - file: core0/TestHW3/core0.axf info: generate by core0+TestHW3 type: elf + project: core0 load: none pname: cm0_core0 - file: core1/TestHW3/core1.axf info: generate by core1+TestHW3 type: elf + project: core1 load: symbols pname: cm0_core1 - file: core1/TestHW3/core1.hex info: generate by core1+TestHW3 type: hex + project: core1 load: image pname: cm0_core1 - file: core1/TestHW3/core1.bin info: generate by core1+TestHW3 type: bin + project: core1 load: none pname: cm0_core1 system-resources: diff --git a/tools/projmgr/test/data/WestSupport/ref/solution+CM0.cbuild-run.yml b/tools/projmgr/test/data/WestSupport/ref/solution+CM0.cbuild-run.yml index ecf2e553e..15899fa27 100644 --- a/tools/projmgr/test/data/WestSupport/ref/solution+CM0.cbuild-run.yml +++ b/tools/projmgr/test/data/WestSupport/ref/solution+CM0.cbuild-run.yml @@ -14,21 +14,25 @@ cbuild-run: - file: core0/CM0/Debug/zephyr/zephyr.elf info: generate by core0.Debug+CM0 type: elf + project: core0 load: symbols pname: cm0_core0 - file: core0/CM0/Debug/zephyr/zephyr.hex info: generate by core0.Debug+CM0 type: hex + project: core0 load: image pname: cm0_core0 - file: core1/CM0/Debug/zephyr/zephyr.elf info: generate by core1.Debug+CM0 type: elf + project: core1 load: symbols pname: cm0_core1 - file: core1/CM0/Debug/zephyr/zephyr.hex info: generate by core1.Debug+CM0 type: hex + project: core1 load: image pname: cm0_core1 system-resources: