btrfs-progs: autoconf: check if backtrace is really supported

Signed-off-by: David Sterba <dsterba@suse.cz>
master
David Sterba 2015-02-03 16:50:33 +01:00
parent 93e0bd4703
commit 8fa3fed3a4
1 changed files with 6 additions and 0 deletions

View File

@ -68,6 +68,12 @@ AS_IF([test "x$enable_backtrace" = xno], [
AC_DEFINE([BTRFS_DISABLE_BACKTRACE], [1], [disable backtrace stuff in kerncompat.h ])
])
if test "x$enable_backtrace" = xyes; then
AC_CHECK_HEADERS([execinfo.h])
AC_CHECK_FUNCS([backtrace backtrace_symbols_fd], [],
AC_MSG_ERROR([standard library does not have backtrace support]))
fi
AC_ARG_ENABLE([documentation],
AS_HELP_STRING([--disable-documentation], [do not build domumentation]),