[PATCH] D57777: [gn] Fix clang-tidy build
Mirko Bonadei via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Feb 5 12:03:51 PST 2019
mbonadei created this revision.
mbonadei added a reviewer: thakis.
Herald added a project: LLVM.
Herald added a subscriber: llvm-commits.
Not depending on //clang/lib/StaticAnalyzer/Core and //clang/lib/StaticAnalyzer/Frontend causes a linker error even if ClangSACheckers are not supported.
Undefined symbols for architecture x86_64:
"clang::ento::CreateAnalysisConsumer(clang::CompilerInstance&)", referenced from:
clang::tidy::ClangTidyASTConsumerFactory::CreateASTConsumer(clang::CompilerInstance&, llvm::StringRef) in libclangTidy.a(libclangTidy.ClangTidy.o)
Repository:
rL LLVM
https://reviews.llvm.org/D57777
Files:
llvm/utils/gn/secondary/clang-tools-extra/clang-tidy/BUILD.gn
Index: llvm/utils/gn/secondary/clang-tools-extra/clang-tidy/BUILD.gn
===================================================================
--- llvm/utils/gn/secondary/clang-tools-extra/clang-tidy/BUILD.gn
+++ llvm/utils/gn/secondary/clang-tools-extra/clang-tidy/BUILD.gn
@@ -22,14 +22,12 @@
# ClangSACheckers
]
- # TODO(mbonadei): Add support for Clang Static Analyzer checkers.
- # Without this, "clang-analyzer-" will not work.
- # if (clang_enable_static_analyzer) {
- # deps += [
- # "//clang/lib/StaticAnalyzer/Core",
- # "//clang/lib/StaticAnalyzer/Frontend",
- # ]
- # }
+ if (clang_enable_static_analyzer) {
+ deps += [
+ "//clang/lib/StaticAnalyzer/Core",
+ "//clang/lib/StaticAnalyzer/Frontend",
+ ]
+ }
sources = [
"ClangTidy.cpp",
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D57777.185368.patch
Type: text/x-patch
Size: 799 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20190205/5056dfc9/attachment.bin>
More information about the llvm-commits
mailing list