Fix unwind detection logic when compiler-rt is disabled

This revision fixes the LLVM CMake build system unable to find the correct way to build libunwind when compiler-rt is disabled. The error may look like:

CMake Error at /root/llvm-toolchain-17-17.0.6/libunwind/src/CMakeLists.txt:90 (message):
  Compiler doesn't support generation of unwind tables if exception support
  is disabled.  Building libunwind DSO with runtime dependency on C++ ABI
  library is not supported.

Merge request reports

Loading