File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -64,6 +64,11 @@ if(ENABLE_LIBUNWIND AND UNIX AND NOT ANDROID)
6464 if (LIBUNWIND_ARCH_LIB)
6565 list (APPEND LIBUNWIND_LIBRARIES ${LIBUNWIND_ARCH_LIB} )
6666 endif ()
67+ elseif (CMAKE_SYSTEM_PROCESSOR MATCHES "aarch64|ARM64" )
68+ find_library (LIBUNWIND_ARCH_LIB unwind-aarch64 )
69+ if (LIBUNWIND_ARCH_LIB)
70+ list (APPEND LIBUNWIND_LIBRARIES ${LIBUNWIND_ARCH_LIB} )
71+ endif ()
6772 endif ()
6873 set (LIBUNWIND_FOUND TRUE )
6974 endif ()
@@ -83,6 +88,16 @@ if(ENABLE_LIBUNWIND AND UNIX AND NOT ANDROID)
8388 message (WARNING "libunwind-x86_64 not found; stack traces may fail to link on x86_64." )
8489 endif ()
8590 endif ()
91+ elseif (CMAKE_SYSTEM_PROCESSOR MATCHES "aarch64|ARM64" )
92+ list (JOIN LIBUNWIND_LIBRARIES ";" _libunwind_libs_joined)
93+ if (NOT _libunwind_libs_joined MATCHES "unwind-aarch64" )
94+ find_library (LIBUNWIND_ARCH_LIB unwind-aarch64 )
95+ if (LIBUNWIND_ARCH_LIB)
96+ list (APPEND LIBUNWIND_LIBRARIES ${LIBUNWIND_ARCH_LIB} )
97+ else ()
98+ message (WARNING "libunwind-aarch64 not found; stack traces may fail to link on aarch64." )
99+ endif ()
100+ endif ()
86101 endif ()
87102 set (HAVE_LIBUNWIND ON )
88103 message (STATUS "libunwind found - LIBUNWIND_LIBRARIES=${LIBUNWIND_LIBRARIES} " )
You can’t perform that action at this time.
0 commit comments