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.git


The following commit(s) were added to refs/heads/master by this push:
     new c164fc9b21 nuttx:generate nuttx.map file when enable debug link map.
c164fc9b21 is described below

commit c164fc9b21f55f659e07096df7f36c5d6ffcb292
Author: cuiziwei <[email protected]>
AuthorDate: Wed Oct 18 17:01:14 2023 +0800

    nuttx:generate nuttx.map file when enable debug link map.
    
    Signed-off-by: cuiziwei <[email protected]>
---
 boards/sim/sim/sim/scripts/Make.defs | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/boards/sim/sim/sim/scripts/Make.defs 
b/boards/sim/sim/sim/scripts/Make.defs
index 01f9e81b48..9ad0d93d97 100644
--- a/boards/sim/sim/sim/scripts/Make.defs
+++ b/boards/sim/sim/sim/scripts/Make.defs
@@ -267,6 +267,12 @@ else
   LDFLAGS += -Wl,-Ttext-segment=0x400000
 endif
 
+ifeq ($(CONFIG_DEBUG_LINK_MAP),y)
+  ifeq ($(CONFIG_HOST_MACOS),)
+    LDFLAGS += -Wl,-Map=$(TOPDIR)/nuttx.map
+  endif
+endif
+
 ifeq ($(CONFIG_SIM_M32),y)
   LDLINKFLAGS += -melf_i386
   LDFLAGS += -m32

Reply via email to