You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@nuttx.apache.org by xi...@apache.org on 2023/12/06 16:29:07 UTC

(nuttx-apps) 01/05: tools: Emit map file for wasm module

This is an automated email from the ASF dual-hosted git repository.

xiaoxiang pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/nuttx-apps.git

commit 3129b7a4659dfd2c8e82b9b3ff596a1e9d6976d2
Author: Huang Qi <hu...@xiaomi.com>
AuthorDate: Fri Aug 18 16:48:37 2023 +0800

    tools: Emit map file for wasm module
    
    Emit map file like NuttX's `System.map` for more
    debug information.
    
    Signed-off-by: Huang Qi <hu...@xiaomi.com>
---
 tools/Wasm.mk | 1 +
 1 file changed, 1 insertion(+)

diff --git a/tools/Wasm.mk b/tools/Wasm.mk
index e112dc01e..c571f881e 100644
--- a/tools/Wasm.mk
+++ b/tools/Wasm.mk
@@ -87,6 +87,7 @@ define LINK_WASM
 	    $(eval STACKSIZE=$(shell echo $(notdir $(bin)) | cut -d'#' -f3)) \
 	    $(eval PROGNAME=$(shell echo $(notdir $(bin)) | cut -d'#' -f1)) \
 	    $(eval RETVAL=$(shell $(WCC) $(bin) $(WBIN) $(WCFLAGS) $(WLDFLAGS) $(COMPILER_RT_LIB) \
+	        -Wl,--Map=$(APPDIR)$(DELIM)wasm$(DELIM)$(PROGNAME).map \
 	        -o $(APPDIR)$(DELIM)wasm$(DELIM)$(PROGNAME).wasm || echo 1;)) \
 	    $(if $(RETVAL), \
 	        $(error wasm build failed for $(PROGNAME).wasm) \