[llvm] r212921 - [CMake] LINK_COMPONENTS: Add also corresponding MCTargetDesc and TargetInfo as well, when target names or "nativecodegen" are specified.
NAKAMURA Takumi
geek4civic at gmail.com
Sun Jul 13 22:07:08 PDT 2014
Author: chapuni
Date: Mon Jul 14 00:07:07 2014
New Revision: 212921
URL: http://llvm.org/viewvc/llvm-project?rev=212921&view=rev
Log:
[CMake] LINK_COMPONENTS: Add also corresponding MCTargetDesc and TargetInfo as well, when target names or "nativecodegen" are specified.
Modified:
llvm/trunk/cmake/modules/LLVM-Config.cmake
Modified: llvm/trunk/cmake/modules/LLVM-Config.cmake
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/cmake/modules/LLVM-Config.cmake?rev=212921&r1=212920&r2=212921&view=diff
==============================================================================
--- llvm/trunk/cmake/modules/LLVM-Config.cmake (original)
+++ llvm/trunk/cmake/modules/LLVM-Config.cmake Mon Jul 14 00:07:07 2014
@@ -105,6 +105,9 @@ function(llvm_map_components_to_libnames
if( TARGET LLVM${c}AsmParser )
list(APPEND expanded_components "LLVM${c}AsmParser")
endif()
+ if( TARGET LLVM${c}Desc )
+ list(APPEND expanded_components "LLVM${c}Desc")
+ endif()
if( TARGET LLVM${c}Info )
list(APPEND expanded_components "LLVM${c}Info")
endif()
@@ -115,6 +118,12 @@ function(llvm_map_components_to_libnames
# already processed
elseif( c STREQUAL "nativecodegen" )
list(APPEND expanded_components "LLVM${LLVM_NATIVE_ARCH}CodeGen")
+ if( TARGET LLVM${LLVM_NATIVE_ARCH}Desc )
+ list(APPEND expanded_components "LLVM${LLVM_NATIVE_ARCH}Desc")
+ endif()
+ if( TARGET LLVM${LLVM_NATIVE_ARCH}Info )
+ list(APPEND expanded_components "LLVM${LLVM_NATIVE_ARCH}Info")
+ endif()
elseif( c STREQUAL "backend" )
# same case as in `native'.
elseif( c STREQUAL "engine" )
More information about the llvm-commits
mailing list