diff options
author | Salvatore Cro <salvatore.cro@st.com> | 2010-09-09 15:45:44 +0200 |
---|---|---|
committer | Carmelo Amoroso <carmelo.amoroso@st.com> | 2010-09-15 12:31:22 +0200 |
commit | 37eb913ed8c4798b736e678f4dbd9f4a91a68f74 (patch) | |
tree | 63fc2c1dbb887a043a7291c9c6215d2db7b5ba5a /extra | |
parent | 7ac7be14eb4c8927fddffbe01fed74c605bf8597 (diff) |
libubacktrace: Provide uClibc with backtrace functions
A new shared object, libubacktrace.so.0 is added to uClibc
to provide backtrace functions to support application self-debugging.
This set of functions requires to dynamically load libgcc_s.so so they
need to call dlopen/dlsym that are provided by libdl. For this reason
they cannot be included into libc.so.0 but are provided by a new library.
User application that wants to use backtrace needs to be compiled with
-fexceptions option and -rdynamic to get full symbols printed and must be
linked against libubacktrace.so
Signed-off-by: Carmelo Amoroso <carmelo.amoroso@st.com>
Diffstat (limited to 'extra')
-rw-r--r-- | extra/Configs/Config.in | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/extra/Configs/Config.in b/extra/Configs/Config.in index 7f0ac9db6..e8d522d71 100644 --- a/extra/Configs/Config.in +++ b/extra/Configs/Config.in @@ -2308,6 +2308,25 @@ config UCLIBC_MALLOC_DEBUGGING Because this increases the size of malloc appreciably (due to strings etc), you should say N unless you need to debug a malloc problem. +config UCLIBC_HAS_BACKTRACE + bool "Add support for application self-debugging" + depends on HAVE_SHARED && TARGET_sh + default n + help + Answer Y here to compile support for application self-debugging, by adding + a new shared object "libubacktrace.so" that provides the following new + functions: + backtrace, backtrace_symbols, backtrace_symbols_fd + + The backtrace functionality is currently supported on SH platform, and it + based on dwarf2 informations to properly work, so any application that + want to use backtrace needs to be built with -fexceptions flag. + + The symbol names may be unavailable without the use of special linker + options. For systems using the GNU linker, it is necessary to use the + -rdynamic linker option too. Note that names of "static" functions are not + exposed, and won't be available in the backtrace. + config WARNINGS string "Compiler Warnings" default "-Wall" |