aboutsummaryrefslogtreecommitdiff
path: root/configure.ac
diff options
context:
space:
mode:
authorNick Mathewson <nickm@torproject.org>2014-02-24 11:41:53 -0500
committerNick Mathewson <nickm@torproject.org>2014-02-24 11:45:03 -0500
commit68ed4878ca97902c8b909d88dd855d71e6647376 (patch)
treecf0fd2d07409311f213919125effad83737a56c4 /configure.ac
parente1deb01e5f1a666486690f9e511b3a0af66ed683 (diff)
downloadtor-68ed4878ca97902c8b909d88dd855d71e6647376.tar
tor-68ed4878ca97902c8b909d88dd855d71e6647376.tar.gz
pass our compiler -fasynchronous-unwind-tables by default
This should make more platforms (in particular, ones with compilers where -fomit-frame-pointer is on by default but table generation isn't) support backtrace generation. Thanks to cypherpunks for this one. Fixes bug 11047; bugfix on 0.2.5.2-alpha.
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac7
1 files changed, 7 insertions, 0 deletions
diff --git a/configure.ac b/configure.ac
index 871ca5613..187fadc3b 100644
--- a/configure.ac
+++ b/configure.ac
@@ -649,6 +649,13 @@ CFLAGS="$saved_CFLAGS"
AC_SUBST(F_OMIT_FRAME_POINTER)
dnl ------------------------------------------------------
+dnl If we are adding -fomit-frame-pointer (or if the compiler's doing it
+dnl for us, as GCC 4.6 and later do at many optimization levels), then
+dnl we should try to add -fasynchronous-unwind-tables so that our backtrace
+dnl code will work.
+TOR_CHECK_CFLAGS(-fasynchronous-unwind-tables)
+
+dnl ------------------------------------------------------
dnl Where do you live, libnatpmp? And how do we call you?
dnl There are no packages for Debian or Redhat as of this patch