[libcxx-commits] [libcxx] [libc++] Don't build against libcxxrt by default on FreeBSD (PR #84484)

via libcxx-commits libcxx-commits at lists.llvm.org
Fri Mar 8 05:49:20 PST 2024


llvmbot wrote:


<!--LLVM PR SUMMARY COMMENT-->

@llvm/pr-subscribers-libcxx

Author: Louis Dionne (ldionne)

<details>
<summary>Changes</summary>

The libc++ CMake build aims to provide a general-purpose configuration that matches the canonical LLVM setup (libc++ / libc++abi / libunwind), not the configuration used for compatibility on any given system. For these "compatibility" configurations, we use CMake caches like Apple.cmake and FreeBSD.cmake.

Defaulting to libcxxrt on FreeBSD makes it look as though we're trying to build the system compatible configuration on FreeBSD, which isn't really correct and causes confusion more than anything else.

Fixes #<!-- -->84476

---
Full diff: https://github.com/llvm/llvm-project/pull/84484.diff


1 Files Affected:

- (modified) libcxx/CMakeLists.txt (-2) 


``````````diff
diff --git a/libcxx/CMakeLists.txt b/libcxx/CMakeLists.txt
index d392e95077ac57..e565c47c76687a 100644
--- a/libcxx/CMakeLists.txt
+++ b/libcxx/CMakeLists.txt
@@ -229,8 +229,6 @@ option(LIBCXX_USE_COMPILER_RT "Use compiler-rt instead of libgcc" OFF)
 # ABI Library options ---------------------------------------------------------
 if (MSVC)
   set(LIBCXX_DEFAULT_ABI_LIBRARY "vcruntime")
-elseif (${CMAKE_SYSTEM_NAME} MATCHES "FreeBSD")
-  set(LIBCXX_DEFAULT_ABI_LIBRARY "libcxxrt")
 else()
   set(LIBCXX_DEFAULT_ABI_LIBRARY "libcxxabi")
 endif()

``````````

</details>


https://github.com/llvm/llvm-project/pull/84484


More information about the libcxx-commits mailing list