[llvm] r366612 - Fix a latent bug discovered by r366610: nativecodegen includes X86CodeGen when X86 is not compiled
Daniel Sanders via llvm-commits
llvm-commits at lists.llvm.org
Fri Jul 19 13:58:11 PDT 2019
Author: dsanders
Date: Fri Jul 19 13:58:11 2019
New Revision: 366612
URL: http://llvm.org/viewvc/llvm-project?rev=366612&view=rev
Log:
Fix a latent bug discovered by r366610: nativecodegen includes X86CodeGen when X86 is not compiled
I believe this to have been a latent bug as the same expansion checks for the
existence of ${native_tgt}Info and ${native_tgt}Desc and only adds them if
they were compiled but unconditionally adds ${native_tgt}CodeGen.
This should fix llvm-clang-x86_64-win-fast which builds ARM only on an X86 host and similar builders.
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=366612&r1=366611&r2=366612&view=diff
==============================================================================
--- llvm/trunk/cmake/modules/LLVM-Config.cmake (original)
+++ llvm/trunk/cmake/modules/LLVM-Config.cmake Fri Jul 19 13:58:11 2019
@@ -154,7 +154,9 @@ function(llvm_expand_pseudo_components o
list(APPEND expanded_components "${c}Utils")
endif()
elseif( c STREQUAL "nativecodegen" )
- list(APPEND expanded_components "${LLVM_NATIVE_ARCH}CodeGen")
+ if( TARGET LLVM${LLVM_NATIVE_ARCH}CodeGen )
+ list(APPEND expanded_components "${LLVM_NATIVE_ARCH}CodeGen")
+ endif()
if( TARGET LLVM${LLVM_NATIVE_ARCH}Desc )
list(APPEND expanded_components "${LLVM_NATIVE_ARCH}Desc")
endif()
More information about the llvm-commits
mailing list