[libcxx-commits] [PATCH] D60743: Allow building without threads in standalone builds

Matthew Bauer via Phabricator via libcxx-commits libcxx-commits at lists.llvm.org
Mon Apr 15 18:56:11 PDT 2019


matthewbauer created this revision.
matthewbauer added a project: libc++.
Herald added subscribers: libcxx-commits, ldionne, sunfish, aheejin, mgorny.

Setting _LIBCPP_HAS_NO_THREADS is needed when building libcxxabi without threads in standalone mode. This is useful when target WASM. Otherwise, you get an error like "No thread API" when building libcxxabi.


Repository:
  rCXXA libc++abi

https://reviews.llvm.org/D60743

Files:
  CMakeLists.txt


Index: CMakeLists.txt
===================================================================
--- CMakeLists.txt
+++ CMakeLists.txt
@@ -362,6 +362,7 @@
                         " is also set to ON.")
   endif()
   add_definitions(-D_LIBCXXABI_HAS_NO_THREADS)
+  add_definitions(-D_LIBCPP_HAS_NO_THREADS)
 endif()
 
 if (LIBCXXABI_HAS_EXTERNAL_THREAD_API)


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D60743.195287.patch
Type: text/x-patch
Size: 351 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/libcxx-commits/attachments/20190416/0025756c/attachment.bin>


More information about the libcxx-commits mailing list