In this patch, dependencies that are expressed in required_libraries
of LLVMBUild.txt are copied into LINK_COMPONENTS of each component's
add_llvm_library/-_target CMake call.
- This patch is NFC, except for a minor detail: Passing LINK_COMPONENTS causes llvm_map_components_to_libnames (in cmake/modules/LLVM-Config.cmake) to verify that each LINK_COMPONENTS item actually exists. It's possible for this check to spuriously fail since components aren't added in RPO.
So an additional small change to LLVM-Config.cmake is needed to quell this error.
- lib/LineEditor/CMakeLists.txt expresses its dependence on LLVMSupport through LINK_LIBS. The patch corrects this to use LINK_COMPONENTS instead.