2013-08-22 21:07:14 +08:00
|
|
|
set(LLVM_LINK_COMPONENTS
|
2013-12-10 03:27:57 +08:00
|
|
|
Support
|
2013-08-22 21:07:14 +08:00
|
|
|
)
|
|
|
|
|
2013-09-04 01:58:19 +08:00
|
|
|
add_clang_library(clangApplyReplacements
|
2013-08-30 22:33:56 +08:00
|
|
|
lib/Tooling/ApplyReplacements.cpp
|
2014-02-26 14:41:29 +08:00
|
|
|
|
|
|
|
LINK_LIBS
|
2014-10-30 11:22:32 +08:00
|
|
|
clangAST
|
2013-08-22 21:07:14 +08:00
|
|
|
clangBasic
|
2014-07-17 00:50:17 +08:00
|
|
|
clangRewrite
|
2014-10-30 08:44:01 +08:00
|
|
|
clangToolingCore
|
[clang-apply-replacements] Don't forget to link to clangToolingRefactor
Fixes build:
[1/3] Linking CXX shared library lib/libclangApplyReplacements.so.7svn
FAILED: lib/libclangApplyReplacements.so.7svn
<...>
/usr/local/bin/ld.lld: error: undefined symbol: clang::tooling::AtomicChange::replace(clang::SourceManager const&, clang::SourceLocation, unsigned int, llvm::StringRef)
>>> referenced by ApplyReplacements.cpp
>>> tools/clang/tools/extra/clang-apply-replacements/CMakeFiles/clangApplyReplacements.dir/lib/Tooling/ApplyReplacements.cpp.o:(clang::replace::mergeAndDeduplicate(std::vector<clang::tooling::TranslationUnitReplacements, std::allocator<clang::tooling::TranslationUnitReplacements> > const&, std::vector<clang::tooling::TranslationUnitDiagnostics, std::allocator<clang::tooling::TranslationUnitDiagnostics> > const&, llvm::DenseMap<clang::FileEntry const*, std::vector<clang::tooling::AtomicChange, std::allocator<clang::tooling::AtomicChange> >, llvm::DenseMapInfo<clang::FileEntry const*>, llvm::detail::DenseMapPair<clang::FileEntry const*, std::vector<clang::tooling::AtomicChange, std::allocator<clang::tooling::AtomicChange> > > >&, clang::SourceManager&))
/usr/local/bin/ld.lld: error: undefined symbol: clang::tooling::applyAtomicChanges[abi:cxx11](llvm::StringRef, llvm::StringRef, llvm::ArrayRef<clang::tooling::AtomicChange>, clang::tooling::ApplyChangesSpec const&)
>>> referenced by ApplyReplacements.cpp
>>> tools/clang/tools/extra/clang-apply-replacements/CMakeFiles/clangApplyReplacements.dir/lib/Tooling/ApplyReplacements.cpp.o:(clang::replace::applyChanges[abi:cxx11](llvm::StringRef, std::vector<clang::tooling::AtomicChange, std::allocator<clang::tooling::AtomicChange> > const&, clang::tooling::ApplyChangesSpec const&, clang::DiagnosticsEngine&))
clang: error: linker command failed with exit code 1 (use -v to see invocation)
Refs. D43764, rL329813
llvm-svn: 329892
2018-04-12 18:01:20 +08:00
|
|
|
clangToolingRefactor
|
2013-08-22 21:07:14 +08:00
|
|
|
)
|
|
|
|
|
2013-08-30 22:33:56 +08:00
|
|
|
include_directories(
|
|
|
|
${CMAKE_CURRENT_SOURCE_DIR}
|
|
|
|
include
|
|
|
|
)
|
2013-08-22 21:07:14 +08:00
|
|
|
add_subdirectory(tool)
|