[PATCH] D106143: [CMake][TSAN] Add build dependency against libcxx

Petr Hosek via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Jul 16 10:51:27 PDT 2021


phosek added a comment.

In D106143#2883083 <https://reviews.llvm.org/D106143#2883083>, @avogelsgesang wrote:

> [12:12:49] :					 [clang-build-stage1] In file included from /Volumes/build/tc/473843e25ae443f4/release/src/clang-osx10.11-x86_64-release-master_avogelsgesang-llvm12.12.0.1.c2458596.r74f7019d/compiler-rt/lib/asan/asan_new_delete.cpp:22:
> [12:12:49] :					 [clang-build-stage1] /Volumes/build/tc/473843e25ae443f4/release/src/clang-osx10.11-x86_64-release-master_avogelsgesang-llvm12.12.0.1.c2458596.r74f7019d/build/stage1_build/./bin/../include/c++/v1/stddef.h:39:10: fatal error: '__config' file not found
> [12:12:49] :					 [clang-build-stage1] #include <__config>
> [12:12:49] :					 [clang-build-stage1]          ^~~~~~~~~~
> [12:12:49] :					 [clang-build-stage1] 1 error generated.
> [12:12:49] :					 [clang-build-stage1] make[5]: *** [compiler-rt/lib/asan/CMakeFiles/RTAsan_dynamic.osx.dir/asan_new_delete.cpp.o] Error 1
> [12:12:49] :					 [clang-build-stage1] make[4]: *** [compiler-rt/lib/asan/CMakeFiles/RTAsan_dynamic.osx.dir/all] Error 2

That error shows issue when compiling ASan, not TSan, so I'm still not sure why this change is needed?



================
Comment at: compiler-rt/lib/tsan/CMakeLists.txt:117
 
+# TSAN uses headers provided by libcxx (errno.h, stdio.h, ...).
+if (TARGET cxx-headers OR HAVE_LIBCXX)
----------------
Headers like `errno.h` or `stdio.h` are provided by libc, not libc++, do you know which libc++ headers are needed by TSan?


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D106143/new/

https://reviews.llvm.org/D106143



More information about the llvm-commits mailing list