Skip to content

Conversation

@valeriosetti
Copy link
Contributor

Currently stderr is printed only if dtc encounters warnings, but it's not printed in case of errors. However this information can be useful to quickly identify and resolve the problem.

@zephyrbot zephyrbot added area: Build System size: XS A PR changing only a single line of code labels Mar 18, 2025
@tejlmand
Copy link
Contributor

Similar proposal was opened a while back in #79236 but seems to have gone stale.

Please take a look at the comment history regarding cleanup and use of COMMAND_ERROR_IS_FATAL alternative the more complete zephyr_execute_process() wrapper until https://gitlab.kitware.com/cmake/cmake/-/issues/24815 has been fixed.

See also final comment here: #79236 (comment)

Currently stderr is printed only if dtc encounters warnings, but it's
not printed in case of errors. However this information can be useful
to quickly identify and resolve the problem.

To solve this let's add "COMMAND_ERROR_IS_FATAL ANY" to execute_process()
so that CMake will fail in case of errors and a proper message will be
printed on the output.

Signed-off-by: Valerio Setti <vsetti@baylibre.com>
@valeriosetti valeriosetti force-pushed the print-error-message-if-dtc-fails branch from a53efc7 to feb1519 Compare March 24, 2025 13:42
@valeriosetti
Copy link
Contributor Author

Similar proposal was opened a while back in #79236 but seems to have gone stale.

Please take a look at the comment history regarding cleanup and use of COMMAND_ERROR_IS_FATAL alternative the more complete zephyr_execute_process() wrapper until https://gitlab.kitware.com/cmake/cmake/-/issues/24815 has been fixed.

See also final comment here: #79236 (comment)

FWIW I updated my PR following the suggestions on #87303, in particular the last one. If #87303 is resumed by its author feel free to close this one at any time ;)

@tejlmand
Copy link
Contributor

FWIW I updated my PR following the suggestions on #87303,

@valeriosetti PR #87303 is this PR (your PR).
Guess you mean #79236 😉

@kartben kartben merged commit 13270a4 into zephyrproject-rtos:main Mar 24, 2025
25 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area: Build System size: XS A PR changing only a single line of code

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants