This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
DWARF2_DEBUGGING_INFO on Darwin
- From: Adriaan van Os <gcc at microbizz dot nl>
- To: gcc-patches at gcc dot gnu dot org
- Date: Sat, 12 Apr 2003 13:28:02 +0200
- Subject: DWARF2_DEBUGGING_INFO on Darwin
Compiling any .c source on Darwin with gcc 3.2.2 using the -ggdb or
-gdwarf-2 switch, produces an internal compiler error in
default_no_named_section, at varasm.c:5305.
The reason being that the Darwin back-end claims to support dwarf-2
(config/darwin.h:128), but doesn't set TARGET_ASM_NAMED_SECTION.
As Darwin doesn't really support dwarf-2 debug info, I propose the
following patch:
--- gcc/config/darwin.h.orig Tue Jan 15 20:20:20 2002
+++ gcc/config/ darwin.h Sat Apr 12 11:45:49 2003
@@ -122,11 +122,11 @@
/* We use Dbx symbol format. */
#define DBX_DEBUGGING_INFO
-/* Also enable Dwarf 2 as an option. */
+/* Darwin doesn't really support Dwarf 2. */
-#define DWARF2_DEBUGGING_INFO
+#undef DWARF2_DEBUGGING_INFO
#define PREFERRED_DEBUGGING_TYPE DBX_DEBUG
/* When generating stabs debugging, use N_BINCL entries. */
Regards,
Adriaan van Os