[U-Boot-Users] [PATCH] - request to change default debug assembly flags from stabs to dwarf2

Wessel, Jason jason.wessel at windriver.com
Thu Sep 1 16:41:30 CEST 2005


The default for the C portion of the u-boot compile is set to dwarf-2
because the -g option for gcc 3.x defaults to dwarf-2, but the assembly
portion is not.  

If possible, I would like to see the debug formats made consistent so as
to allow the debugger to more reliably step through assembly source with
gdb and other debuggers with the more modern dwarf2 debug format.  I
have tested this change with gcc 3.4.3 on Arm9, MPC82xx, PPC85xx, PPC
40x and PPC 44x.  I also tested with ELDK 3.1.1 on all the PPC archs and
it works quite well.

Signed-off-by: Jason Wessel <jason.wessel at windriver.com>

diff --git a/config.mk b/config.mk
--- a/config.mk
+++ b/config.mk
@@ -133,7 +133,7 @@ CFLAGS := $(CPPFLAGS) -Wall -Wno-trigrap
 endif
 endif
 
-AFLAGS_DEBUG := -Wa,-gstabs
+AFLAGS_DEBUG := -Wa,-gdwarf2
 AFLAGS := $(AFLAGS_DEBUG) -D__ASSEMBLY__ $(CPPFLAGS)
 
 LDFLAGS += -Bstatic -T $(LDSCRIPT) -Ttext $(TEXT_BASE)
$(PLATFORM_LDFLAGS)




More information about the U-Boot mailing list