summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Support
diff options
context:
space:
mode:
authorEric Christopher <echristo@apple.com>2012-09-21 23:03:29 +0000
committerEric Christopher <echristo@apple.com>2012-09-21 23:03:29 +0000
commit9fafe07da0e613862c81ae1eddb9de61d08d7d28 (patch)
treeadb1be19bf16cfaf29767890c6f5ce8e6dd8d8d6 /llvm/lib/Support
parent8d042fa519c798b90fdbea3fb36bafda6dba41ba (diff)
downloadbcm5719-llvm-9fafe07da0e613862c81ae1eddb9de61d08d7d28.tar.gz
bcm5719-llvm-9fafe07da0e613862c81ae1eddb9de61d08d7d28.zip
Add an --enable-backtraces option to configure to determine
whether or not we want to print out backtrace information. Useful for libraries that don't need backtrace information on a crash. rdar://11844710 llvm-svn: 164426
Diffstat (limited to 'llvm/lib/Support')
-rw-r--r--llvm/lib/Support/Unix/Signals.inc2
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/lib/Support/Unix/Signals.inc b/llvm/lib/Support/Unix/Signals.inc
index b7f83b6ff73..7d161a6a056 100644
--- a/llvm/lib/Support/Unix/Signals.inc
+++ b/llvm/lib/Support/Unix/Signals.inc
@@ -243,7 +243,7 @@ void llvm::sys::AddSignalHandler(void (*FnPtr)(void *), void *Cookie) {
// On glibc systems we have the 'backtrace' function, which works nicely, but
// doesn't demangle symbols.
static void PrintStackTrace(void *) {
-#ifdef HAVE_BACKTRACE
+#if defined(HAVE_BACKTRACE) && defined(ENABLE_BACKTRACE)
static void* StackTrace[256];
// Use backtrace() to output a backtrace on Linux systems with glibc.
int depth = backtrace(StackTrace,
OpenPOWER on IntegriCloud