This is an automated email from the ASF dual-hosted git repository. acassis pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/nuttx.git
commit 365699efcbb0bcfd15012626831e6fb448a30107 Author: Marco Casaroli <[email protected]> AuthorDate: Fri Nov 13 14:09:31 2026 +0100 tools/Unix.mk: Update .version once per make invocation. Each parse of the top-level Makefile ran tools/version.sh, which starts several git commands. Sub-makes of the top-level Makefile (for example the clean_context and apps_preconfig steps of olddefconfig) parsed it again and ran it again for the same git state. Run it once and export NUTTX_VERSION_UPDATED, so sub-makes skip it. Assisted-by: Claude Code:claude-opus-5-5 Signed-off-by: Marco Casaroli <[email protected]> --- tools/Unix.mk | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/tools/Unix.mk b/tools/Unix.mk index 46823a0008f..2d886a037da 100644 --- a/tools/Unix.mk +++ b/tools/Unix.mk @@ -55,9 +55,14 @@ else # Generate .version.tmp every time from GIT history # Only update .version if the contents of version.tmp actually changes # Note: this is executed before any rule is run +# Do it once per make invocation; sub-makes get NUTTX_VERSION_UPDATED from +# the environment. +ifeq ($(origin NUTTX_VERSION_UPDATED),undefined) $(shell tools/version.sh $(VERSION_ARG) .version.tmp > /dev/null) $(shell $(call TESTANDREPLACEFILE, .version.tmp, .version)) +export NUTTX_VERSION_UPDATED := y +endif endif # Process architecture specific directories
