CMake's target_link_libraries() will manage dependencies with Brad's LLVMConfig improvements.
Configuration time may be reduced by a few seconds.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@201062
91177308-0d34-0410-b5e6-
96231b3b80d8
function(explicit_llvm_config executable)
set( link_components ${ARGN} )
function(explicit_llvm_config executable)
set( link_components ${ARGN} )
- # Check for out-of-tree builds.
- if(PROJECT_NAME STREQUAL "LLVM")
- llvm_map_components_to_libnames(LIBRARIES ${link_components})
- else()
- explicit_map_components_to_libraries(LIBRARIES ${link_components})
- endif()
-
+ llvm_map_components_to_libnames(LIBRARIES ${link_components})
target_link_libraries(${executable} ${LIBRARIES})
endfunction(explicit_llvm_config)
target_link_libraries(${executable} ${LIBRARIES})
endfunction(explicit_llvm_config)