From ca3a382ea3aa9c9ccb57060afae47c7f702727ac Mon Sep 17 00:00:00 2001 From: Wilco Dijkstra Date: Thu, 14 Sep 2017 12:47:35 +0100 Subject: Enable unwind info in libc-start.c and backtrace.c Add unwind info to __libc_start_main so that unwinding continues one extra level to _start. Similarly add unwind info to backtrace. Given many targets require this, do this in a general way. * csu/Makefile: Add -funwind-tables to libc-start.c. * debug/Makefile: Add -funwind-tables to backtrace.c. * sysdeps/aarch64/Makefile: Remove CFLAGS-backtrace.c. * sysdeps/arm/Makefile: Likewise. * sysdeps/i386/Makefile: Likewise. * sysdeps/m68k/Makefile: Likewise. * sysdeps/mips/Makefile: Likewise. * sysdeps/nios2/Makefile: Likewise. * sysdeps/sh/Makefile: Likewise. * sysdeps/sparc/Makefile: Likewise. --- debug/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'debug') diff --git a/debug/Makefile b/debug/Makefile index 504bf87..a9ac779 100644 --- a/debug/Makefile +++ b/debug/Makefile @@ -63,7 +63,7 @@ elide-routines.o := stack_chk_fail_local CFLAGS-stack_chk_fail.c = $(no-stack-protector) CFLAGS-stack_chk_fail_local.c = $(no-stack-protector) -CFLAGS-backtrace.c = -fno-omit-frame-pointer +CFLAGS-backtrace.c = -fno-omit-frame-pointer -funwind-tables CFLAGS-sprintf_chk.c = $(libio-mtsafe) CFLAGS-snprintf_chk.c = $(libio-mtsafe) CFLAGS-vsprintf_chk.c = $(libio-mtsafe) -- cgit v1.1