if (HAVE_BACKTRACE)
set (BACKTRACE_FILE backtrace.c simple.c)
else ()
- message("WARNING: No unwind.h, setting BACKTRACE_SUPPORTED=0")
- set (BACKTRACE_FILE nounwind.c)
- set (BACKTRACE_SUPPORTED 0)
+ message(FATAL_ERROR "Could not find unwind.h, install the libunwind development package.")
endif ()
include (CheckCCompilerFlag)
set (FORMAT_FILE elf.c dwarf.c)
math (EXPR BACKTRACE_ELF_SIZE 8*${CMAKE_C_SIZEOF_DATA_PTR})
else ()
- message("WARNING: Unknown executable format \"${CMAKE_EXECUTABLE_FORMAT}\", setting BACKTRACE_SUPPORTED=0")
- set (FORMAT_FILE unknown.c)
- set (BACKTRACE_SUPPORTED 0)
+ message(FATAL_ERROR "Unknown executable format \"${CMAKE_EXECUTABLE_FORMAT}\", currently only ELF is supported.")
endif ()
check_symbol_exists (mmap sys/mman.h HAVE_MMAP)
find_path(DWARF_INCLUDE_DIR dwarf.h
PATH_SUFFIXES libdwarf)
if (NOT DWARF_INCLUDE_DIR)
- message("WARNING: No dwarf.h, setting BACKTRACE_SUPPORTED=0")
- set (FORMAT_FILE unknown.c)
- set (BACKTRACE_SUPPORTED 0)
- else()
- include_directories(${DWARF_INCLUDE_DIR})
+ message(FATAL_ERROR "Could not find dwarf.h, try installing the elfutils development package.")
endif ()
+include_directories(${DWARF_INCLUDE_DIR})
configure_file (backtrace-supported.h.in backtrace-supported.h)