[clang][bytecode] Implement __builtin_reduce_mul (#118287)
[llvm-project.git] / clang / unittests / CMakeLists.txt
blob85d265426ec80be6a8259666c72da36e2c869544
1 add_custom_target(ClangUnitTests)
2 set_target_properties(ClangUnitTests PROPERTIES FOLDER "Clang/Tests")
4 if(CLANG_BUILT_STANDALONE)
5   # LLVMTesting* libraries are needed for some of the unittests.
6   if (EXISTS ${LLVM_MAIN_SRC_DIR}/lib/Testing/Annotations
7       AND NOT TARGET LLVMTestingAnnotations)
8     add_subdirectory(${LLVM_MAIN_SRC_DIR}/lib/Testing/Annotations
9       lib/Testing/Annotations)
10   endif()
11   if (EXISTS ${LLVM_MAIN_SRC_DIR}/lib/Testing/Support
12       AND NOT TARGET LLVMTestingSupport)
13     add_subdirectory(${LLVM_MAIN_SRC_DIR}/lib/Testing/Support
14       lib/Testing/Support)
15   endif()
16 endif()
18 # add_clang_unittest(test_dirname file1.cpp file2.cpp)
20 # Will compile the list of files together and link against the clang
21 # Produces a binary named 'basename(test_dirname)'.
22 function(add_clang_unittest test_dirname)
23   add_unittest(ClangUnitTests ${test_dirname} ${ARGN})
24 endfunction()
26 add_subdirectory(Basic)
27 add_subdirectory(Lex)
28 add_subdirectory(Driver)
29 if(CLANG_ENABLE_STATIC_ANALYZER)
30   add_subdirectory(Analysis)
31   add_subdirectory(StaticAnalyzer)
32 endif()
33 add_subdirectory(ASTMatchers)
34 add_subdirectory(AST)
35 add_subdirectory(CrossTU)
36 add_subdirectory(Tooling)
37 add_subdirectory(Format)
38 add_subdirectory(Frontend)
39 add_subdirectory(Rewrite)
40 add_subdirectory(Sema)
41 add_subdirectory(CodeGen)
42 if(HAVE_CLANG_REPL_SUPPORT)
43   add_subdirectory(Interpreter)
44 endif()
45 # FIXME: libclang unit tests are disabled on Windows due
46 # to failures, mostly in libclang.VirtualFileOverlay_*.
47 if(NOT WIN32 AND CLANG_TOOL_LIBCLANG_BUILD) 
48   add_subdirectory(libclang)
49 endif()
50 add_subdirectory(DirectoryWatcher)
51 add_subdirectory(Index)
52 add_subdirectory(InstallAPI)
53 add_subdirectory(Serialization)
54 add_subdirectory(Support)