[PATCH] D12488: Enable linking tools, shared libraries against libLLVM

Andrew Wilkins via llvm-commits llvm-commits at lists.llvm.org
Tue Sep 1 17:36:48 PDT 2015


axw added a comment.

In http://reviews.llvm.org/D12488#237856, @axw wrote:

> In http://reviews.llvm.org/D12488#237400, @beanz wrote:
>
> > I've also been thinking more about how this patch works, and I think it is implemented wrong. We should push all of this down into the `llvm_config` CMake functionality, and we should probably find a way to bake this behavior into the llvm-config executable and installed CMake files so that people using distributions of LLVM get the right behavior too.
>
>
> I did think about that, and the problem there is that the way the existing build scripts work is: call into LLVM-Config.cmake to translate a list of component names to library names, and pass them through target_link_libraries. Making this change would have been *much* more invasive, requiring touching all the CMakeLists.txts.


Please disregard this reply, I was in a pre-caffeine state. This is just what I did in AddLLVM.cmake. The alternative I was thinking of was to modify llvm_map_components_to_libnames to return libLLVM only in this mode, but that seemed like it would be wrong/surprising.

If you could describe how you'd like this to look instead, I'm very happy to do the work.


http://reviews.llvm.org/D12488





More information about the llvm-commits mailing list