Debian Codegraph @

llvm-project/clang-tools-extra/unittests/clang-tidy/CMakeLists.txt

raw
1 set(LLVM_LINK_COMPONENTS
2 FrontendOpenMP
3 Support
4 )
5
6 if(CLANG_BUILT_STANDALONE)
7 # LLVMTestingSupport library is needed for clang-tidy tests.
8 if (EXISTS ${LLVM_MAIN_SRC_DIR}/lib/Testing/Support
9 AND NOT TARGET LLVMTestingSupport)
10 add_subdirectory(${LLVM_MAIN_SRC_DIR}/lib/Testing/Support
11 lib/Testing/Support)
12 endif()
13 endif()
14
15 get_filename_component(CLANG_LINT_SOURCE_DIR
16 ${CMAKE_CURRENT_SOURCE_DIR}/../../clang-tidy REALPATH)
17 include_directories(${CLANG_LINT_SOURCE_DIR})
18
19 add_extra_unittest(ClangTidyTests
20 AddConstTest.cpp
21 ClangTidyDiagnosticConsumerTest.cpp
22 ClangTidyOptionsTest.cpp
23 DeclRefExprUtilsTest.cpp
24 IncludeInserterTest.cpp
25 GlobListTest.cpp
26 GoogleModuleTest.cpp
27 LLVMModuleTest.cpp
28 ModernizeModuleTest.cpp
29 NamespaceAliaserTest.cpp
30 ObjCModuleTest.cpp
31 OptionsProviderTest.cpp
32 OverlappingReplacementsTest.cpp
33 UsingInserterTest.cpp
34 ReadabilityModuleTest.cpp
35 TransformerClangTidyCheckTest.cpp
36 )
37
38 clang_target_link_libraries(ClangTidyTests
39 PRIVATE
40 clangAST
41 clangASTMatchers
42 clangBasic
43 clangFrontend
44 clangLex
45 clangSerialization
46 clangTooling
47 clangToolingCore
48 clangTransformer
49 )
50 target_link_libraries(ClangTidyTests
51 PRIVATE
52 clangTidy
53 clangTidyAndroidModule
54 clangTidyGoogleModule
55 clangTidyLLVMModule
56 clangTidyModernizeModule
57 clangTidyObjCModule
58 clangTidyReadabilityModule
59 clangTidyUtils
60 LLVMTestingAnnotations
61 LLVMTestingSupport
62 )