aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xcmake/modules/AddLLVM.cmake8
-rw-r--r--cmake/modules/CMakeLists.txt2
-rwxr-xr-xcmake/modules/LLVM-Config.cmake28
-rw-r--r--cmake/modules/LLVMLibDeps.cmake83
-rw-r--r--lib/Analysis/CMakeLists.txt6
-rw-r--r--lib/Analysis/IPA/CMakeLists.txt6
-rw-r--r--lib/Archive/CMakeLists.txt6
-rw-r--r--lib/AsmParser/CMakeLists.txt5
-rw-r--r--lib/Bitcode/Reader/CMakeLists.txt5
-rw-r--r--lib/Bitcode/Writer/CMakeLists.txt5
-rw-r--r--lib/CodeGen/AsmPrinter/CMakeLists.txt9
-rw-r--r--lib/CodeGen/CMakeLists.txt10
-rw-r--r--lib/CodeGen/SelectionDAG/CMakeLists.txt10
-rw-r--r--lib/ExecutionEngine/CMakeLists.txt7
-rw-r--r--lib/ExecutionEngine/Interpreter/CMakeLists.txt8
-rw-r--r--lib/ExecutionEngine/JIT/CMakeLists.txt8
-rw-r--r--lib/ExecutionEngine/MCJIT/CMakeLists.txt8
-rw-r--r--lib/ExecutionEngine/RuntimeDyld/CMakeLists.txt5
-rw-r--r--lib/Linker/CMakeLists.txt8
-rw-r--r--lib/MC/CMakeLists.txt5
-rw-r--r--lib/MC/MCDisassembler/CMakeLists.txt42
-rw-r--r--lib/MC/MCParser/CMakeLists.txt5
-rw-r--r--lib/Object/CMakeLists.txt5
-rw-r--r--lib/Target/ARM/AsmParser/CMakeLists.txt9
-rw-r--r--lib/Target/ARM/CMakeLists.txt14
-rw-r--r--lib/Target/ARM/Disassembler/CMakeLists.txt8
-rw-r--r--lib/Target/ARM/InstPrinter/CMakeLists.txt6
-rw-r--r--lib/Target/ARM/MCTargetDesc/CMakeLists.txt7
-rw-r--r--lib/Target/ARM/TargetInfo/CMakeLists.txt6
-rw-r--r--lib/Target/Alpha/CMakeLists.txt12
-rw-r--r--lib/Target/Alpha/MCTargetDesc/CMakeLists.txt6
-rw-r--r--lib/Target/Alpha/TargetInfo/CMakeLists.txt7
-rw-r--r--lib/Target/Blackfin/CMakeLists.txt12
-rw-r--r--lib/Target/Blackfin/MCTargetDesc/CMakeLists.txt6
-rw-r--r--lib/Target/Blackfin/TargetInfo/CMakeLists.txt6
-rw-r--r--lib/Target/CBackend/CMakeLists.txt12
-rw-r--r--lib/Target/CBackend/TargetInfo/CMakeLists.txt5
-rw-r--r--lib/Target/CMakeLists.txt6
-rw-r--r--lib/Target/CellSPU/CMakeLists.txt12
-rw-r--r--lib/Target/CellSPU/MCTargetDesc/CMakeLists.txt6
-rw-r--r--lib/Target/CellSPU/TargetInfo/CMakeLists.txt6
-rw-r--r--lib/Target/CppBackend/CMakeLists.txt7
-rw-r--r--lib/Target/CppBackend/TargetInfo/CMakeLists.txt4
-rw-r--r--lib/Target/MBlaze/AsmParser/CMakeLists.txt9
-rw-r--r--lib/Target/MBlaze/CMakeLists.txt13
-rw-r--r--lib/Target/MBlaze/Disassembler/CMakeLists.txt8
-rw-r--r--lib/Target/MBlaze/InstPrinter/CMakeLists.txt7
-rw-r--r--lib/Target/MBlaze/MCTargetDesc/CMakeLists.txt10
-rw-r--r--lib/Target/MBlaze/TargetInfo/CMakeLists.txt6
-rw-r--r--lib/Target/MSP430/CMakeLists.txt13
-rw-r--r--lib/Target/MSP430/InstPrinter/CMakeLists.txt6
-rw-r--r--lib/Target/MSP430/MCTargetDesc/CMakeLists.txt9
-rw-r--r--lib/Target/MSP430/TargetInfo/CMakeLists.txt6
-rw-r--r--lib/Target/Mips/CMakeLists.txt13
-rw-r--r--lib/Target/Mips/InstPrinter/CMakeLists.txt6
-rw-r--r--lib/Target/Mips/MCTargetDesc/CMakeLists.txt10
-rw-r--r--lib/Target/Mips/TargetInfo/CMakeLists.txt6
-rw-r--r--lib/Target/PTX/CMakeLists.txt13
-rw-r--r--lib/Target/PTX/MCTargetDesc/CMakeLists.txt7
-rw-r--r--lib/Target/PTX/TargetInfo/CMakeLists.txt6
-rw-r--r--lib/Target/PowerPC/CMakeLists.txt14
-rw-r--r--lib/Target/PowerPC/InstPrinter/CMakeLists.txt6
-rw-r--r--lib/Target/PowerPC/MCTargetDesc/CMakeLists.txt10
-rw-r--r--lib/Target/PowerPC/TargetInfo/CMakeLists.txt6
-rw-r--r--lib/Target/Sparc/CMakeLists.txt12
-rw-r--r--lib/Target/Sparc/MCTargetDesc/CMakeLists.txt7
-rw-r--r--lib/Target/Sparc/TargetInfo/CMakeLists.txt6
-rw-r--r--lib/Target/SystemZ/CMakeLists.txt12
-rw-r--r--lib/Target/SystemZ/MCTargetDesc/CMakeLists.txt6
-rw-r--r--lib/Target/SystemZ/TargetInfo/CMakeLists.txt6
-rw-r--r--lib/Target/X86/AsmParser/CMakeLists.txt9
-rw-r--r--lib/Target/X86/CMakeLists.txt13
-rw-r--r--lib/Target/X86/Disassembler/CMakeLists.txt8
-rw-r--r--lib/Target/X86/InstPrinter/CMakeLists.txt7
-rw-r--r--lib/Target/X86/MCTargetDesc/CMakeLists.txt11
-rw-r--r--lib/Target/X86/TargetInfo/CMakeLists.txt6
-rw-r--r--lib/Target/X86/Utils/CMakeLists.txt6
-rw-r--r--lib/Target/XCore/CMakeLists.txt12
-rw-r--r--lib/Target/XCore/MCTargetDesc/CMakeLists.txt6
-rw-r--r--lib/Target/XCore/TargetInfo/CMakeLists.txt6
-rw-r--r--lib/Transforms/IPO/CMakeLists.txt10
-rw-r--r--lib/Transforms/InstCombine/CMakeLists.txt8
-rw-r--r--lib/Transforms/Instrumentation/CMakeLists.txt7
-rw-r--r--lib/Transforms/Scalar/CMakeLists.txt9
-rw-r--r--lib/Transforms/Utils/CMakeLists.txt7
-rw-r--r--lib/VMCore/CMakeLists.txt2
-rw-r--r--tools/llvm-config/CMakeLists.txt24
87 files changed, 675 insertions, 150 deletions
diff --git a/cmake/modules/AddLLVM.cmake b/cmake/modules/AddLLVM.cmake
index 5e3a4c1c43..cf9ea72107 100755
--- a/cmake/modules/AddLLVM.cmake
+++ b/cmake/modules/AddLLVM.cmake
@@ -34,6 +34,14 @@ macro(add_llvm_library name)
set_target_properties(${name} PROPERTIES FOLDER "Libraries")
endmacro(add_llvm_library name)
+macro(add_llvm_library_dependencies name)
+ # Save the dependencies of the LLVM library in a variable so that we can
+ # query it when resolve llvm-config-style component -> library mappings.
+ set(LLVM_LIB_DEPS_${name} ${ARGN})
+
+ # Then add the actual dependencies to the library target.
+ target_link_libraries(${name} ${ARGN})
+endmacro(add_llvm_library_dependencies name)
macro(add_llvm_loadable_module name)
if( NOT LLVM_ON_UNIX OR CYGWIN )
diff --git a/cmake/modules/CMakeLists.txt b/cmake/modules/CMakeLists.txt
index 257deb6d4c..298da95d1e 100644
--- a/cmake/modules/CMakeLists.txt
+++ b/cmake/modules/CMakeLists.txt
@@ -17,7 +17,6 @@ install(FILES
${llvm_cmake_builddir}/LLVMConfig.cmake
${llvm_cmake_builddir}/LLVMConfigVersion.cmake
LLVM-Config.cmake
- LLVMLibDeps.cmake
DESTINATION share/llvm/cmake)
install(DIRECTORY .
@@ -27,7 +26,6 @@ install(DIRECTORY .
PATTERN LLVMConfig.cmake EXCLUDE
PATTERN LLVMConfigVersion.cmake EXCLUDE
PATTERN LLVM-Config.cmake EXCLUDE
- PATTERN LLVMLibDeps.cmake EXCLUDE
PATTERN FindBison.cmake EXCLUDE
PATTERN GetTargetTriple.cmake EXCLUDE
PATTERN VersionFromVCS.cmake EXCLUDE
diff --git a/cmake/modules/LLVM-Config.cmake b/cmake/modules/LLVM-Config.cmake
index a6286fee68..d6b31245b0 100755
--- a/cmake/modules/LLVM-Config.cmake
+++ b/cmake/modules/LLVM-Config.cmake
@@ -152,7 +152,7 @@ function(explicit_map_components_to_libraries out_libs)
set(processed)
while( cursor LESS lst_size )
list(GET expanded_components ${cursor} lib)
- list(APPEND expanded_components ${MSVC_LIB_DEPS_${lib}})
+ list(APPEND expanded_components ${LLVM_LIB_DEPS_${lib}})
# Remove duplicates at the front:
list(REVERSE expanded_components)
list(REMOVE_DUPLICATES expanded_components)
@@ -175,29 +175,3 @@ function(explicit_map_components_to_libraries out_libs)
endforeach(c)
set(${out_libs} ${result} PARENT_SCOPE)
endfunction(explicit_map_components_to_libraries)
-
-
-# The library dependency data is contained in the file
-# LLVMLibDeps.cmake on this directory. It is automatically generated
-# by tools/llvm-config/CMakeLists.txt when the build comprises all the
-# targets and we are on a environment Posix enough to build the
-# llvm-config script. This, in practice, just excludes MSVC.
-
-# When you remove or rename a library from the build, be sure to
-# remove its file from lib/ as well, or the GenLibDeps.pl script will
-# include it on its analysis!
-
-# The format generated by GenLibDeps.pl
-
-# LLVMARMAsmPrinter.o: LLVMARMCodeGen.o libLLVMAsmPrinter.a libLLVMCodeGen.a libLLVMCore.a libLLVMSupport.a libLLVMTarget.a
-
-# is translated to:
-
-# set(MSVC_LIB_DEPS_LLVMARMAsmPrinter LLVMARMCodeGen LLVMAsmPrinter LLVMCodeGen LLVMCore LLVMSupport LLVMTarget)
-
-# It is necessary to remove the `lib' prefix and the `.a'.
-
-# This 'sed' script should do the trick:
-# sed -e s'#\.a##g' -e 's#libLLVM#LLVM#g' -e 's#: # #' -e 's#\(.*\)#set(MSVC_LIB_DEPS_\1)#' ~/llvm/tools/llvm-config/LibDeps.txt
-
-include(LLVMLibDeps)
diff --git a/cmake/modules/LLVMLibDeps.cmake b/cmake/modules/LLVMLibDeps.cmake
deleted file mode 100644
index 4aded2cf58..0000000000
--- a/cmake/modules/LLVMLibDeps.cmake
+++ /dev/null
@@ -1,83 +0,0 @@
-set(MSVC_LIB_DEPS_LLVMARMAsmParser LLVMARMDesc LLVMARMInfo LLVMMC LLVMMCParser LLVMSupport)
-set(MSVC_LIB_DEPS_LLVMARMAsmPrinter LLVMMC LLVMSupport)
-set(MSVC_LIB_DEPS_LLVMARMCodeGen LLVMARMAsmPrinter LLVMARMDesc LLVMARMInfo LLVMAnalysis LLVMAsmPrinter LLVMCodeGen LLVMCore LLVMMC LLVMSelectionDAG LLVMSupport LLVMTarget)
-set(MSVC_LIB_DEPS_LLVMARMDesc LLVMARMInfo LLVMMC LLVMSupport)
-set(MSVC_LIB_DEPS_LLVMARMDisassembler LLVMARMDesc LLVMARMInfo LLVMMC LLVMSupport)
-set(MSVC_LIB_DEPS_LLVMARMInfo LLVMMC LLVMSupport LLVMTarget)
-set(MSVC_LIB_DEPS_LLVMAlphaCodeGen LLVMAlphaDesc LLVMAlphaInfo LLVMAsmPrinter LLVMCodeGen LLVMCore LLVMMC LLVMSelectionDAG LLVMSupport LLVMTarget)
-set(MSVC_LIB_DEPS_LLVMAlphaDesc LLVMAlphaInfo LLVMMC)
-set(MSVC_LIB_DEPS_LLVMAlphaInfo LLVMMC LLVMSupport LLVMTarget)
-set(MSVC_LIB_DEPS_LLVMAnalysis LLVMCore LLVMSupport LLVMTarget)
-set(MSVC_LIB_DEPS_LLVMArchive LLVMBitReader LLVMCore LLVMSupport)
-set(MSVC_LIB_DEPS_LLVMAsmParser LLVMCore LLVMSupport)
-set(MSVC_LIB_DEPS_LLVMAsmPrinter LLVMAnalysis LLVMCodeGen LLVMCore LLVMMC LLVMMCParser LLVMSupport LLVMTarget)
-set(MSVC_LIB_DEPS_LLVMBitReader LLVMCore LLVMSupport)
-set(MSVC_LIB_DEPS_LLVMBitWriter LLVMCore LLVMSupport)
-set(MSVC_LIB_DEPS_LLVMBlackfinCodeGen LLVMAsmPrinter LLVMBlackfinDesc LLVMBlackfinInfo LLVMCodeGen LLVMCore LLVMMC LLVMSelectionDAG LLVMSupport LLVMTarget)
-set(MSVC_LIB_DEPS_LLVMBlackfinDesc LLVMBlackfinInfo LLVMMC)
-set(MSVC_LIB_DEPS_LLVMBlackfinInfo LLVMMC LLVMSupport LLVMTarget)
-set(MSVC_LIB_DEPS_LLVMCBackend LLVMAnalysis LLVMCBackendInfo LLVMCodeGen LLVMCore LLVMMC LLVMScalarOpts LLVMSupport LLVMTarget LLVMTransformUtils)
-set(MSVC_LIB_DEPS_LLVMCBackendInfo LLVMMC LLVMSupport LLVMTarget)
-set(MSVC_LIB_DEPS_LLVMCellSPUCodeGen LLVMAsmPrinter LLVMCellSPUDesc LLVMCellSPUInfo LLVMCodeGen LLVMCore LLVMMC LLVMSelectionDAG LLVMSupport LLVMTarget)
-set(MSVC_LIB_DEPS_LLVMCellSPUDesc LLVMCellSPUInfo LLVMMC)
-set(MSVC_LIB_DEPS_LLVMCellSPUInfo LLVMMC LLVMSupport LLVMTarget)
-set(MSVC_LIB_DEPS_LLVMCodeGen LLVMAnalysis LLVMCore LLVMMC LLVMScalarOpts LLVMSupport LLVMTarget LLVMTransformUtils)
-set(MSVC_LIB_DEPS_LLVMCore LLVMSupport)
-set(MSVC_LIB_DEPS_LLVMCppBackend LLVMCore LLVMCppBackendInfo LLVMSupport LLVMTarget)
-set(MSVC_LIB_DEPS_LLVMCppBackendInfo LLVMMC LLVMTarget)
-set(MSVC_LIB_DEPS_LLVMExecutionEngine LLVMCore LLVMMC LLVMSupport LLVMTarget)
-set(MSVC_LIB_DEPS_LLVMInstCombine LLVMAnalysis LLVMCore LLVMSupport LLVMTarget LLVMTransformUtils)
-set(MSVC_LIB_DEPS_LLVMInstrumentation LLVMAnalysis LLVMCore LLVMSupport LLVMTransformUtils)
-set(MSVC_LIB_DEPS_LLVMInterpreter LLVMCodeGen LLVMCore LLVMExecutionEngine LLVMSupport LLVMTarget)
-set(MSVC_LIB_DEPS_LLVMJIT LLVMCodeGen LLVMCore LLVMExecutionEngine LLVMMC LLVMSupport LLVMTarget)
-set(MSVC_LIB_DEPS_LLVMLinker LLVMArchive LLVMBitReader LLVMCore LLVMSupport LLVMTransformUtils)
-set(MSVC_LIB_DEPS_LLVMMBlazeAsmParser LLVMMBlazeInfo LLVMMC LLVMMCParser LLVMSupport)
-set(MSVC_LIB_DEPS_LLVMMBlazeAsmPrinter LLVMMC LLVMSupport)
-set(MSVC_LIB_DEPS_LLVMMBlazeCodeGen LLVMAsmPrinter LLVMCodeGen LLVMCore LLVMMBlazeAsmPrinter LLVMMBlazeDesc LLVMMBlazeInfo LLVMMC LLVMSelectionDAG LLVMSupport LLVMTarget)
-set(MSVC_LIB_DEPS_LLVMMBlazeDesc LLVMMBlazeInfo LLVMMC LLVMSupport)
-set(MSVC_LIB_DEPS_LLVMMBlazeDisassembler LLVMMBlazeDesc LLVMMBlazeInfo LLVMMC LLVMSupport)
-set(MSVC_LIB_DEPS_LLVMMBlazeInfo LLVMMC LLVMSupport LLVMTarget)
-set(MSVC_LIB_DEPS_LLVMMC LLVMSupport)
-set(MSVC_LIB_DEPS_LLVMMCDisassembler LLVMARMAsmParser LLVMARMDesc LLVMARMDisassembler LLVMARMInfo LLVMAlphaDesc LLVMAlphaInfo LLVMBlackfinDesc LLVMBlackfinInfo LLVMCBackendInfo LLVMCellSPUDesc LLVMCellSPUInfo LLVMCppBackendInfo LLVMMBlazeAsmParser LLVMMBlazeDesc LLVMMBlazeDisassembler LLVMMBlazeInfo LLVMMC LLVMMCParser LLVMMSP430Desc LLVMMSP430Info LLVMMipsDesc LLVMMipsInfo LLVMPTXDesc LLVMPTXInfo LLVMPowerPCDesc LLVMPowerPCInfo LLVMSparcDesc LLVMSparcInfo LLVMSupport LLVMSystemZDesc LLVMSystemZInfo LLVMTarget LLVMX86AsmParser LLVMX86Desc LLVMX86Disassembler LLVMX86Info LLVMXCoreDesc LLVMXCoreInfo)
-set(MSVC_LIB_DEPS_LLVMMCJIT LLVMCore LLVMExecutionEngine LLVMRuntimeDyld LLVMSupport LLVMTarget)
-set(MSVC_LIB_DEPS_LLVMMCParser LLVMMC LLVMSupport)
-set(MSVC_LIB_DEPS_LLVMMSP430AsmPrinter LLVMMC LLVMSupport)
-set(MSVC_LIB_DEPS_LLVMMSP430CodeGen LLVMAsmPrinter LLVMCodeGen LLVMCore LLVMMC LLVMMSP430AsmPrinter LLVMMSP430Desc LLVMMSP430Info LLVMSelectionDAG LLVMSupport LLVMTarget)
-set(MSVC_LIB_DEPS_LLVMMSP430Desc LLVMMC LLVMMSP430Info)
-set(MSVC_LIB_DEPS_LLVMMSP430Info LLVMMC LLVMSupport LLVMTarget)
-set(MSVC_LIB_DEPS_LLVMMipsAsmPrinter LLVMMC LLVMSupport)
-set(MSVC_LIB_DEPS_LLVMMipsCodeGen LLVMAsmPrinter LLVMCodeGen LLVMCore LLVMMC LLVMMipsAsmPrinter LLVMMipsDesc LLVMMipsInfo LLVMSelectionDAG LLVMSupport LLVMTarget)
-set(MSVC_LIB_DEPS_LLVMMipsDesc LLVMMC LLVMMipsInfo LLVMSupport)
-set(MSVC_LIB_DEPS_LLVMMipsInfo LLVMMC LLVMSupport LLVMTarget)
-set(MSVC_LIB_DEPS_LLVMObject LLVMSupport)
-set(MSVC_LIB_DEPS_LLVMPTXCodeGen LLVMAnalysis LLVMAsmPrinter LLVMCodeGen LLVMCore LLVMMC LLVMPTXDesc LLVMPTXInfo LLVMSelectionDAG LLVMSupport LLVMTarget)
-set(MSVC_LIB_DEPS_LLVMPTXDesc LLVMMC LLVMPTXInfo LLVMSupport)
-set(MSVC_LIB_DEPS_LLVMPTXInfo LLVMMC LLVMSupport LLVMTarget)
-set(MSVC_LIB_DEPS_LLVMPowerPCAsmPrinter LLVMMC LLVMSupport)
-set(MSVC_LIB_DEPS_LLVMPowerPCCodeGen LLVMAnalysis LLVMAsmPrinter LLVMCodeGen LLVMCore LLVMMC LLVMPowerPCAsmPrinter LLVMPowerPCDesc LLVMPowerPCInfo LLVMSelectionDAG LLVMSupport LLVMTarget)
-set(MSVC_LIB_DEPS_LLVMPowerPCDesc LLVMMC LLVMPowerPCInfo LLVMSupport)
-set(MSVC_LIB_DEPS_LLVMPowerPCInfo LLVMMC LLVMSupport LLVMTarget)
-set(MSVC_LIB_DEPS_LLVMRuntimeDyld LLVMObject LLVMSupport)
-set(MSVC_LIB_DEPS_LLVMScalarOpts LLVMAnalysis LLVMCore LLVMInstCombine LLVMSupport LLVMTarget LLVMTransformUtils)
-set(MSVC_LIB_DEPS_LLVMSelectionDAG LLVMAnalysis LLVMCodeGen LLVMCore LLVMMC LLVMSupport LLVMTarget LLVMTransformUtils)
-set(MSVC_LIB_DEPS_LLVMSparcCodeGen LLVMAsmPrinter LLVMCodeGen LLVMCore LLVMMC LLVMSelectionDAG LLVMSparcDesc LLVMSparcInfo LLVMSupport LLVMTarget)
-set(MSVC_LIB_DEPS_LLVMSparcDesc LLVMMC LLVMSparcInfo LLVMSupport)
-set(MSVC_LIB_DEPS_LLVMSparcInfo LLVMMC LLVMSupport LLVMTarget)
-set(MSVC_LIB_DEPS_LLVMSupport )
-set(MSVC_LIB_DEPS_LLVMSystemZCodeGen LLVMAsmPrinter LLVMCodeGen LLVMCore LLVMMC LLVMSelectionDAG LLVMSupport LLVMSystemZDesc LLVMSystemZInfo LLVMTarget)
-set(MSVC_LIB_DEPS_LLVMSystemZDesc LLVMMC LLVMSystemZInfo)
-set(MSVC_LIB_DEPS_LLVMSystemZInfo LLVMMC LLVMSupport LLVMTarget)
-set(MSVC_LIB_DEPS_LLVMTarget LLVMCore LLVMMC LLVMSupport)
-set(MSVC_LIB_DEPS_LLVMTransformUtils LLVMAnalysis LLVMCore LLVMSupport LLVMTarget LLVMipa)
-set(MSVC_LIB_DEPS_LLVMX86AsmParser LLVMMC LLVMMCParser LLVMSupport LLVMX86Desc LLVMX86Info)
-set(MSVC_LIB_DEPS_LLVMX86AsmPrinter LLVMMC LLVMSupport LLVMX86Utils)
-set(MSVC_LIB_DEPS_LLVMX86CodeGen LLVMAnalysis LLVMAsmPrinter LLVMCodeGen LLVMCore LLVMMC LLVMSelectionDAG LLVMSupport LLVMTarget LLVMX86AsmPrinter LLVMX86Desc LLVMX86Info LLVMX86Utils)
-set(MSVC_LIB_DEPS_LLVMX86Desc LLVMMC LLVMSupport LLVMX86AsmPrinter LLVMX86Info)
-set(MSVC_LIB_DEPS_LLVMX86Disassembler LLVMMC LLVMSupport LLVMX86Info)
-set(MSVC_LIB_DEPS_LLVMX86Info LLVMMC LLVMSupport LLVMTarget)
-set(MSVC_LIB_DEPS_LLVMX86Utils LLVMCore LLVMSupport)
-set(MSVC_LIB_DEPS_LLVMXCoreCodeGen LLVMAsmPrinter LLVMCodeGen LLVMCore LLVMMC LLVMSelectionDAG LLVMSupport LLVMTarget LLVMXCoreDesc LLVMXCoreInfo)
-set(MSVC_LIB_DEPS_LLVMXCoreDesc LLVMMC LLVMXCoreInfo)
-set(MSVC_LIB_DEPS_LLVMXCoreInfo LLVMMC LLVMSupport LLVMTarget)
-set(MSVC_LIB_DEPS_LLVMipa LLVMAnalysis LLVMCore LLVMSupport)
-set(MSVC_LIB_DEPS_LLVMipo LLVMAnalysis LLVMCore LLVMScalarOpts LLVMSupport LLVMTarget LLVMTransformUtils LLVMipa)
diff --git a/lib/Analysis/CMakeLists.txt b/lib/Analysis/CMakeLists.txt
index cb1e1ebbd1..e79459d7a4 100644
--- a/lib/Analysis/CMakeLists.txt
+++ b/lib/Analysis/CMakeLists.txt
@@ -58,4 +58,10 @@ add_llvm_library(LLVMAnalysis
ValueTracking.cpp
)
+add_llvm_library_dependencies(LLVMAnalysis
+ LLVMCore
+ LLVMSupport
+ LLVMTarget
+ )
+
add_subdirectory(IPA)
diff --git a/lib/Analysis/IPA/CMakeLists.txt b/lib/Analysis/IPA/CMakeLists.txt
index 8ffef29870..eae83fdc36 100644
--- a/lib/Analysis/IPA/CMakeLists.txt
+++ b/lib/Analysis/IPA/CMakeLists.txt
@@ -5,3 +5,9 @@ add_llvm_library(LLVMipa
GlobalsModRef.cpp
IPA.cpp
)
+
+add_llvm_library_dependencies(LLVMipa
+ LLVMAnalysis
+ LLVMCore
+ LLVMSupport
+ )
diff --git a/lib/Archive/CMakeLists.txt b/lib/Archive/CMakeLists.txt
index 7ff478a41a..b52974e075 100644
--- a/lib/Archive/CMakeLists.txt
+++ b/lib/Archive/CMakeLists.txt
@@ -3,3 +3,9 @@ add_llvm_library(LLVMArchive
ArchiveReader.cpp
ArchiveWriter.cpp
)
+
+add_llvm_library_dependencies(LLVMArchive
+ LLVMBitReader
+ LLVMCore
+ LLVMSupport
+ )
diff --git a/lib/AsmParser/CMakeLists.txt b/lib/AsmParser/CMakeLists.txt
index 985ebe2009..749601510b 100644
--- a/lib/AsmParser/CMakeLists.txt
+++ b/lib/AsmParser/CMakeLists.txt
@@ -4,3 +4,8 @@ add_llvm_library(LLVMAsmParser
LLParser.cpp
Parser.cpp
)
+
+add_llvm_library_dependencies(LLVMAsmParser
+ LLVMCore
+ LLVMSupport
+ )
diff --git a/lib/Bitcode/Reader/CMakeLists.txt b/lib/Bitcode/Reader/CMakeLists.txt
index 693d4310b8..37bebc4496 100644
--- a/lib/Bitcode/Reader/CMakeLists.txt
+++ b/lib/Bitcode/Reader/CMakeLists.txt
@@ -2,3 +2,8 @@ add_llvm_library(LLVMBitReader
BitReader.cpp
BitcodeReader.cpp
)
+
+add_llvm_library_dependencies(LLVMBitReader
+ LLVMCore
+ LLVMSupport
+ )
diff --git a/lib/Bitcode/Writer/CMakeLists.txt b/lib/Bitcode/Writer/CMakeLists.txt
index f097b097c3..3cf905697a 100644
--- a/lib/Bitcode/Writer/CMakeLists.txt
+++ b/lib/Bitcode/Writer/CMakeLists.txt
@@ -4,3 +4,8 @@ add_llvm_library(LLVMBitWriter
BitcodeWriterPass.cpp
ValueEnumerator.cpp
)
+
+add_llvm_library_dependencies(LLVMBitWriter
+ LLVMCore
+ LLVMSupport
+ )
diff --git a/lib/CodeGen/AsmPrinter/CMakeLists.txt b/lib/CodeGen/AsmPrinter/CMakeLists.txt
index 4da7876ea4..67d927348b 100644
--- a/lib/CodeGen/AsmPrinter/CMakeLists.txt
+++ b/lib/CodeGen/AsmPrinter/CMakeLists.txt
@@ -12,3 +12,12 @@ add_llvm_library(LLVMAsmPrinter
Win64Exception.cpp
)
+add_llvm_library_dependencies(LLVMAsmPrinter
+ LLVMAnalysis
+ LLVMCodeGen
+ LLVMCore
+ LLVMMC
+ LLVMMCParser
+ LLVMSupport
+ LLVMTarget
+ )
diff --git a/lib/CodeGen/CMakeLists.txt b/lib/CodeGen/CMakeLists.txt
index 5e4fb44219..9cbb25cebe 100644
--- a/lib/CodeGen/CMakeLists.txt
+++ b/lib/CodeGen/CMakeLists.txt
@@ -97,5 +97,15 @@ add_llvm_library(LLVMCodeGen
VirtRegRewriter.cpp
)
+add_llvm_library_dependencies(LLVMCodeGen
+ LLVMAnalysis
+ LLVMCore
+ LLVMMC
+ LLVMScalarOpts
+ LLVMSupport
+ LLVMTarget
+ LLVMTransformUtils
+ )
+
add_subdirectory(SelectionDAG)
add_subdirectory(AsmPrinter)
diff --git a/lib/CodeGen/SelectionDAG/CMakeLists.txt b/lib/CodeGen/SelectionDAG/CMakeLists.txt
index 15932c03a1..2282f0e6eb 100644
--- a/lib/CodeGen/SelectionDAG/CMakeLists.txt
+++ b/lib/CodeGen/SelectionDAG/CMakeLists.txt
@@ -21,3 +21,13 @@ add_llvm_library(LLVMSelectionDAG
TargetLowering.cpp
TargetSelectionDAGInfo.cpp
)
+
+add_llvm_library_dependencies(LLVMSelectionDAG
+ LLVMAnalysis
+ LLVMCodeGen
+ LLVMCore
+ LLVMMC
+ LLVMSupport
+ LLVMTarget
+ LLVMTransformUtils
+ )
diff --git a/lib/ExecutionEngine/CMakeLists.txt b/lib/ExecutionEngine/CMakeLists.txt
index 58caae830f..fb14d41e91 100644
--- a/lib/ExecutionEngine/CMakeLists.txt
+++ b/lib/ExecutionEngine/CMakeLists.txt
@@ -4,6 +4,13 @@ add_llvm_library(LLVMExecutionEngine
TargetSelect.cpp
)
+add_llvm_library_dependencies(LLVMExecutionEngine
+ LLVMCore
+ LLVMMC
+ LLVMSupport
+ LLVMTarget
+ )
+
add_subdirectory(Interpreter)
add_subdirectory(JIT)
add_subdirectory(MCJIT)
diff --git a/lib/ExecutionEngine/Interpreter/CMakeLists.txt b/lib/ExecutionEngine/Interpreter/CMakeLists.txt
index d331f830b6..4fb58c2e37 100644
--- a/lib/ExecutionEngine/Interpreter/CMakeLists.txt
+++ b/lib/ExecutionEngine/Interpreter/CMakeLists.txt
@@ -12,6 +12,14 @@ add_llvm_library(LLVMInterpreter
Interpreter.cpp
)
+add_llvm_library_dependencies(LLVMInterpreter
+ LLVMCodeGen
+ LLVMCore
+ LLVMExecutionEngine
+ LLVMSupport
+ LLVMTarget
+ )
+
if( LLVM_ENABLE_FFI )
target_link_libraries( LLVMInterpreter ${FFI_LIBRARY_PATH} )
endif()
diff --git a/lib/ExecutionEngine/JIT/CMakeLists.txt b/lib/ExecutionEngine/JIT/CMakeLists.txt
index cefb0aedde..598e50e794 100644
--- a/lib/ExecutionEngine/JIT/CMakeLists.txt
+++ b/lib/ExecutionEngine/JIT/CMakeLists.txt
@@ -10,3 +10,11 @@ add_llvm_library(LLVMJIT
JITMemoryManager.cpp
OProfileJITEventListener.cpp
)
+
+add_llvm_library_dependencies(LLVMJIT
+ LLVMCore
+ LLVMExecutionEngine
+ LLVMRuntimeDyld
+ LLVMSupport
+ LLVMTarget
+ )
diff --git a/lib/ExecutionEngine/MCJIT/CMakeLists.txt b/lib/ExecutionEngine/MCJIT/CMakeLists.txt
index 38fdffa0e9..aae8a1b2c5 100644
--- a/lib/ExecutionEngine/MCJIT/CMakeLists.txt
+++ b/lib/ExecutionEngine/MCJIT/CMakeLists.txt
@@ -2,3 +2,11 @@ add_llvm_library(LLVMMCJIT
MCJIT.cpp
Intercept.cpp
)
+
+add_llvm_library_dependencies(LLVMMCJIT
+ LLVMCore
+ LLVMExecutionEngine
+ LLVMRuntimeDyld
+ LLVMSupport
+ LLVMTarget
+ )
diff --git a/lib/ExecutionEngine/RuntimeDyld/CMakeLists.txt b/lib/ExecutionEngine/RuntimeDyld/CMakeLists.txt
index 59bdfee3db..c236d1d9d1 100644
--- a/lib/ExecutionEngine/RuntimeDyld/CMakeLists.txt
+++ b/lib/ExecutionEngine/RuntimeDyld/CMakeLists.txt
@@ -2,3 +2,8 @@ add_llvm_library(LLVMRuntimeDyld
RuntimeDyld.cpp
RuntimeDyldMachO.cpp
)
+
+add_llvm_library_dependencies(LLVMRuntimeDyld
+ LLVMObject
+ LLVMSupport
+ )
diff --git a/lib/Linker/CMakeLists.txt b/lib/Linker/CMakeLists.txt
index 0b6d2f4218..4d8824bfcb 100644
--- a/lib/Linker/CMakeLists.txt
+++ b/lib/Linker/CMakeLists.txt
@@ -4,3 +4,11 @@ add_llvm_library(LLVMLinker
LinkModules.cpp
Linker.cpp
)
+
+add_llvm_library_dependencies(LLVMLinker
+ LLVMArchive
+ LLVMBitReader
+ LLVMCore
+ LLVMSupport
+ LLVMTransformUtils
+ )
diff --git a/lib/MC/CMakeLists.txt b/lib/MC/CMakeLists.txt
index 9f0a7e8bca..a3303a1bf2 100644
--- a/lib/MC/CMakeLists.txt
+++ b/lib/MC/CMakeLists.txt
@@ -42,5 +42,10 @@ add_llvm_library(LLVMMC
MCTargetAsmLexer.cpp
)
+add_llvm_library_dependencies(LLVMMC
+ LLVMObject
+ LLVMSupport
+ )
+
add_subdirectory(MCParser)
add_subdirectory(MCDisassembler)
diff --git a/lib/MC/MCDisassembler/CMakeLists.txt b/lib/MC/MCDisassembler/CMakeLists.txt
index 0ce359d4b5..bb7447ccc0 100644
--- a/lib/MC/MCDisassembler/CMakeLists.txt
+++ b/lib/MC/MCDisassembler/CMakeLists.txt
@@ -1,4 +1,3 @@
-
add_llvm_library(LLVMMCDisassembler
Disassembler.cpp
EDDisassembler.cpp
@@ -6,3 +5,44 @@ add_llvm_library(LLVMMCDisassembler
EDOperand.cpp
EDToken.cpp
)
+
+add_llvm_library_dependencies(LLVMMCDisassembler
+ LLVMARMAsmParser
+ LLVMARMDesc
+ LLVMARMDisassembler
+ LLVMARMInfo
+ LLVMAlphaDesc
+ LLVMAlphaInfo
+ LLVMBlackfinDesc
+ LLVMBlackfinInfo
+ LLVMCBackendInfo
+ LLVMCellSPUDesc
+ LLVMCellSPUInfo
+ LLVMCppBackendInfo
+ LLVMMBlazeAsmParser
+ LLVMMBlazeDesc
+ LLVMMBlazeDisassembler
+ LLVMMBlazeInfo
+ LLVMMC
+ LLVMMCParser
+ LLVMMSP430Desc
+ LLVMMSP430Info
+ LLVMMipsDesc
+ LLVMMipsInfo
+ LLVMPTXDesc
+ LLVMPTXInfo
+ LLVMPowerPCDesc
+ LLVMPowerPCInfo
+ LLVMSparcDesc
+ LLVMSparcInfo
+ LLVMSupport
+ LLVMSystemZDesc
+ LLVMSystemZInfo
+ LLVMTarget
+ LLVMX86AsmParser
+ LLVMX86Desc
+ LLVMX86Disassembler
+ LLVMX86Info
+ LLVMXCoreDesc
+ LLVMXCoreInfo
+ )
diff --git a/lib/MC/MCParser/CMakeLists.txt b/lib/MC/MCParser/CMakeLists.txt
index 222f237bfd..299d281689 100644
--- a/lib/MC/MCParser/CMakeLists.txt
+++ b/lib/MC/MCParser/CMakeLists.txt
@@ -9,3 +9,8 @@ add_llvm_library(LLVMMCParser
MCAsmParserExtension.cpp
MCTargetAsmParser.cpp
)
+
+add_llvm_library_dependencies(LLVMMCParser
+ LLVMMC
+ LLVMSupport
+ )
diff --git a/lib/Object/CMakeLists.txt b/lib/Object/CMakeLists.txt
index 68e5e94924..81113934dc 100644
--- a/lib/Object/CMakeLists.txt
+++ b/lib/Object/CMakeLists.txt
@@ -8,3 +8,8 @@ add_llvm_library(LLVMObject
Object.cpp
ObjectFile.cpp
)
+
+add_llvm_library_dependencies(LLVMObject
+ LLVMCore
+ LLVMSupport
+ )
diff --git a/lib/Target/ARM/AsmParser/CMakeLists.txt b/lib/Target/ARM/AsmParser/CMakeLists.txt
index 88393e313a..3f5ad39deb 100644
--- a/lib/Target/ARM/AsmParser/CMakeLists.txt
+++ b/lib/Target/ARM/AsmParser/CMakeLists.txt
@@ -4,4 +4,13 @@ add_llvm_library(LLVMARMAsmParser
ARMAsmLexer.cpp
ARMAsmParser.cpp
)
+
add_dependencies(LLVMARMAsmParser ARMCommonTableGen)
+
+add_llvm_library_dependencies(LLVMARMAsmParser
+ LLVMARMDesc
+ LLVMARMInfo
+ LLVMMC
+ LLVMMCParser
+ LLVMSupport
+ )
diff --git a/lib/Target/ARM/CMakeLists.txt b/lib/Target/ARM/CMakeLists.txt
index 8394be52cd..42b450959f 100644
--- a/lib/Target/ARM/CMakeLists.txt
+++ b/lib/Target/ARM/CMakeLists.txt
@@ -50,6 +50,20 @@ add_llvm_target(ARMCodeGen
Thumb2SizeReduction.cpp
)
+add_llvm_library_dependencies(LLVMARMCodeGen
+ LLVMARMAsmPrinter
+ LLVMARMDesc
+ LLVMARMInfo
+ LLVMAnalysis
+ LLVMAsmPrinter
+ LLVMCodeGen
+ LLVMCore
+ LLVMMC
+ LLVMSelectionDAG
+ LLVMSupport
+ LLVMTarget
+ )
+
# workaround for hanging compilation on MSVC10
if( MSVC_VERSION EQUAL 1600 )
set_property(
diff --git a/lib/Target/ARM/Disassembler/CMakeLists.txt b/lib/Target/ARM/Disassembler/CMakeLists.txt
index a4238aae54..952dab53ec 100644
--- a/lib/Target/ARM/Disassembler/CMakeLists.txt
+++ b/lib/Target/ARM/Disassembler/CMakeLists.txt
@@ -12,3 +12,11 @@ set_property(
)
endif()
add_dependencies(LLVMARMDisassembler ARMCommonTableGen)
+
+add_llvm_library_dependencies(LLVMARMDisassembler
+ LLVMARMCodeGen
+ LLVMARMDesc
+ LLVMARMInfo
+ LLVMMC
+ LLVMSupport
+ )
diff --git a/lib/Target/ARM/InstPrinter/CMakeLists.txt b/lib/Target/ARM/InstPrinter/CMakeLists.txt
index 7b6193aeef..fa0b4957cc 100644
--- a/lib/Target/ARM/InstPrinter/CMakeLists.txt
+++ b/lib/Target/ARM/InstPrinter/CMakeLists.txt
@@ -3,4 +3,10 @@ include_directories( ${CMAKE_CURRENT_BINARY_DIR}/.. ${CMAKE_CURRENT_SOURCE_DIR}/
add_llvm_library(LLVMARMAsmPrinter
ARMInstPrinter.cpp
)
+
add_dependencies(LLVMARMAsmPrinter ARMCommonTableGen)
+
+add_llvm_library_dependencies(LLVMARMAsmPrinter
+ LLVMMC
+ LLVMSupport
+ )
diff --git a/lib/Target/ARM/MCTargetDesc/CMakeLists.txt b/lib/Target/ARM/MCTargetDesc/CMakeLists.txt
index df2cf81be2..83fd641c31 100644
--- a/lib/Target/ARM/MCTargetDesc/CMakeLists.txt
+++ b/lib/Target/ARM/MCTargetDesc/CMakeLists.txt
@@ -11,4 +11,9 @@ add_dependencies(LLVMARMDesc ARMCommonTableGen)
# Hack: we need to include 'main' target directory to grab private headers
include_directories(${CMAKE_CURRENT_SOURCE_DIR}/.. ${CMAKE_CURRENT_BINARY_DIR}/..)
-target_link_libraries(LLVMARMDesc LLVMARMAsmPrinter)
+add_llvm_library_dependencies(LLVMARMDesc
+ LLVMARMInfo
+ LLVMARMAsmPrinter
+ LLVMMC
+ LLVMSupport
+ )
diff --git a/lib/Target/ARM/TargetInfo/CMakeLists.txt b/lib/Target/ARM/TargetInfo/CMakeLists.txt
index 3910bb02e2..3ccd4c3d53 100644
--- a/lib/Target/ARM/TargetInfo/CMakeLists.txt
+++ b/lib/Target/ARM/TargetInfo/CMakeLists.txt
@@ -5,3 +5,9 @@ add_llvm_library(LLVMARMInfo
)
add_dependencies(LLVMARMInfo ARMCodeGenTable_gen)
+
+add_llvm_library_dependencies(LLVMARMInfo
+ LLVMMC
+ LLVMSupport
+ LLVMTarget
+ )
diff --git a/lib/Target/Alpha/CMakeLists.txt b/lib/Target/Alpha/CMakeLists.txt
index 5444e1ab08..63412c144b 100644
--- a/lib/Target/Alpha/CMakeLists.txt
+++ b/lib/Target/Alpha/CMakeLists.txt
@@ -22,5 +22,17 @@ add_llvm_target(AlphaCodeGen
AlphaSelectionDAGInfo.cpp
)
+add_llvm_library_dependencies(LLVMAlphaCodeGen
+ LLVMAlphaDesc
+ LLVMAlphaInfo
+ LLVMAsmPrinter
+ LLVMCodeGen
+ LLVMCore
+ LLVMMC
+ LLVMSelectionDAG
+ LLVMSupport
+ LLVMTarget
+ )
+
add_subdirectory(TargetInfo)
add_subdirectory(MCTargetDesc)
diff --git a/lib/Target/Alpha/MCTargetDesc/CMakeLists.txt b/lib/Target/Alpha/MCTargetDesc/CMakeLists.txt
index 733b1c01d4..f745ecbdb6 100644
--- a/lib/Target/Alpha/MCTargetDesc/CMakeLists.txt
+++ b/lib/Target/Alpha/MCTargetDesc/CMakeLists.txt
@@ -2,4 +2,10 @@ add_llvm_library(LLVMAlphaDesc
AlphaMCTargetDesc.cpp
AlphaMCAsmInfo.cpp
)
+
+add_llvm_library_dependencies(LLVMAlphaDesc
+ LLVMAlphaInfo
+ LLVMMC
+ )
+
add_dependencies(LLVMAlphaDesc AlphaCommonTableGen)
diff --git a/lib/Target/Alpha/TargetInfo/CMakeLists.txt b/lib/Target/Alpha/TargetInfo/CMakeLists.txt
index a52457d633..cac3178b78 100644
--- a/lib/Target/Alpha/TargetInfo/CMakeLists.txt
+++ b/lib/Target/Alpha/TargetInfo/CMakeLists.txt
@@ -3,4 +3,11 @@ include_directories( ${CMAKE_CURRENT_BINARY_DIR}/.. ${CMAKE_CURRENT_SOURCE_DIR}/
add_llvm_library(LLVMAlphaInfo
AlphaTargetInfo.cpp
)
+
+add_llvm_library_dependencies(LLVMAlphaInfo
+ LLVMMC
+ LLVMSupport
+ LLVMTarget
+ )
+
add_dependencies(LLVMAlphaInfo AlphaCommonTableGen)
diff --git a/lib/Target/Blackfin/CMakeLists.txt b/lib/Target/Blackfin/CMakeLists.txt
index e69ffa4a3a..a0b2e935cf 100644
--- a/lib/Target/Blackfin/CMakeLists.txt
+++ b/lib/Target/Blackfin/CMakeLists.txt
@@ -22,5 +22,17 @@ add_llvm_target(BlackfinCodeGen
BlackfinSelectionDAGInfo.cpp
)
+add_llvm_library_dependencies(LLVMBlackfinCodeGen
+ LLVMAsmPrinter
+ LLVMBlackfinDesc
+ LLVMBlackfinInfo
+ LLVMCodeGen
+ LLVMCore
+ LLVMMC
+ LLVMSelectionDAG
+ LLVMSupport
+ LLVMTarget
+ )
+
add_subdirectory(TargetInfo)
add_subdirectory(MCTargetDesc)
diff --git a/lib/Target/Blackfin/MCTargetDesc/CMakeLists.txt b/lib/Target/Blackfin/MCTargetDesc/CMakeLists.txt
index 7ea79b498e..73315d852c 100644
--- a/lib/Target/Blackfin/MCTargetDesc/CMakeLists.txt
+++ b/lib/Target/Blackfin/MCTargetDesc/CMakeLists.txt
@@ -2,4 +2,10 @@ add_llvm_library(LLVMBlackfinDesc
BlackfinMCTargetDesc.cpp
BlackfinMCAsmInfo.cpp
)
+
+add_llvm_library_dependencies(LLVMBlackfinDesc
+ LLVMBlackfinInfo
+ LLVMMC
+ )
+
add_dependencies(LLVMBlackfinDesc BlackfinCommonTableGen)
diff --git a/lib/Target/Blackfin/TargetInfo/CMakeLists.txt b/lib/Target/Blackfin/TargetInfo/CMakeLists.txt
index 5ca80604f6..73faf1bcd3 100644
--- a/lib/Target/Blackfin/TargetInfo/CMakeLists.txt
+++ b/lib/Target/Blackfin/TargetInfo/CMakeLists.txt
@@ -4,4 +4,10 @@ add_llvm_library(LLVMBlackfinInfo
BlackfinTargetInfo.cpp
)
+add_llvm_library_dependencies(LLVMBlackfinInfo
+ LLVMMC
+ LLVMSupport
+ LLVMTarget
+ )
+
add_dependencies(LLVMBlackfinInfo BlackfinCodeGenTable_gen)
diff --git a/lib/Target/CBackend/CMakeLists.txt b/lib/Target/CBackend/CMakeLists.txt
index a23ff85297..96ae49f01f 100644
--- a/lib/Target/CBackend/CMakeLists.txt
+++ b/lib/Target/CBackend/CMakeLists.txt
@@ -2,4 +2,16 @@ add_llvm_target(CBackend
CBackend.cpp
)
+add_llvm_library_dependencies(LLVMCBackend
+ LLVMAnalysis
+ LLVMCBackendInfo
+ LLVMCodeGen
+ LLVMCore
+ LLVMMC
+ LLVMScalarOpts
+ LLVMSupport
+ LLVMTarget
+ LLVMTransformUtils
+ )
+
add_subdirectory(TargetInfo)
diff --git a/lib/Target/CBackend/TargetInfo/CMakeLists.txt b/lib/Target/CBackend/TargetInfo/CMakeLists.txt
index 5b35fa7c06..8e616bebd5 100644
--- a/lib/Target/CBackend/TargetInfo/CMakeLists.txt
+++ b/lib/Target/CBackend/TargetInfo/CMakeLists.txt
@@ -4,3 +4,8 @@ add_llvm_library(LLVMCBackendInfo
CBackendTargetInfo.cpp
)
+add_llvm_library_dependencies(LLVMCBackendInfo
+ LLVMMC
+ LLVMSupport
+ LLVMTarget
+ )
diff --git a/lib/Target/CMakeLists.txt b/lib/Target/CMakeLists.txt
index d91940aea4..6620882f22 100644
--- a/lib/Target/CMakeLists.txt
+++ b/lib/Target/CMakeLists.txt
@@ -14,6 +14,12 @@ add_llvm_library(LLVMTarget
TargetSubtargetInfo.cpp
)
+add_llvm_library_dependencies(LLVMTarget
+ LLVMCore
+ LLVMMC
+ LLVMSupport
+ )
+
set(LLVM_ENUM_ASM_PRINTERS "")
set(LLVM_ENUM_ASM_PARSERS "")
set(LLVM_ENUM_DISASSEMBLERS "")
diff --git a/lib/Target/CellSPU/CMakeLists.txt b/lib/Target/CellSPU/CMakeLists.txt
index 20ecb9b60e..c16e53cdfe 100644
--- a/lib/Target/CellSPU/CMakeLists.txt
+++ b/lib/Target/CellSPU/CMakeLists.txt
@@ -23,5 +23,17 @@ add_llvm_target(CellSPUCodeGen
SPUNopFiller.cpp
)
+add_llvm_library_dependencies(LLVMCellSPUCodeGen
+ LLVMAsmPrinter
+ LLVMCellSPUDesc
+ LLVMCellSPUInfo
+ LLVMCodeGen
+ LLVMCore
+ LLVMMC
+ LLVMSelectionDAG
+ LLVMSupport
+ LLVMTarget
+ )
+
add_subdirectory(TargetInfo)
add_subdirectory(MCTargetDesc)
diff --git a/lib/Target/CellSPU/MCTargetDesc/CMakeLists.txt b/lib/Target/CellSPU/MCTargetDesc/CMakeLists.txt
index 7435e93fe0..d41fe934e2 100644
--- a/lib/Target/CellSPU/MCTargetDesc/CMakeLists.txt
+++ b/lib/Target/CellSPU/MCTargetDesc/CMakeLists.txt
@@ -2,4 +2,10 @@ add_llvm_library(LLVMCellSPUDesc
SPUMCTargetDesc.cpp
SPUMCAsmInfo.cpp
)
+
+add_llvm_library_dependencies(LLVMCellSPUDesc
+ LLVMCellSPUInfo
+ LLVMMC
+ )
+
add_dependencies(LLVMCellSPUDesc CellSPUCommonTableGen)
diff --git a/lib/Target/CellSPU/TargetInfo/CMakeLists.txt b/lib/Target/CellSPU/TargetInfo/CMakeLists.txt
index 928d0fe97e..4e0785a6d8 100644
--- a/lib/Target/CellSPU/TargetInfo/CMakeLists.txt
+++ b/lib/Target/CellSPU/TargetInfo/CMakeLists.txt
@@ -4,4 +4,10 @@ add_llvm_library(LLVMCellSPUInfo
CellSPUTargetInfo.cpp
)
+add_llvm_library_dependencies(LLVMCellSPUInfo
+ LLVMMC
+ LLVMSupport
+ LLVMTarget
+ )
+
add_dependencies(LLVMCellSPUInfo CellSPUCodeGenTable_gen)
diff --git a/lib/Target/CppBackend/CMakeLists.txt b/lib/Target/CppBackend/CMakeLists.txt
index e937559951..95b6058243 100644
--- a/lib/Target/CppBackend/CMakeLists.txt
+++ b/lib/Target/CppBackend/CMakeLists.txt
@@ -2,4 +2,11 @@ add_llvm_target(CppBackend
CPPBackend.cpp
)
+add_llvm_library_dependencies(LLVMCppBackend
+ LLVMCore
+ LLVMCppBackendInfo
+ LLVMSupport
+ LLVMTarget
+ )
+
add_subdirectory(TargetInfo)
diff --git a/lib/Target/CppBackend/TargetInfo/CMakeLists.txt b/lib/Target/CppBackend/TargetInfo/CMakeLists.txt
index edaf5d3cb1..7165d8fdf2 100644
--- a/lib/Target/CppBackend/TargetInfo/CMakeLists.txt
+++ b/lib/Target/CppBackend/TargetInfo/CMakeLists.txt
@@ -4,3 +4,7 @@ add_llvm_library(LLVMCppBackendInfo
CppBackendTargetInfo.cpp
)
+add_llvm_library_dependencies(LLVMCppBackendInfo
+ LLVMMC
+ LLVMTarget
+ )
diff --git a/lib/Target/MBlaze/AsmParser/CMakeLists.txt b/lib/Target/MBlaze/AsmParser/CMakeLists.txt
index 18870cd1cf..ec8f52a92c 100644
--- a/lib/Target/MBlaze/AsmParser/CMakeLists.txt
+++ b/lib/Target/MBlaze/AsmParser/CMakeLists.txt
@@ -5,5 +5,12 @@ add_llvm_library(LLVMMBlazeAsmParser
MBlazeAsmLexer.cpp
MBlazeAsmParser.cpp
)
-add_dependencies(LLVMMBlazeAsmParser MBlazeCommonTableGen)
+add_llvm_library_dependencies(LLVMMBlazeAsmParser
+ LLVMMBlazeInfo
+ LLVMMC
+ LLVMMCParser
+ LLVMSupport
+ )
+
+add_dependencies(LLVMMBlazeAsmParser MBlazeCommonTableGen)
diff --git a/lib/Target/MBlaze/CMakeLists.txt b/lib/Target/MBlaze/CMakeLists.txt
index ae0eca96a2..20b3b036b0 100644
--- a/lib/Target/MBlaze/CMakeLists.txt
+++ b/lib/Target/MBlaze/CMakeLists.txt
@@ -29,6 +29,19 @@ add_llvm_target(MBlazeCodeGen
MBlazeELFWriterInfo.cpp
)
+add_llvm_library_dependencies(LLVMMBlazeCodeGen
+ LLVMAsmPrinter
+ LLVMCodeGen
+ LLVMCore
+ LLVMMBlazeAsmPrinter
+ LLVMMBlazeDesc
+ LLVMMBlazeInfo
+ LLVMMC
+ LLVMSelectionDAG
+ LLVMSupport
+ LLVMTarget
+ )
+
add_subdirectory(AsmParser)
add_subdirectory(Disassembler)
add_subdirectory(InstPrinter)
diff --git a/lib/Target/MBlaze/Disassembler/CMakeLists.txt b/lib/Target/MBlaze/Disassembler/CMakeLists.txt
index be2dce156d..112c64c026 100644
--- a/lib/Target/MBlaze/Disassembler/CMakeLists.txt
+++ b/lib/Target/MBlaze/Disassembler/CMakeLists.txt
@@ -13,4 +13,12 @@ set_property(
)
endif()
+add_llvm_library_dependencies(LLVMMBlazeDisassembler
+ LLVMMBlazeCodeGen
+ LLVMMBlazeDesc
+ LLVMMBlazeInfo
+ LLVMMC
+ LLVMSupport
+ )
+
add_dependencies(LLVMMBlazeDisassembler MBlazeCommonTableGen)
diff --git a/lib/Target/MBlaze/InstPrinter/CMakeLists.txt b/lib/Target/MBlaze/InstPrinter/CMakeLists.txt
index 138a4e3634..aff0b3d992 100644
--- a/lib/Target/MBlaze/InstPrinter/CMakeLists.txt
+++ b/lib/Target/MBlaze/InstPrinter/CMakeLists.txt
@@ -2,7 +2,12 @@ include_directories( ${CMAKE_CURRENT_BINARY_DIR}/..
${CMAKE_CURRENT_SOURCE_DIR}/.. )
add_llvm_library(LLVMMBlazeAsmPrinter
- MBlazeInstPrinter.cpp
+ MBlazeInstPrinter.cpp
+ )
+
+add_llvm_library_dependencies(LLVMMBlazeAsmPrinter
+ LLVMMC
+ LLVMSupport
)
add_dependencies(LLVMMBlazeAsmPrinter MBlazeCommonTableGen)
diff --git a/lib/Target/MBlaze/MCTargetDesc/CMakeLists.txt b/lib/Target/MBlaze/MCTargetDesc/CMakeLists.txt
index 247dfe884e..37871b6916 100644
--- a/lib/Target/MBlaze/MCTargetDesc/CMakeLists.txt
+++ b/lib/Target/MBlaze/MCTargetDesc/CMakeLists.txt
@@ -4,6 +4,12 @@ add_llvm_library(LLVMMBlazeDesc
MBlazeMCCodeEmitter.cpp
MBlazeMCTargetDesc.cpp
)
-add_dependencies(LLVMMBlazeDesc MBlazeCommonTableGen)
-target_link_libraries(LLVMMBlazeDesc LLVMMBlazeAsmPrinter)
+add_llvm_library_dependencies(LLVMMBlazeDesc
+ LLVMMBlazeAsmPrinter
+ LLVMMBlazeInfo
+ LLVMMC
+ LLVMSupport
+ )
+
+add_dependencies(LLVMMBlazeDesc MBlazeCommonTableGen)
diff --git a/lib/Target/MBlaze/TargetInfo/CMakeLists.txt b/lib/Target/MBlaze/TargetInfo/CMakeLists.txt
index 40696f63c4..3425334d05 100644
--- a/lib/Target/MBlaze/TargetInfo/CMakeLists.txt
+++ b/lib/Target/MBlaze/TargetInfo/CMakeLists.txt
@@ -5,4 +5,10 @@ add_llvm_library(LLVMMBlazeInfo
MBlazeTargetInfo.cpp
)
+add_llvm_library_dependencies(LLVMMBlazeInfo
+ LLVMMC
+ LLVMSupport
+ LLVMTarget
+ )
+
add_dependencies(LLVMMBlazeInfo MBlazeCodeGenTable_gen)
diff --git a/lib/Target/MSP430/CMakeLists.txt b/lib/Target/MSP430/CMakeLists.txt
index 3b6cf89d1f..3840b03b97 100644
--- a/lib/Target/MSP430/CMakeLists.txt
+++ b/lib/Target/MSP430/CMakeLists.txt
@@ -22,6 +22,19 @@ add_llvm_target(MSP430CodeGen
MSP430MCInstLower.cpp
)
+add_llvm_library_dependencies(LLVMMSP430CodeGen
+ LLVMAsmPrinter
+ LLVMCodeGen
+ LLVMCore
+ LLVMMC
+ LLVMMSP430AsmPrinter
+ LLVMMSP430Desc
+ LLVMMSP430Info
+ LLVMSelectionDAG
+ LLVMSupport
+ LLVMTarget
+ )
+
add_subdirectory(InstPrinter)
add_subdirectory(TargetInfo)
add_subdirectory(MCTargetDesc)
diff --git a/lib/Target/MSP430/InstPrinter/CMakeLists.txt b/lib/Target/MSP430/InstPrinter/CMakeLists.txt
index 5ad01456a4..ce39d9517e 100644
--- a/lib/Target/MSP430/InstPrinter/CMakeLists.txt
+++ b/lib/Target/MSP430/InstPrinter/CMakeLists.txt
@@ -3,4 +3,10 @@ include_directories( ${CMAKE_CURRENT_BINARY_DIR}/.. ${CMAKE_CURRENT_SOURCE_DIR}/
add_llvm_library(LLVMMSP430AsmPrinter
MSP430InstPrinter.cpp
)
+
+add_llvm_library_dependencies(LLVMMSP430AsmPrinter
+ LLVMMC
+ LLVMSupport
+ )
+
add_dependencies(LLVMMSP430AsmPrinter MSP430CommonTableGen)
diff --git a/lib/Target/MSP430/MCTargetDesc/CMakeLists.txt b/lib/Target/MSP430/MCTargetDesc/CMakeLists.txt
index 45b9ae8895..04bd03e494 100644
--- a/lib/Target/MSP430/MCTargetDesc/CMakeLists.txt
+++ b/lib/Target/MSP430/MCTargetDesc/CMakeLists.txt
@@ -2,6 +2,11 @@ add_llvm_library(LLVMMSP430Desc
MSP430MCTargetDesc.cpp
MSP430MCAsmInfo.cpp
)
-add_dependencies(LLVMMSP430Desc MSP430CommonTableGen)
-target_link_libraries(LLVMMSP430Desc LLVMMSP430AsmPrinter)
+add_llvm_library_dependencies(LLVMMSP430Desc
+ LLVMMC
+ LLVMMSP430AsmPrinter
+ LLVMMSP430Info
+ )
+
+add_dependencies(LLVMMSP430Desc MSP430CommonTableGen)
diff --git a/lib/Target/MSP430/TargetInfo/CMakeLists.txt b/lib/Target/MSP430/TargetInfo/CMakeLists.txt
index 2d1aa9d4e5..40f002313d 100644
--- a/lib/Target/MSP430/TargetInfo/CMakeLists.txt
+++ b/lib/Target/MSP430/TargetInfo/CMakeLists.txt
@@ -4,4 +4,10 @@ add_llvm_library(LLVMMSP430Info
MSP430TargetInfo.cpp
)
+add_llvm_library_dependencies(LLVMMSP430Info
+ LLVMMC
+ LLVMSupport
+ LLVMTarget
+ )
+
add_dependencies(LLVMMSP430Info MSP430CodeGenTable_gen)
diff --git a/lib/Target/Mips/CMakeLists.txt b/lib/Target/Mips/CMakeLists.txt
index 192ff1c93f..9daa89e54f 100644
--- a/lib/Target/Mips/CMakeLists.txt
+++ b/lib/Target/Mips/CMakeLists.txt
@@ -28,6 +28,19 @@ add_llvm_target(MipsCodeGen
MipsSelectionDAGInfo.cpp
)
+add_llvm_library_dependencies(LLVMMipsCodeGen
+ LLVMAsmPrinter
+ LLVMCodeGen
+ LLVMCore
+ LLVMMC
+ LLVMMipsAsmPrinter
+ LLVMMipsDesc
+ LLVMMipsInfo
+ LLVMSelectionDAG
+ LLVMSupport
+ LLVMTarget
+ )
+
add_subdirectory(InstPrinter)
add_subdirectory(TargetInfo)
add_subdirectory(MCTargetDesc)
diff --git a/lib/Target/Mips/InstPrinter/CMakeLists.txt b/lib/Target/Mips/InstPrinter/CMakeLists.txt
index e64d511f07..c45b35df8c 100644
--- a/lib/Target/Mips/InstPrinter/CMakeLists.txt
+++ b/lib/Target/Mips/InstPrinter/CMakeLists.txt
@@ -3,4 +3,10 @@ include_directories( ${CMAKE_CURRENT_BINARY_DIR}/.. ${CMAKE_CURRENT_SOURCE_DIR}/
add_llvm_library(LLVMMipsAsmPrinter
MipsInstPrinter.cpp
)
+
+add_llvm_library_dependencies(LLVMMipsAsmPrinter
+ LLVMMC
+ LLVMSupport
+ )
+
add_dependencies(LLVMMipsAsmPrinter MipsCommonTableGen)
diff --git a/lib/Target/Mips/MCTargetDesc/CMakeLists.txt b/lib/Target/Mips/MCTargetDesc/CMakeLists.txt
index 98760c5cd2..bb8aab1e64 100644
--- a/lib/Target/Mips/MCTargetDesc/CMakeLists.txt
+++ b/lib/Target/Mips/MCTargetDesc/CMakeLists.txt
@@ -2,6 +2,12 @@ add_llvm_library(LLVMMipsDesc
MipsMCTargetDesc.cpp
MipsMCAsmInfo.cpp
)
-add_dependencies(LLVMMipsDesc MipsCommonTableGen)
-target_link_libraries(LLVMMipsDesc LLVMMipsAsmPrinter)
+add_llvm_library_dependencies(LLVMMipsDesc
+ LLVMMC
+ LLVMMipsAsmPrinter
+ LLVMMipsInfo
+ LLVMSupport
+ )
+
+add_dependencies(LLVMMipsDesc MipsCommonTableGen)
diff --git a/lib/Target/Mips/TargetInfo/CMakeLists.txt b/lib/Target/Mips/TargetInfo/CMakeLists.txt
index 6e5d56ba4a..32240e09dd 100644
--- a/lib/Target/Mips/TargetInfo/CMakeLists.txt
+++ b/lib/Target/Mips/TargetInfo/CMakeLists.txt
@@ -4,4 +4,10 @@ add_llvm_library(LLVMMipsInfo
MipsTargetInfo.cpp
)
+add_llvm_library_dependencies(LLVMMipsInfo
+ LLVMMC
+ LLVMSupport
+ LLVMTarget
+ )
+
add_dependencies(LLVMMipsInfo MipsCodeGenTable_gen)
diff --git a/lib/Target/PTX/CMakeLists.txt b/lib/Target/PTX/CMakeLists.txt
index 1eafb66030..bfbbe87281 100644
--- a/lib/Target/PTX/CMakeLists.txt
+++ b/lib/Target/PTX/CMakeLists.txt
@@ -21,5 +21,18 @@ add_llvm_target(PTXCodeGen
PTXTargetMachine.cpp
)
+add_llvm_library_dependencies(LLVMPTXCodeGen
+ LLVMAnalysis
+ LLVMAsmPrinter
+ LLVMCodeGen
+ LLVMCore
+ LLVMMC
+ LLVMPTXDesc
+ LLVMPTXInfo
+ LLVMSelectionDAG
+ LLVMSupport
+ LLVMTarget
+ )
+
add_subdirectory(TargetInfo)
add_subdirectory(MCTargetDesc)
diff --git a/lib/Target/PTX/MCTargetDesc/CMakeLists.txt b/lib/Target/PTX/MCTargetDesc/CMakeLists.txt
index ad787321e4..ddf0825903 100644
--- a/lib/Target/PTX/MCTargetDesc/CMakeLists.txt
+++ b/lib/Target/PTX/MCTargetDesc/CMakeLists.txt
@@ -2,4 +2,11 @@ add_llvm_library(LLVMPTXDesc
PTXMCTargetDesc.cpp
PTXMCAsmInfo.cpp
)
+
+add_llvm_library_dependencies(LLVMPTXDesc
+ LLVMMC
+ LLVMPTXInfo
+ LLVMSupport
+ )
+
add_dependencies(LLVMPTXDesc PTXCommonTableGen)
diff --git a/lib/Target/PTX/TargetInfo/CMakeLists.txt b/lib/Target/PTX/TargetInfo/CMakeLists.txt
index 4b09cf5ce0..8b399dfb5d 100644
--- a/lib/Target/PTX/TargetInfo/CMakeLists.txt
+++ b/lib/Target/PTX/TargetInfo/CMakeLists.txt
@@ -4,4 +4,10 @@ add_llvm_library(LLVMPTXInfo
PTXTargetInfo.cpp
)
+add_llvm_library_dependencies(LLVMPTXInfo
+ LLVMMC
+ LLVMSupport
+ LLVMTarget
+ )
+
add_dependencies(LLVMPTXInfo PTXCodeGenTable_gen)
diff --git a/lib/Target/PowerPC/CMakeLists.txt b/lib/Target/PowerPC/CMakeLists.txt
index 563a0bd95c..ec0a9186f2 100644
--- a/lib/Target/PowerPC/CMakeLists.txt
+++ b/lib/Target/PowerPC/CMakeLists.txt
@@ -27,6 +27,20 @@ add_llvm_target(PowerPCCodeGen
PPCSelectionDAGInfo.cpp
)
+add_llvm_library_dependencies(LLVMPowerPCCodeGen
+ LLVMAnalysis
+ LLVMAsmPrinter
+ LLVMCodeGen
+ LLVMCore
+ LLVMMC
+ LLVMPowerPCAsmPrinter
+ LLVMPowerPCDesc
+ LLVMPowerPCInfo
+ LLVMSelectionDAG
+ LLVMSupport
+ LLVMTarget
+ )
+
add_subdirectory(InstPrinter)
add_subdirectory(TargetInfo)
add_subdirectory(MCTargetDesc)
diff --git a/lib/Target/PowerPC/InstPrinter/CMakeLists.txt b/lib/Target/PowerPC/InstPrinter/CMakeLists.txt
index dfdc277361..1d857e2f48 100644
--- a/lib/Target/PowerPC/InstPrinter/CMakeLists.txt
+++ b/lib/Target/PowerPC/InstPrinter/CMakeLists.txt
@@ -3,4 +3,10 @@ include_directories( ${CMAKE_CURRENT_BINARY_DIR}/.. ${CMAKE_CURRENT_SOURCE_DIR}/
add_llvm_library(LLVMPowerPCAsmPrinter
PPCInstPrinter.cpp
)
+
+add_llvm_library_dependencies(LLVMPowerPCAsmPrinter
+ LLVMMC
+ LLVMSupport
+ )
+
add_dependencies(LLVMPowerPCAsmPrinter PowerPCCommonTableGen)
diff --git a/lib/Target/PowerPC/MCTargetDesc/CMakeLists.txt b/lib/Target/PowerPC/MCTargetDesc/CMakeLists.txt
index 78e7ab5a80..c4041db8cf 100644
--- a/lib/Target/PowerPC/MCTargetDesc/CMakeLists.txt
+++ b/lib/Target/PowerPC/MCTargetDesc/CMakeLists.txt
@@ -5,6 +5,12 @@ add_llvm_library(LLVMPowerPCDesc
PPCMCCodeEmitter.cpp
PPCPredicates.cpp
)
-add_dependencies(LLVMPowerPCDesc PowerPCCommonTableGen)
-target_link_libraries(LLVMPowerPCDesc LLVMPowerPCAsmPrinter)
+add_llvm_library_dependencies(LLVMPowerPCDesc
+ LLVMMC
+ LLVMPowerPCAsmPrinter
+ LLVMPowerPCInfo
+ LLVMSupport
+ )
+
+add_dependencies(LLVMPowerPCDesc PowerPCCommonTableGen)
diff --git a/lib/Target/PowerPC/TargetInfo/CMakeLists.txt b/lib/Target/PowerPC/TargetInfo/CMakeLists.txt
index 058d599a4a..aab91ae036 100644
--- a/lib/Target/PowerPC/TargetInfo/CMakeLists.txt
+++ b/lib/Target/PowerPC/TargetInfo/CMakeLists.txt
@@ -4,4 +4,10 @@ add_llvm_library(LLVMPowerPCInfo
PowerPCTargetInfo.cpp
)
+add_llvm_library_dependencies(LLVMPowerPCInfo
+ LLVMMC
+ LLVMSupport
+ LLVMTarget
+ )
+
add_dependencies(LLVMPowerPCInfo PowerPCCodeGenTable_gen)
diff --git a/lib/Target/Sparc/CMakeLists.txt b/lib/Target/Sparc/CMakeLists.txt
index 32bc421f0b..0491229f61 100644
--- a/lib/Target/Sparc/CMakeLists.txt
+++ b/lib/Target/Sparc/CMakeLists.txt
@@ -22,5 +22,17 @@ add_llvm_target(SparcCodeGen
SparcSelectionDAGInfo.cpp
)
+add_llvm_library_dependencies(LLVMSparcCodeGen
+ LLVMAsmPrinter
+ LLVMCodeGen
+ LLVMCore
+ LLVMMC
+ LLVMSelectionDAG
+ LLVMSparcDesc
+ LLVMSparcInfo
+ LLVMSupport
+ LLVMTarget
+ )
+
add_subdirectory(TargetInfo)
add_subdirectory(MCTargetDesc)
diff --git a/lib/Target/Sparc/MCTargetDesc/CMakeLists.txt b/lib/Target/Sparc/MCTargetDesc/CMakeLists.txt
index a0525b6723..d3bdf0b503 100644
--- a/lib/Target/Sparc/MCTargetDesc/CMakeLists.txt
+++ b/lib/Target/Sparc/MCTargetDesc/CMakeLists.txt
@@ -2,4 +2,11 @@ add_llvm_library(LLVMSparcDesc
SparcMCTargetDesc.cpp
SparcMCAsmInfo.cpp
)
+
+add_llvm_library_dependencies(LLVMSparcDesc
+ LLVMMC
+ LLVMSparcInfo
+ LLVMSupport
+ )
+
add_dependencies(LLVMSparcDesc SparcCommonTableGen)
diff --git a/lib/Target/Sparc/TargetInfo/CMakeLists.txt b/lib/Target/Sparc/TargetInfo/CMakeLists.txt
index 870b56a6ea..e2dabb1749 100644
--- a/lib/Target/Sparc/TargetInfo/CMakeLists.txt
+++ b/lib/Target/Sparc/TargetInfo/CMakeLists.txt
@@ -4,4 +4,10 @@ add_llvm_library(LLVMSparcInfo
SparcTargetInfo.cpp
)
+add_llvm_library_dependencies(LLVMSparcInfo
+ LLVMMC
+ LLVMSupport
+ LLVMTarget
+ )
+
add_dependencies(LLVMSparcInfo SparcCodeGenTable_gen)
diff --git a/lib/Target/SystemZ/CMakeLists.txt b/lib/Target/SystemZ/CMakeLists.txt
index bd8238ecac..41b4c78bee 100644
--- a/lib/Target/SystemZ/CMakeLists.txt
+++ b/lib/Target/SystemZ/CMakeLists.txt
@@ -20,5 +20,17 @@ add_llvm_target(SystemZCodeGen
SystemZSelectionDAGInfo.cpp
)
+add_llvm_library_dependencies(LLVMSystemZCodeGen
+ LLVMAsmPrinter
+ LLVMCodeGen
+ LLVMCore
+ LLVMMC
+ LLVMSelectionDAG
+ LLVMSupport
+ LLVMSystemZDesc
+ LLVMSystemZInfo
+ LLVMTarget
+ )
+
add_subdirectory(TargetInfo)
add_subdirectory(MCTargetDesc)
diff --git a/lib/Target/SystemZ/MCTargetDesc/CMakeLists.txt b/lib/Target/SystemZ/MCTargetDesc/CMakeLists.txt
index 612a94ec92..822df097a3 100644
--- a/lib/Target/SystemZ/MCTargetDesc/CMakeLists.txt
+++ b/lib/Target/SystemZ/MCTargetDesc/CMakeLists.txt
@@ -2,6 +2,12 @@ add_llvm_library(LLVMSystemZDesc
SystemZMCTargetDesc.cpp
SystemZMCAsmInfo.cpp
)
+
+add_llvm_library_dependencies(LLVMSystemZDesc
+ LLVMMC
+ LLVMSystemZInfo
+ )
+
add_dependencies(LLVMSystemZDesc SystemZCommonTableGen)
# Hack: we need to include 'main' target directory to grab private headers
diff --git a/lib/Target/SystemZ/TargetInfo/CMakeLists.txt b/lib/Target/SystemZ/TargetInfo/CMakeLists.txt
index 743d8d322d..12045bdc4d 100644
--- a/lib/Target/SystemZ/TargetInfo/CMakeLists.txt
+++ b/lib/Target/SystemZ/TargetInfo/CMakeLists.txt
@@ -4,4 +4,10 @@ add_llvm_library(LLVMSystemZInfo
SystemZTargetInfo.cpp
)
+add_llvm_library_dependencies(LLVMSystemZInfo
+ LLVMMC
+ LLVMSupport
+ LLVMTarget
+ )
+
add_dependencies(LLVMSystemZInfo SystemZCodeGenTable_gen)
diff --git a/lib/Target/X86/AsmParser/CMakeLists.txt b/lib/Target/X86/AsmParser/CMakeLists.txt
index 78b16f7cd3..94aca7abb2 100644
--- a/lib/Target/X86/AsmParser/CMakeLists.txt
+++ b/lib/Target/X86/AsmParser/CMakeLists.txt
@@ -4,4 +4,13 @@ add_llvm_library(LLVMX86AsmParser
X86AsmLexer.cpp
X86AsmParser.cpp
)
+
+add_llvm_library_dependencies(LLVMX86AsmParser
+ LLVMMC
+ LLVMMCParser
+ LLVMSupport
+ LLVMX86Desc
+ LLVMX86Info
+ )
+
add_dependencies(LLVMX86AsmParser X86CommonTableGen)
diff --git a/lib/Target/X86/CMakeLists.txt b/lib/Target/X86/CMakeLists.txt
index 60d3e26ccf..1fd55128e2 100644
--- a/lib/Target/X86/CMakeLists.txt
+++ b/lib/Target/X86/CMakeLists.txt
@@ -51,6 +51,19 @@ endif()
add_llvm_target(X86CodeGen ${sources})
+add_llvm_library_dependencies(LLVMX86CodeGen
+ LLVMAnalysis
+ LLVMAsmPrinter
+ LLVMCodeGen
+ LLVMCore
+ LLVMMC
+ LLVMSelectionDAG
+ LLVMSupport
+ LLVMTarget
+ LLVMX86AsmPrinter
+ LLVMX86Desc
+ )
+
add_subdirectory(AsmParser)
add_subdirectory(Disassembler)
add_subdirectory(InstPrinter)
diff --git a/lib/Target/X86/Disassembler/CMakeLists.txt b/lib/Target/X86/Disassembler/CMakeLists.txt
index 240f9b5748..4f570d56e6 100644
--- a/lib/Target/X86/Disassembler/CMakeLists.txt
+++ b/lib/Target/X86/Disassembler/CMakeLists.txt
@@ -4,6 +4,13 @@ add_llvm_library(LLVMX86Disassembler
X86Disassembler.cpp
X86DisassemblerDecoder.c
)
+
+add_llvm_library_dependencies(LLVMX86Disassembler
+ LLVMMC
+ LLVMSupport
+ LLVMX86Info
+ )
+
# workaround for hanging compilation on MSVC9 and 10
if( MSVC_VERSION EQUAL 1400 OR MSVC_VERSION EQUAL 1500 OR MSVC_VERSION EQUAL 1600 )
set_property(
@@ -11,4 +18,5 @@ set_property(
PROPERTY COMPILE_FLAGS "/Od"
)
endif()
+
add_dependencies(LLVMX86Disassembler X86CommonTableGen)
diff --git a/lib/Target/X86/InstPrinter/CMakeLists.txt b/lib/Target/X86/InstPrinter/CMakeLists.txt
index 3be627a1f0..2a2b5dbb43 100644
--- a/lib/Target/X86/InstPrinter/CMakeLists.txt
+++ b/lib/Target/X86/InstPrinter/CMakeLists.txt
@@ -5,4 +5,11 @@ add_llvm_library(LLVMX86AsmPrinter
X86IntelInstPrinter.cpp
X86InstComments.cpp
)
+
+add_llvm_library_dependencies(LLVMX86AsmPrinter
+ LLVMMC
+ LLVMSupport
+ LLVMX86Utils
+ )
+
add_dependencies(LLVMX86AsmPrinter X86CommonTableGen)
diff --git a/lib/Target/X86/MCTargetDesc/CMakeLists.txt b/lib/Target/X86/MCTargetDesc/CMakeLists.txt
index 4e7995d76b..87219120e2 100644
--- a/lib/Target/X86/MCTargetDesc/CMakeLists.txt
+++ b/lib/Target/X86/MCTargetDesc/CMakeLists.txt
@@ -5,9 +5,16 @@ add_llvm_library(LLVMX86Desc
X86MCCodeEmitter.cpp
X86MachObjectWriter.cpp
)
+
+add_llvm_library_dependencies(LLVMX86Desc
+ LLVMMC
+ LLVMSupport
+ LLVMX86AsmPrinter
+ LLVMX86AsmPrinter
+ LLVMX86Info
+ )
+
add_dependencies(LLVMX86Desc X86CommonTableGen)
# Hack: we need to include 'main' target directory to grab private headers
include_directories(${CMAKE_CURRENT_SOURCE_DIR}/.. ${CMAKE_CURRENT_BINARY_DIR}/..)
-
-target_link_libraries(LLVMX86Desc LLVMX86AsmPrinter)
diff --git a/lib/Target/X86/TargetInfo/CMakeLists.txt b/lib/Target/X86/TargetInfo/CMakeLists.txt
index 90be9f58cc..8611c40700 100644
--- a/lib/Target/X86/TargetInfo/CMakeLists.txt
+++ b/lib/Target/X86/TargetInfo/CMakeLists.txt
@@ -4,4 +4,10 @@ add_llvm_library(LLVMX86Info
X86TargetInfo.cpp
)
+add_llvm_library_dependencies(LLVMX86Info
+ LLVMMC
+ LLVMSupport
+ LLVMTarget
+ )
+
add_dependencies(LLVMX86Info X86CodeGenTable_gen)
diff --git a/lib/Target/X86/Utils/CMakeLists.txt b/lib/Target/X86/Utils/CMakeLists.txt
index 3ad5f991c8..30ed60bb4b 100644
--- a/lib/Target/X86/Utils/CMakeLists.txt
+++ b/lib/Target/X86/Utils/CMakeLists.txt
@@ -3,4 +3,10 @@ include_directories( ${CMAKE_CURRENT_BINARY_DIR}/.. ${CMAKE_CURRENT_SOURCE_DIR}/
add_llvm_library(LLVMX86Utils
X86ShuffleDecode.cpp
)
+
+add_llvm_library_dependencies(LLVMX86Utils
+ LLVMCore
+ LLVMSupport
+ )
+
add_dependencies(LLVMX86Utils X86CodeGenTable_gen)
diff --git a/lib/Target/XCore/CMakeLists.txt b/lib/Target/XCore/CMakeLists.txt
index aa4c45bdf1..dce6e32b6f 100644
--- a/lib/Target/XCore/CMakeLists.txt
+++ b/lib/Target/XCore/CMakeLists.txt
@@ -21,5 +21,17 @@ add_llvm_target(XCoreCodeGen
XCoreSelectionDAGInfo.cpp
)
+add_llvm_library_dependencies(LLVMXCoreCodeGen
+ LLVMAsmPrinter
+ LLVMCodeGen
+ LLVMCore
+ LLVMMC
+ LLVMSelectionDAG
+ LLVMSupport
+ LLVMTarget
+ LLVMXCoreDesc
+ LLVMXCoreInfo
+ )
+
add_subdirectory(TargetInfo)
add_subdirectory(MCTargetDesc)
diff --git a/lib/Target/XCore/MCTargetDesc/CMakeLists.txt b/lib/Target/XCore/MCTargetDesc/CMakeLists.txt
index 4a69922f62..269822db71 100644
--- a/lib/Target/XCore/MCTargetDesc/CMakeLists.txt
+++ b/lib/Target/XCore/MCTargetDesc/CMakeLists.txt
@@ -2,6 +2,12 @@ add_llvm_library(LLVMXCoreDesc
XCoreMCTargetDesc.cpp
XCoreMCAsmInfo.cpp
)
+
+add_llvm_library_dependencies(LLVMXCoreDesc
+ LLVMMC
+ LLVMXCoreInfo
+ )
+
add_dependencies(LLVMXCoreDesc XCoreCommonTableGen)
# Hack: we need to include 'main' target directory to grab private headers
diff --git a/lib/Target/XCore/TargetInfo/CMakeLists.txt b/lib/Target/XCore/TargetInfo/CMakeLists.txt
index c147b8a66b..b2d33499fb 100644
--- a/lib/Target/XCore/TargetInfo/CMakeLists.txt
+++ b/lib/Target/XCore/TargetInfo/CMakeLists.txt
@@ -4,4 +4,10 @@ add_llvm_library(LLVMXCoreInfo
XCoreTargetInfo.cpp
)
+add_llvm_library_dependencies(LLVMXCoreInfo
+ LLVMMC
+ LLVMSupport
+ LLVMTarget
+ )
+
add_dependencies(LLVMXCoreInfo XCoreCodeGenTable_gen)
diff --git a/lib/Transforms/IPO/CMakeLists.txt b/lib/Transforms/IPO/CMakeLists.txt
index 3de7bfceed..d476cccf18 100644
--- a/lib/Transforms/IPO/CMakeLists.txt
+++ b/lib/Transforms/IPO/CMakeLists.txt
@@ -20,3 +20,13 @@ add_llvm_library(LLVMipo
StripDeadPrototypes.cpp
StripSymbols.cpp
)
+
+add_llvm_library_dependencies(LLVMipo
+ LLVMAnalysis
+ LLVMCore
+ LLVMScalarOpts
+ LLVMSupport
+ LLVMTarget
+ LLVMTransformUtils
+ LLVMipa
+ )
diff --git a/lib/Transforms/InstCombine/CMakeLists.txt b/lib/Transforms/InstCombine/CMakeLists.txt
index d070ccc0d6..a46d5adc0a 100644
--- a/lib/Transforms/InstCombine/CMakeLists.txt
+++ b/lib/Transforms/InstCombine/CMakeLists.txt
@@ -13,3 +13,11 @@ add_llvm_library(LLVMInstCombine
InstCombineSimplifyDemanded.cpp
InstCombineVectorOps.cpp
)
+
+add_llvm_library_dependencies(LLVMInstCombine
+ LLVMAnalysis
+ LLVMCore
+ LLVMSupport
+ LLVMTarget
+ LLVMTransformUtils
+ )
diff --git a/lib/Transforms/Instrumentation/CMakeLists.txt b/lib/Transforms/Instrumentation/CMakeLists.txt
index 5700ac87f6..7b3a927a4e 100644
--- a/lib/Transforms/Instrumentation/CMakeLists.txt
+++ b/lib/Transforms/Instrumentation/CMakeLists.txt
@@ -6,3 +6,10 @@ add_llvm_library(LLVMInstrumentation
PathProfiling.cpp
ProfilingUtils.cpp
)
+
+add_llvm_library_dependencies(LLVMInstrumentation
+ LLVMAnalysis
+ LLVMCore
+ LLVMSupport
+ LLVMTransformUtils
+ )
diff --git a/lib/Transforms/Scalar/CMakeLists.txt b/lib/Transforms/Scalar/CMakeLists.txt
index c223da60e0..728f9fb2d2 100644
--- a/lib/Transforms/Scalar/CMakeLists.txt
+++ b/lib/Transforms/Scalar/CMakeLists.txt
@@ -32,3 +32,12 @@ add_llvm_library(LLVMScalarOpts
TailDuplication.cpp
TailRecursionElimination.cpp
)
+
+add_llvm_library_dependencies(LLVMScalarOpts
+ LLVMAnalysis
+ LLVMCore
+ LLVMInstCombine
+ LLVMSupport
+ LLVMTarget
+ LLVMTransformUtils
+ )
diff --git a/lib/Transforms/Utils/CMakeLists.txt b/lib/Transforms/Utils/CMakeLists.txt
index 204c2c63e1..8b944096e7 100644
--- a/lib/Transforms/Utils/CMakeLists.txt
+++ b/lib/Transforms/Utils/CMakeLists.txt
@@ -27,3 +27,10 @@ add_llvm_library(LLVMTransformUtils
ValueMapper.cpp
)
+add_llvm_library_dependencies(LLVMTransformUtils
+ LLVMAnalysis
+ LLVMCore
+ LLVMSupport
+ LLVMTarget
+ LLVMipa
+ )
diff --git a/lib/VMCore/CMakeLists.txt b/lib/VMCore/CMakeLists.txt
index f60dd06c98..2553cc099c 100644
--- a/lib/VMCore/CMakeLists.txt
+++ b/lib/VMCore/CMakeLists.txt
@@ -36,3 +36,5 @@ add_llvm_library(LLVMCore
ValueTypes.cpp
Verifier.cpp
)
+
+add_llvm_library_dependencies(LLVMCore LLVMSupport)
diff --git a/tools/llvm-config/CMakeLists.txt b/tools/llvm-config/CMakeLists.txt
index bc23a64d0e..60168623f1 100644
--- a/tools/llvm-config/CMakeLists.txt
+++ b/tools/llvm-config/CMakeLists.txt
@@ -138,27 +138,3 @@ install(FILES ${LLVM_CONFIG}
PERMISSIONS OWNER_READ OWNER_WRITE OWNER_EXECUTE GROUP_READ GROUP_EXECUTE
WORLD_READ WORLD_EXECUTE
DESTINATION bin)
-
-
-# Regeneration of library dependencies.
-
-# See the comments at the end of cmake/modules/LLVM-Config.cmake for
-# notes and guidelines.
-
-set(LLVMLibDeps ${LLVM_MAIN_SRC_DIR}/cmake/modules/LLVMLibDeps.cmake)
-set(LLVMLibDeps_TMP ${CMAKE_CURRENT_BINARY_DIR}/LLVMLibDeps.cmake.tmp)
-
-add_custom_command(OUTPUT ${LLVMLibDeps_TMP}
- COMMAND sed -e s'@\\.a@@g' -e s'@\\.so@@g' -e 's@libLLVM@LLVM@g' -e 's@: @ @' -e 's@\\\(.*\\\)@set\(MSVC_LIB_DEPS_\\1\)@' ${FINAL_LIBDEPS} > ${LLVMLibDeps_TMP}
- COMMAND ${CMAKE_COMMAND} -E copy_if_different ${LLVMLibDeps_TMP} ${LLVMLibDeps}
- DEPENDS ${FINAL_LIBDEPS}
- COMMENT "Updating cmake library dependencies file ${LLVMLibDeps}"
- )
-
-if( LLVM_TARGETS_TO_BUILD STREQUAL LLVM_ALL_TARGETS )
- add_custom_target(llvmlibdeps.target ALL DEPENDS ${LLVMLibDeps_TMP})
- add_dependencies(llvmlibdeps.target llvm-config.target)
- set(LLVM_COMMON_DEPENDS ${LLVM_COMMON_DEPENDS} llvmlibdeps.target)
-endif()
-
-set(LLVM_COMMON_DEPENDS ${LLVM_COMMON_DEPENDS} PARENT_SCOPE)