Skip to content

Conversation

c8ef
Copy link
Contributor

@c8ef c8ef commented Oct 9, 2025

… builds using MinGW.

I tried running the original command, but the error told me I had to include libunwind.

@c8ef c8ef requested a review from a team as a code owner October 9, 2025 15:36
@llvmbot llvmbot added the libc++ libc++ C++ Standard Library. Not GNU libstdc++. Not libc++abi. label Oct 9, 2025
@c8ef
Copy link
Contributor Author

c8ef commented Oct 9, 2025

I also have a minor question regarding the libcxx benchmarks. I know I can use ./build/bin/llvm-lit to run individual test cases, but can I use it to run benchmark files as well?

@llvmbot
Copy link
Member

llvmbot commented Oct 9, 2025

@llvm/pr-subscribers-libcxx

Author: Connector Switch (c8ef)

Changes

… builds using MinGW.

I tried running the original command, but the error told me I had to include libunwind.


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

1 Files Affected:

  • (modified) libcxx/docs/VendorDocumentation.rst (+1-1)
diff --git a/libcxx/docs/VendorDocumentation.rst b/libcxx/docs/VendorDocumentation.rst
index aede8f9a81dd2..7eba598909a74 100644
--- a/libcxx/docs/VendorDocumentation.rst
+++ b/libcxx/docs/VendorDocumentation.rst
@@ -443,7 +443,7 @@ e.g. the ``mingw-w64-x86_64-clang`` package), together with CMake and ninja.
           -DCMAKE_C_COMPILER=clang                                                    \
           -DCMAKE_CXX_COMPILER=clang++                                                \
           -DLLVM_ENABLE_LLD=ON                                                        \
-          -DLLVM_ENABLE_RUNTIMES="libcxx;libcxxabi"                                   \
+          -DLLVM_ENABLE_RUNTIMES="libcxx;libcxxabi;libunwind"                         \
           -DLIBCXXABI_ENABLE_SHARED=OFF                                               \
           -DLIBCXX_ENABLE_STATIC_ABI_LIBRARY=ON
   > ninja -C build cxx

@philnik777 philnik777 requested review from mstorsjo and removed request for philnik777 October 10, 2025 06:40
@mstorsjo
Copy link
Member

I tried running the original command, but the error told me I had to include libunwind.

That's interesting - can you quote the exact error? I did test this build configuration back when writing the docs, but apparently something has changed somewhere. (It may be some libcxx/libcxxabi internal defaults that have changed.)

Including libunwind clearly is a more complete build setup, how it possibly is built in most cases, but for the original example, I tried to do a setup that was as minimal as possible. But including libunwind should probably make it more robust and be a closer match to what we actually test.

@c8ef
Copy link
Contributor Author

c8ef commented Oct 10, 2025

That's interesting - can you quote the exact error?

CMake Error at C:/Users/xxx/Desktop/llvm-project/libcxxabi/CMakeLists.txt:57 (
message):
  LIBCXXABI_USE_LLVM_UNWINDER is set to ON, but libunwind is not specified in
  LLVM_ENABLE_RUNTIMES.

@c8ef c8ef merged commit 21b2bdd into main Oct 10, 2025
67 of 69 checks passed
@c8ef c8ef deleted the users/c8ef/libcxx-mingw branch October 10, 2025 14:58
DharuniRAcharya pushed a commit to DharuniRAcharya/llvm-project that referenced this pull request Oct 13, 2025
llvm#162682)

… builds using MinGW.

I tried running the original command, but the error told me I had to
include libunwind.
akadutta pushed a commit to akadutta/llvm-project that referenced this pull request Oct 14, 2025
llvm#162682)

… builds using MinGW.

I tried running the original command, but the error told me I had to
include libunwind.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

libc++ libc++ C++ Standard Library. Not GNU libstdc++. Not libc++abi.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants