llvm-project
llvm-project copied to clipboard
[main] Linker error while building unit tests for Clang: `DirectoryWatcherTest`
ld.lld: error: undefined symbol: clang::DirectoryWatcher::create(llvm::StringRef, std::function<void (llvm::ArrayRef<clang::DirectoryWatcher::Event>, bool)>, bool)
>>> referenced by DirectoryWatcherTest.cpp:486 (/home/helmaazouz/repositories/personal/llvm/llvm-project/clang/unittests/DirectoryWatcher/DirectoryWatcherTest.cpp:486)
>>> tools/clang/unittests/AllClangUnitTests.lto.o:(DirectoryWatcherTest_InvalidatedWatcherAsync_Test::TestBody())
>>> referenced by DirectoryWatcherTest.cpp:450 (/home/helmaazouz/repositories/personal/llvm/llvm-project/clang/unittests/DirectoryWatcher/DirectoryWatcherTest.cpp:450)
>>> tools/clang/unittests/AllClangUnitTests.lto.o:(DirectoryWatcherTest_InvalidatedWatcher_Test::TestBody())
>>> referenced by DirectoryWatcherTest.cpp:428 (/home/helmaazouz/repositories/personal/llvm/llvm-project/clang/unittests/DirectoryWatcher/DirectoryWatcherTest.cpp:428)
>>> tools/clang/unittests/AllClangUnitTests.lto.o:(DirectoryWatcherTest_DeleteWatchedDir_Test::TestBody())
>>> referenced 5 more times
clang++: error: linker command failed with exit code 1 (use -v to see invocation)
ninja: build stopped: subcommand failed.
Build settings:
cd $LLVM_REPO/llvm
cp ~/Downloads/CMakeUserPresets.json .
cmake --preset llvm-rwdi
cmake --build build/llvm-rwdi
@hamidelmaazouz can i work on this ??
Hey @hamidelmaazouz , #178455 this is my PR link .
I'd like to work on this. Is it still available?
This is already fixed. See 507d1856ccef4193ed48edabc010fe4661c9216c.