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

[nrf fromtree] cmake: reports: Add support for JSON prefix #2505

Merged
merged 1 commit into from
Feb 17, 2025
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
34 changes: 18 additions & 16 deletions cmake/reports/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ foreach(report ram_report rom_report footprint)
)
endforeach()

if (CONFIG_BUILD_WITH_TFM)
if(CONFIG_BUILD_WITH_TFM)
foreach(report ram_report rom_report footprint)
add_custom_target(
tfm_${report}
Expand All @@ -40,6 +40,7 @@ if (CONFIG_BUILD_WITH_TFM)
-o ${CMAKE_BINARY_DIR}
${workspace_arg}
-d ${report_depth}
--json tfm_${report}.json
${flag_for_${report}}
DEPENDS tfm
USES_TERMINAL
Expand All @@ -48,22 +49,23 @@ if (CONFIG_BUILD_WITH_TFM)
endforeach()
endif()

if (CONFIG_TFM_BL2)
if(CONFIG_TFM_BL2)
foreach(report ram_report rom_report footprint)
add_custom_target(
bl2_${report}
${PYTHON_EXECUTABLE}
${ZEPHYR_BASE}/scripts/footprint/size_report
-k $<TARGET_PROPERTY:tfm,BL2_ELF_FILE>
-z ${ZEPHYR_BASE}
-o ${CMAKE_BINARY_DIR}
${workspace_arg}
-d ${report_depth}
${flag_for_${report}}
DEPENDS tfm
USES_TERMINAL
WORKING_DIRECTORY ${CMAKE_BINARY_DIR}
)
add_custom_target(
bl2_${report}
${PYTHON_EXECUTABLE}
${ZEPHYR_BASE}/scripts/footprint/size_report
-k $<TARGET_PROPERTY:tfm,BL2_ELF_FILE>
-z ${ZEPHYR_BASE}
-o ${CMAKE_BINARY_DIR}
${workspace_arg}
-d ${report_depth}
--json bl2_${report}.json
${flag_for_${report}}
DEPENDS tfm
USES_TERMINAL
WORKING_DIRECTORY ${CMAKE_BINARY_DIR}
)
endforeach()
endif()

Expand Down
Loading