summaryrefslogtreecommitdiff
path: root/CMakeLists.txt
diff options
context:
space:
mode:
authorĐoàn Trần Công Danh <congdanhqx@gmail.com>2021-07-18 16:32:38 +0700
committerBrad King <brad.king@kitware.com>2021-07-26 12:14:02 -0400
commitaa4c30182b0c258cddfb0582e7cfc2561b69a378 (patch)
treec8e877011478e9a27b7f62fde4c711e4c10f8f55 /CMakeLists.txt
parent0615aeffbfa9e1e23dd24af640fdaddea7be9a94 (diff)
downloadcmake-aa4c30182b0c258cddfb0582e7cfc2561b69a378.tar.gz
Add option to explicitly avoid using execinfo for backtraces
backtrace(3) from libexecinfo in musl will run into crash [1]. Provide an option to disable it explicitly even if libexecinfo is present. 1: https://www.openwall.com/lists/musl/2021/07/17/1
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r--CMakeLists.txt3
1 files changed, 3 insertions, 0 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 44b433ac8f..9944ea4ce3 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -361,6 +361,9 @@ macro (CMAKE_BUILD_UTILITIES)
if(CMake_NO_CXX_STANDARD)
set(KWSYS_CXX_STANDARD "")
endif()
+ if(CMake_NO_SELF_BACKTRACE)
+ set(KWSYS_NO_EXECINFO 1)
+ endif()
if(WIN32)
# FIXME: Teach KWSys to hard-code these checks on Windows.
set(KWSYS_C_HAS_CLOCK_GETTIME_MONOTONIC_COMPILED 0)