option(LIBCXXABI_ENABLE_ASSERTIONS "Enable assertions independent of build mode." ON)
option(LIBCXXABI_ENABLE_PEDANTIC "Compile with pedantic enabled." ON)
option(LIBCXXABI_ENABLE_WERROR "Fail and stop if a warning is triggered." OFF)
-option(LIBCXXABI_USE_LLVM_UNWINDER "Build and use the LLVM unwinder." OFF)
+set(LIBCXXABI_USE_LLVM_UNWINDER_DEFAULT OFF)
+if (${LLVM_NATIVE_ARCH} MATCHES arm)
+ set(LIBCXXABI_USE_LLVM_UNWINDER_DEFAULT ON)
+endif ()
+option(LIBCXXABI_USE_LLVM_UNWINDER "Build and use the LLVM unwinder."
+ ${LIBCXXABI_USE_LLVM_UNWINDER_DEFAULT})
option(LIBCXXABI_ENABLE_THREADS "Build with threads enabled" ON)
set(LIBCXXABI_GCC_TOOLCHAIN "" CACHE STRING "GCC toolchain for cross compiling.")
set(LIBCXXABI_SYSROOT "" CACHE STRING "Sysroot for cross compiling.")