diff options
author | Thomas Wood <thomas.wood@intel.com> | 2015-03-13 17:02:12 +0000 |
---|---|---|
committer | Thomas Wood <thomas.wood@intel.com> | 2015-03-26 15:50:05 +0000 |
commit | 277ca2b992c766581ef6ef01ea210808f456fbe0 (patch) | |
tree | d5002e6dba2c2e5287e4eac9c918ba40a096ed63 /configure.ac | |
parent | 2659cbbf643f2fdbf2f9acf8008edd4c6980cd2f (diff) |
lib: print a stack trace when a test assertion fails
Add an optional dependency on libunwind to print stack traces when a
test assertion fails.
Acked-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Signed-off-by: Thomas Wood <thomas.wood@intel.com>
Diffstat (limited to 'configure.ac')
-rw-r--r-- | configure.ac | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/configure.ac b/configure.ac index 9b646ddb..b9ecef8d 100644 --- a/configure.ac +++ b/configure.ac @@ -187,6 +187,15 @@ AM_CONDITIONAL(BUILD_SHADER_DEBUGGER, [test "x$BUILD_SHADER_DEBUGGER" != xno]) AS_IF([test "x$BUILD_SHADER_DEBUGGER" != xno], [enable_debugger=yes], [enable_debugger=no]) +AC_ARG_WITH(libunwind, + AS_HELP_STRING([--without-libunwind], + [Build tests without libunwind support]), + [], [with_libunwind=yes]) +if test "x$with_libunwind" = xyes; then + PKG_CHECK_MODULES(LIBUNWIND, libunwind, AC_DEFINE(HAVE_LIBUNWIND, 1, [libunwind support]), + AC_MSG_ERROR([libunwind not found. Use --without-libunwind to disable libunwind support.])) +fi + # ----------------------------------------------------------------------------- # To build multithread code, gcc uses -pthread, Solaris Studio cc uses -mt @@ -243,6 +252,7 @@ echo "" echo " • Tests:" echo " Build tests : ${BUILD_TESTS}" echo " Compile prime tests: ${NOUVEAU}" +echo " Print stack traces : ${with_libunwind}" echo "" echo " • Tools:" echo " Assembler : ${enable_assembler}" |