зеркало из https://github.com/microsoft/clang.git
Revert "CMake: Update to use standard CMake dependency tracking facilities instead"
This reverts commit r113631 Conflicts: CMakeLists.txt lib/CodeGen/CMakeLists.txt git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@113817 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Родитель
206caf539d
Коммит
560a921b85
|
@ -107,7 +107,6 @@ macro(add_clang_library name)
|
|||
set_target_properties(${name} PROPERTIES COMPILE_FLAGS ${cflag})
|
||||
endif(MSVC)
|
||||
install(TARGETS ${name}
|
||||
EXPORT LLVM
|
||||
LIBRARY DESTINATION lib${LLVM_LIBDIR_SUFFIX}
|
||||
ARCHIVE DESTINATION lib${LLVM_LIBDIR_SUFFIX})
|
||||
endmacro(add_clang_library)
|
||||
|
|
|
@ -2,16 +2,7 @@ set(MODULE TRUE)
|
|||
|
||||
set(LLVM_NO_RTTI 1)
|
||||
|
||||
add_clang_library(PrintFunctionNames
|
||||
PrintFunctionNames.cpp
|
||||
)
|
||||
|
||||
target_link_libraries(PrintFunctionNames
|
||||
clangAST
|
||||
clangFrontend
|
||||
clangBasic
|
||||
)
|
||||
|
||||
add_clang_library(PrintFunctionNames PrintFunctionNames.cpp)
|
||||
|
||||
set_target_properties(PrintFunctionNames
|
||||
PROPERTIES
|
||||
|
|
|
@ -1,24 +1,34 @@
|
|||
set(LLVM_NO_RTTI 1)
|
||||
|
||||
set(LLVM_USED_LIBS
|
||||
clangFrontend
|
||||
clangSerialization
|
||||
clangDriver
|
||||
clangCodeGen
|
||||
clangSema
|
||||
clangChecker
|
||||
clangIndex
|
||||
clangAnalysis
|
||||
clangRewrite
|
||||
clangAST
|
||||
clangParse
|
||||
clangLex
|
||||
clangBasic
|
||||
)
|
||||
|
||||
set(LLVM_LINK_COMPONENTS
|
||||
jit
|
||||
interpreter
|
||||
nativecodegen
|
||||
asmparser
|
||||
bitreader
|
||||
bitwriter
|
||||
codegen
|
||||
ipo
|
||||
selectiondag
|
||||
)
|
||||
|
||||
add_clang_executable(clang-interpreter
|
||||
main.cpp
|
||||
)
|
||||
|
||||
add_llvm_link_components(clang-interpreter jit interpreter nativecodegen)
|
||||
target_link_libraries(clang-interpreter
|
||||
clangFrontend
|
||||
clangSerialization
|
||||
clangDriver
|
||||
clangCodeGen
|
||||
clangSema
|
||||
clangChecker
|
||||
clangIndex
|
||||
clangAnalysis
|
||||
clangRewrite
|
||||
clangAST
|
||||
clangParse
|
||||
clangLex
|
||||
clangBasic
|
||||
)
|
||||
|
||||
add_dependencies(clang-interpreter clang-headers)
|
||||
|
|
|
@ -1,10 +1,6 @@
|
|||
set(LLVM_NO_RTTI 1)
|
||||
|
||||
add_clang_executable(clang-wpa
|
||||
clang-wpa.cpp
|
||||
)
|
||||
|
||||
target_link_libraries(clang-wpa
|
||||
set(LLVM_USED_LIBS
|
||||
clangIndex
|
||||
clangFrontend
|
||||
clangDriver
|
||||
|
@ -16,9 +12,15 @@ target_link_libraries(clang-wpa
|
|||
clangAST
|
||||
clangParse
|
||||
clangLex
|
||||
clangBasic
|
||||
clangBasic)
|
||||
|
||||
set( LLVM_LINK_COMPONENTS
|
||||
bitreader
|
||||
mc
|
||||
core
|
||||
)
|
||||
|
||||
add_dependencies(clang-wpa
|
||||
clang-headers
|
||||
add_clang_executable(clang-wpa
|
||||
clang-wpa.cpp
|
||||
)
|
||||
add_dependencies(clang-wpa clang-headers)
|
||||
|
|
|
@ -1,5 +1,7 @@
|
|||
set(LLVM_NO_RTTI 1)
|
||||
|
||||
set(LLVM_USED_LIBS clangBasic)
|
||||
|
||||
add_clang_library(clangAST
|
||||
APValue.cpp
|
||||
ASTConsumer.cpp
|
||||
|
@ -42,16 +44,5 @@ add_clang_library(clangAST
|
|||
TypePrinter.cpp
|
||||
)
|
||||
|
||||
target_link_libraries(clangAST
|
||||
clangBasic
|
||||
)
|
||||
|
||||
add_dependencies(clangAST
|
||||
ClangARMNeon
|
||||
ClangAttrClasses
|
||||
ClangAttrList
|
||||
ClangAttrImpl
|
||||
ClangDiagnosticAST
|
||||
ClangDeclNodes
|
||||
ClangStmtNodes
|
||||
)
|
||||
add_dependencies(clangAST ClangARMNeon ClangAttrClasses ClangAttrList
|
||||
ClangAttrImpl ClangDiagnosticAST ClangDeclNodes ClangStmtNodes)
|
||||
|
|
|
@ -1,5 +1,7 @@
|
|||
set(LLVM_NO_RTTI 1)
|
||||
|
||||
set(LLVM_USED_LIBS clangBasic clangAST clangIndex)
|
||||
|
||||
add_clang_library(clangAnalysis
|
||||
AnalysisContext.cpp
|
||||
CFG.cpp
|
||||
|
@ -13,16 +15,5 @@ add_clang_library(clangAnalysis
|
|||
UninitializedValues.cpp
|
||||
)
|
||||
|
||||
target_link_libraries(clangAnalysis
|
||||
clangBasic
|
||||
clangAST
|
||||
clangIndex
|
||||
)
|
||||
|
||||
add_dependencies(clangAnalysis
|
||||
ClangAttrClasses
|
||||
ClangAttrList
|
||||
ClangDiagnosticAnalysis
|
||||
ClangDeclNodes
|
||||
ClangStmtNodes
|
||||
)
|
||||
add_dependencies(clangAnalysis ClangAttrClasses ClangAttrList
|
||||
ClangDiagnosticAnalysis ClangDeclNodes ClangStmtNodes)
|
||||
|
|
|
@ -14,10 +14,6 @@ add_clang_library(clangBasic
|
|||
Version.cpp
|
||||
)
|
||||
|
||||
target_link_libraries(clangBasic
|
||||
LLVMMC
|
||||
)
|
||||
|
||||
# Determine Subversion revision.
|
||||
# FIXME: This only gets updated when CMake is run, so this revision number
|
||||
# may be out-of-date!
|
||||
|
@ -29,16 +25,15 @@ if (Subversion_FOUND AND EXISTS "${CLANG_SOURCE_DIR}/.svn")
|
|||
endif()
|
||||
|
||||
add_dependencies(clangBasic
|
||||
ClangARMNeon
|
||||
ClangAttrList
|
||||
ClangDiagnosticAnalysis
|
||||
ClangDiagnosticAST
|
||||
ClangDiagnosticCommon
|
||||
ClangDiagnosticDriver
|
||||
ClangDiagnosticFrontend
|
||||
ClangDiagnosticGroups
|
||||
ClangDiagnosticLex
|
||||
ClangDiagnosticParse
|
||||
ClangDiagnosticSema
|
||||
)
|
||||
ClangARMNeon
|
||||
ClangAttrList
|
||||
ClangDiagnosticAnalysis
|
||||
ClangDiagnosticAST
|
||||
ClangDiagnosticCommon
|
||||
ClangDiagnosticDriver
|
||||
ClangDiagnosticFrontend
|
||||
ClangDiagnosticGroups
|
||||
ClangDiagnosticLex
|
||||
ClangDiagnosticParse
|
||||
ClangDiagnosticSema)
|
||||
|
||||
|
|
|
@ -1,5 +1,7 @@
|
|||
set(LLVM_NO_RTTI 1)
|
||||
|
||||
set(LLVM_USED_LIBS clangBasic clangLex clangAST clangFrontend clangRewrite)
|
||||
|
||||
add_clang_library(clangChecker
|
||||
AdjustedReturnValueChecker.cpp
|
||||
AggExprVisitor.cpp
|
||||
|
@ -82,17 +84,5 @@ add_clang_library(clangChecker
|
|||
ValueManager.cpp
|
||||
)
|
||||
|
||||
target_link_libraries(clangChecker
|
||||
clangBasic
|
||||
clangLex
|
||||
clangAST
|
||||
clangFrontend
|
||||
clangRewrite
|
||||
)
|
||||
|
||||
add_dependencies(clangChecker
|
||||
ClangAttrClasses
|
||||
ClangAttrList
|
||||
ClangDeclNodes
|
||||
ClangStmtNodes
|
||||
)
|
||||
add_dependencies(clangChecker ClangAttrClasses ClangAttrList ClangDeclNodes
|
||||
ClangStmtNodes)
|
||||
|
|
|
@ -1,5 +1,7 @@
|
|||
set(LLVM_NO_RTTI 1)
|
||||
|
||||
set(LLVM_USED_LIBS clangBasic clangAST clangFrontend)
|
||||
|
||||
add_clang_library(clangCodeGen
|
||||
BackendUtil.cpp
|
||||
CGBlocks.cpp
|
||||
|
@ -37,19 +39,5 @@ add_clang_library(clangCodeGen
|
|||
TargetInfo.cpp
|
||||
)
|
||||
|
||||
target_link_libraries(clangCodeGen
|
||||
LLVMCore
|
||||
LLVMAsmParser
|
||||
LLVMBitReader
|
||||
LLVMBitWriter
|
||||
LLVMipo
|
||||
)
|
||||
|
||||
add_dependencies(clangCodeGen
|
||||
ClangARMNeon
|
||||
ClangAttrClasses
|
||||
ClangAttrList
|
||||
ClangDeclNodes
|
||||
ClangStmtNodes
|
||||
ClangDiagnosticFrontend
|
||||
)
|
||||
add_dependencies(clangCodeGen ClangAttrClasses ClangAttrList ClangDeclNodes
|
||||
ClangStmtNodes)
|
||||
|
|
|
@ -1,5 +1,7 @@
|
|||
set(LLVM_NO_RTTI 1)
|
||||
|
||||
set(LLVM_USED_LIBS clangBasic clangAST clangParse)
|
||||
|
||||
add_clang_library(clangDriver
|
||||
Action.cpp
|
||||
Arg.cpp
|
||||
|
@ -21,16 +23,5 @@ add_clang_library(clangDriver
|
|||
Types.cpp
|
||||
)
|
||||
|
||||
target_link_libraries(clangDriver
|
||||
clangBasic
|
||||
clangAST
|
||||
clangParse
|
||||
)
|
||||
|
||||
add_dependencies(clangDriver
|
||||
ClangAttrList
|
||||
ClangDiagnosticDriver
|
||||
ClangDriverOptions
|
||||
ClangCC1Options
|
||||
ClangCC1AsOptions
|
||||
)
|
||||
add_dependencies(clangDriver ClangAttrList ClangDiagnosticDriver
|
||||
ClangDriverOptions ClangCC1Options ClangCC1AsOptions)
|
||||
|
|
|
@ -1,5 +1,14 @@
|
|||
set(LLVM_NO_RTTI 1)
|
||||
|
||||
set( LLVM_USED_LIBS
|
||||
clangDriver
|
||||
clangParse
|
||||
clangSema
|
||||
clangAST
|
||||
clangLex
|
||||
clangBasic
|
||||
)
|
||||
|
||||
add_clang_library(clangFrontend
|
||||
ASTConsumers.cpp
|
||||
ASTMerge.cpp
|
||||
|
@ -27,17 +36,6 @@ add_clang_library(clangFrontend
|
|||
Warnings.cpp
|
||||
)
|
||||
|
||||
target_link_libraries(clangFrontend
|
||||
LLVMCore
|
||||
|
||||
clangDriver
|
||||
clangParse
|
||||
clangSema
|
||||
clangAST
|
||||
clangLex
|
||||
clangBasic
|
||||
)
|
||||
|
||||
IF(MSVC)
|
||||
get_target_property(NON_ANSI_COMPILE_FLAGS clangFrontend COMPILE_FLAGS)
|
||||
string(REPLACE /Za
|
||||
|
@ -54,5 +52,4 @@ add_dependencies(clangFrontend
|
|||
ClangDiagnosticLex
|
||||
ClangDiagnosticSema
|
||||
ClangDeclNodes
|
||||
ClangStmtNodes
|
||||
)
|
||||
ClangStmtNodes)
|
||||
|
|
|
@ -1,13 +1,8 @@
|
|||
set(LLVM_NO_RTTI 1)
|
||||
|
||||
set(LLVM_USED_LIBS clangDriver clangFrontend clangRewrite clangCodeGen
|
||||
clangChecker)
|
||||
|
||||
add_clang_library(clangFrontendTool
|
||||
ExecuteCompilerInvocation.cpp
|
||||
)
|
||||
|
||||
target_link_libraries(clangFrontendTool
|
||||
clangDriver
|
||||
clangFrontend
|
||||
clangRewrite
|
||||
clangCodeGen
|
||||
clangChecker
|
||||
)
|
||||
|
|
|
@ -1,5 +1,21 @@
|
|||
set(LLVM_NO_RTTI 1)
|
||||
|
||||
set(LLVM_USED_LIBS clangBasic clangLex clangAST)
|
||||
|
||||
set( LLVM_USED_LIBS
|
||||
clangSerialization
|
||||
clangFrontend
|
||||
clangParse
|
||||
clangSema
|
||||
clangChecker
|
||||
clangAnalysis
|
||||
clangIndex
|
||||
clangRewrite
|
||||
clangAST
|
||||
clangLex
|
||||
clangBasic
|
||||
)
|
||||
|
||||
add_clang_library(clangIndex
|
||||
ASTLocation.cpp
|
||||
Analyzer.cpp
|
||||
|
@ -14,23 +30,5 @@ add_clang_library(clangIndex
|
|||
SelectorMap.cpp
|
||||
)
|
||||
|
||||
target_link_libraries(clangIndex
|
||||
clangSerialization
|
||||
clangFrontend
|
||||
clangParse
|
||||
clangSema
|
||||
clangChecker
|
||||
clangAnalysis
|
||||
clangIndex
|
||||
clangRewrite
|
||||
clangAST
|
||||
clangLex
|
||||
clangBasic
|
||||
)
|
||||
|
||||
add_dependencies(clangIndex
|
||||
ClangAttrClasses
|
||||
ClangAttrList
|
||||
ClangDeclNodes
|
||||
ClangStmtNodes
|
||||
)
|
||||
add_dependencies(clangIndex ClangAttrClasses ClangAttrList
|
||||
ClangDeclNodes ClangStmtNodes)
|
||||
|
|
|
@ -2,6 +2,8 @@ set(LLVM_NO_RTTI 1)
|
|||
|
||||
# TODO: Add -maltivec when ARCH is PowerPC.
|
||||
|
||||
set(LLVM_USED_LIBS clangBasic)
|
||||
|
||||
add_clang_library(clangLex
|
||||
HeaderMap.cpp
|
||||
HeaderSearch.cpp
|
||||
|
@ -24,10 +26,4 @@ add_clang_library(clangLex
|
|||
TokenLexer.cpp
|
||||
)
|
||||
|
||||
target_link_libraries(clangLex
|
||||
clangBasic
|
||||
)
|
||||
|
||||
add_dependencies(clangLex
|
||||
ClangDiagnosticLex
|
||||
)
|
||||
add_dependencies(clangLex ClangDiagnosticLex)
|
||||
|
|
|
@ -1,5 +1,7 @@
|
|||
set(LLVM_NO_RTTI 1)
|
||||
|
||||
set(LLVM_USED_LIBS clangBasic clangAST clangLex clangSema)
|
||||
|
||||
add_clang_library(clangParse
|
||||
ParseAST.cpp
|
||||
ParseCXXInlineMethods.cpp
|
||||
|
@ -16,17 +18,4 @@ add_clang_library(clangParse
|
|||
Parser.cpp
|
||||
)
|
||||
|
||||
target_link_libraries(clangParse
|
||||
clangBasic
|
||||
clangAST
|
||||
clangLex
|
||||
clangSema
|
||||
)
|
||||
|
||||
add_dependencies(clangParse
|
||||
ClangAttrClasses
|
||||
ClangAttrList
|
||||
ClangDeclNodes
|
||||
ClangDiagnosticParse
|
||||
ClangStmtNodes
|
||||
)
|
||||
add_dependencies(clangParse ClangAttrClasses ClangAttrList ClangDeclNodes ClangDiagnosticParse ClangStmtNodes)
|
||||
|
|
|
@ -1,5 +1,7 @@
|
|||
set(LLVM_NO_RTTI 1)
|
||||
|
||||
set(LLVM_USED_LIBS clangBasic clangAST clangParse clangFrontend)
|
||||
|
||||
add_clang_library(clangRewrite
|
||||
DeltaTree.cpp
|
||||
FixItRewriter.cpp
|
||||
|
@ -14,16 +16,8 @@ add_clang_library(clangRewrite
|
|||
TokenRewriter.cpp
|
||||
)
|
||||
|
||||
target_link_libraries(clangRewrite
|
||||
clangBasic
|
||||
clangAST
|
||||
clangParse
|
||||
clangFrontend
|
||||
)
|
||||
|
||||
add_dependencies(clangRewrite
|
||||
ClangAttrClasses
|
||||
ClangAttrList
|
||||
ClangDeclNodes
|
||||
ClangStmtNodes
|
||||
)
|
||||
ClangStmtNodes)
|
||||
|
|
|
@ -1,5 +1,7 @@
|
|||
set(LLVM_NO_RTTI 1)
|
||||
|
||||
set(LLVM_USED_LIBS clangBasic clangAST clangLex clangAnalysis)
|
||||
|
||||
add_clang_library(clangSema
|
||||
AnalysisBasedWarnings.cpp
|
||||
AttributeList.cpp
|
||||
|
@ -35,15 +37,5 @@ add_clang_library(clangSema
|
|||
TargetAttributesSema.cpp
|
||||
)
|
||||
|
||||
target_link_libraries(clangSema
|
||||
clangAnalysis
|
||||
)
|
||||
|
||||
add_dependencies(clangSema
|
||||
ClangARMNeon
|
||||
ClangAttrClasses
|
||||
ClangAttrList
|
||||
ClangDiagnosticSema
|
||||
ClangDeclNodes
|
||||
ClangStmtNodes
|
||||
)
|
||||
add_dependencies(clangSema ClangARMNeon ClangAttrClasses ClangAttrList
|
||||
ClangDiagnosticSema ClangDeclNodes ClangStmtNodes)
|
||||
|
|
|
@ -1,5 +1,7 @@
|
|||
set(LLVM_NO_RTTI 1)
|
||||
|
||||
set(LLVM_USED_LIBS clangFrontend)
|
||||
|
||||
add_clang_library(clangSerialization
|
||||
GeneratePCH.cpp
|
||||
ASTCommon.cpp
|
||||
|
@ -11,10 +13,6 @@ add_clang_library(clangSerialization
|
|||
ASTWriterStmt.cpp
|
||||
)
|
||||
|
||||
target_link_libraries(clangSerialization
|
||||
clangFrontend
|
||||
)
|
||||
|
||||
add_dependencies(clangSerialization
|
||||
ClangAttrClasses
|
||||
ClangAttrList
|
||||
|
@ -24,5 +22,4 @@ add_dependencies(clangSerialization
|
|||
ClangDiagnosticLex
|
||||
ClangDiagnosticSema
|
||||
ClangDeclNodes
|
||||
ClangStmtNodes
|
||||
)
|
||||
ClangStmtNodes)
|
||||
|
|
|
@ -1,13 +1,17 @@
|
|||
set(LLVM_NO_RTTI 1)
|
||||
|
||||
set(LLVM_USED_LIBS libclang)
|
||||
|
||||
set( LLVM_LINK_COMPONENTS
|
||||
bitreader
|
||||
mc
|
||||
core
|
||||
)
|
||||
|
||||
add_clang_executable(c-index-test
|
||||
c-index-test.c
|
||||
)
|
||||
|
||||
target_link_libraries(c-index-test
|
||||
libclang
|
||||
)
|
||||
|
||||
set_target_properties(c-index-test
|
||||
PROPERTIES
|
||||
LINKER_LANGUAGE CXX)
|
||||
|
|
|
@ -1,20 +1,6 @@
|
|||
set(LLVM_NO_RTTI 1)
|
||||
|
||||
add_clang_executable(clang
|
||||
driver.cpp
|
||||
cc1_main.cpp
|
||||
cc1as_main.cpp
|
||||
)
|
||||
|
||||
add_llvm_link_components(clang all)
|
||||
target_link_libraries(clang
|
||||
LLVMAsmParser
|
||||
LLVMBitReader
|
||||
LLVMBitWriter
|
||||
LLVMCodeGen
|
||||
LLVMipo
|
||||
LLVMSelectionDAG
|
||||
|
||||
set( LLVM_USED_LIBS
|
||||
clangFrontendTool
|
||||
clangFrontend
|
||||
clangDriver
|
||||
|
@ -31,6 +17,22 @@ target_link_libraries(clang
|
|||
clangBasic
|
||||
)
|
||||
|
||||
set( LLVM_LINK_COMPONENTS
|
||||
${LLVM_TARGETS_TO_BUILD}
|
||||
asmparser
|
||||
bitreader
|
||||
bitwriter
|
||||
codegen
|
||||
ipo
|
||||
selectiondag
|
||||
)
|
||||
|
||||
add_clang_executable(clang
|
||||
driver.cpp
|
||||
cc1_main.cpp
|
||||
cc1as_main.cpp
|
||||
)
|
||||
|
||||
if(UNIX)
|
||||
set(CLANGXX_LINK_OR_COPY create_symlink)
|
||||
set(CLANGXX_DESTDIR $ENV{DESTDIR}/)
|
||||
|
|
|
@ -2,6 +2,22 @@ set(SHARED_LIBRARY TRUE)
|
|||
|
||||
set(LLVM_NO_RTTI 1)
|
||||
|
||||
set(LLVM_USED_LIBS
|
||||
clangFrontend
|
||||
clangDriver
|
||||
clangSerialization
|
||||
clangIndex
|
||||
clangSema
|
||||
clangAST
|
||||
clangLex
|
||||
clangBasic)
|
||||
|
||||
set( LLVM_LINK_COMPONENTS
|
||||
bitreader
|
||||
mc
|
||||
core
|
||||
)
|
||||
|
||||
add_clang_library(libclang
|
||||
CIndex.cpp
|
||||
CIndexCXX.cpp
|
||||
|
@ -13,22 +29,7 @@ add_clang_library(libclang
|
|||
CXCursor.cpp
|
||||
CXType.cpp
|
||||
../../include/clang-c/Index.h
|
||||
)
|
||||
|
||||
target_link_libraries(libclang
|
||||
LLVMBitReader
|
||||
LLVMMC
|
||||
LLVMCore
|
||||
|
||||
clangFrontend
|
||||
clangDriver
|
||||
clangSerialization
|
||||
clangIndex
|
||||
clangSema
|
||||
clangAST
|
||||
clangLex
|
||||
clangBasic
|
||||
)
|
||||
)
|
||||
|
||||
if(${CMAKE_SYSTEM_NAME} MATCHES "Darwin")
|
||||
# dylib versioning information
|
||||
|
|
Загрузка…
Ссылка в новой задаче