summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--lib/CMakeLists.txt4
-rw-r--r--test/CMakeLists.txt13
2 files changed, 13 insertions, 4 deletions
diff --git a/lib/CMakeLists.txt b/lib/CMakeLists.txt
index 7bb65e923e..dfd819a407 100644
--- a/lib/CMakeLists.txt
+++ b/lib/CMakeLists.txt
@@ -3,9 +3,7 @@ add_subdirectory(Basic)
add_subdirectory(Lex)
add_subdirectory(Parse)
add_subdirectory(AST)
-if(CLANG_ENABLE_REWRITER)
- add_subdirectory(ASTMatchers)
-endif()
+add_subdirectory(ASTMatchers)
add_subdirectory(Sema)
add_subdirectory(CodeGen)
add_subdirectory(Analysis)
diff --git a/test/CMakeLists.txt b/test/CMakeLists.txt
index 2052873cb3..b7d689c778 100644
--- a/test/CMakeLists.txt
+++ b/test/CMakeLists.txt
@@ -27,10 +27,16 @@ endif ()
list(APPEND CLANG_TEST_DEPS
clang clang-headers
c-index-test diagtool
- clang-check clang-format
clang-tblgen
)
+if (CLANG_ENABLE_REWRITER)
+ list(APPEND CLANG_TEST_DEPS
+ clang-check
+ clang-format
+ )
+endif ()
+
if (CLANG_ENABLE_ARCMT)
list(APPEND CLANG_TEST_DEPS
arcmt-test
@@ -42,6 +48,11 @@ if (ENABLE_CLANG_EXAMPLES)
list(APPEND CLANG_TEST_DEPS
clang-interpreter
PrintFunctionNames
+ )
+endif ()
+
+if (ENABLE_CLANG_STATIC_ANALYZER AND ENABLE_CLANG_EXAMPLES)
+ list(APPEND CLANG_TEST_DEPS
SampleAnalyzerPlugin
)
endif ()