tmedicci commented on code in PR #15304: URL: https://github.com/apache/nuttx/pull/15304#discussion_r1900837806
########## tools/Unix.mk: ########## @@ -618,6 +619,40 @@ bootloader: clean_bootloader: $(Q) $(MAKE) -C $(ARCH_SRC) clean_bootloader +checkpython3: + @if [ -z "$$(which python3)" ]; then \ + echo "ERROR: python3 not found in PATH"; \ + echo " Please install python3 or fix the PATH"; \ + exit 1; \ + fi + +# debug_info target flags to get diagnostic info without building nxdiag application + +SYSINFO_PARSE_FLAGS = "$(realpath $(TOPDIR))" +SYSINFO_PARSE_FLAGS += "-fsysinfo.h" + +SYSINFO_FLAGS = "-c" +SYSINFO_FLAGS += "-p" +SYSINFO_FLAGS += -f \""$(shell echo '$(CFLAGS)' | sed 's/"/\\\\\\"/g')"\" +SYSINFO_FLAGS += \""$(shell echo '$(CXXFLAGS)' | sed 's/"/\\\\\\"/g')"\" +SYSINFO_FLAGS += \""$(shell echo '$(LDFLAGS)' | sed 's/"/\\\\\\"/g')"\" + +ifneq ($(findstring esp,$(CONFIG_ARCH_CHIP)),) +ARCH_ESP_HALDIR = $(TOPDIR)$(DELIM)arch$(DELIM)$(CONFIG_ARCH)$(DELIM)src$(DELIM)chip$(DELIM)esp-hal-3rdparty Review Comment: > so, should we just keep the flag required by parse_sysinfo.py, but move the host_sysinfo.py's options to apps/system/nxdiag. BTW, host_sysinfo.py should be still keep in apps/system/nxdiag too. I prefer to keep it on `tools/host_sysinfo.py`: it's an application that read general system information (and can generate both the header file and the verbose info), so I see no reason to move it to `apps/system/nxdiag` since it's used for `make debug_info`. I'd let only the necessary scripts to embed this information on firmware on `apps/system/nxdiag` and make the most important part of `nxdiag` as a NuttX's tool. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org