Merge pull request #11075

58e54bf cmake: disable stack traces by default for release builds (Rene Guenon)

ACKs: selsta, jeffro256, jpk68
This commit is contained in:
tobtoht
2026-08-16 15:20:21 +00:00
+4 -1
View File
@@ -505,7 +505,10 @@ endif()
# Can't install hook in static build on OSX, because OSX linker does not support --wrap
# On ARM, having libunwind package (with .so's only) installed breaks static link.
# When possible, avoid stack tracing using libunwind in favor of using easylogging++.
if (APPLE OR NETBSD)
if (CMAKE_BUILD_TYPE_LOWER STREQUAL "release" AND NOT STACK_TRACE)
set(DEFAULT_STACK_TRACE OFF)
set(LIBUNWIND_LIBRARIES "")
elseif (APPLE OR NETBSD)
set(DEFAULT_STACK_TRACE OFF)
set(LIBUNWIND_LIBRARIES "")
elseif (DEPENDS AND NOT LINUX)