From 0c221230c701ff6c60cce8f6401148dba6dd9d95 Mon Sep 17 00:00:00 2001 From: George Karpenkov Date: Mon, 28 Aug 2017 19:39:05 +0000 Subject: Proper dependency check for clang in compiler_rt. - Not having a dependency does not work in standalone build, as Clang does not exist. - if (TARGET clang) check is useless, as it is order-dependent, and Clang may not be registered yet. Differential Revision: https://reviews.llvm.org/D37228 git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@311911 91177308-0d34-0410-b5e6-96231b3b80d8 --- cmake/Modules/CompilerRTCompile.cmake | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'cmake') diff --git a/cmake/Modules/CompilerRTCompile.cmake b/cmake/Modules/CompilerRTCompile.cmake index 4c6568167..872f1a065 100644 --- a/cmake/Modules/CompilerRTCompile.cmake +++ b/cmake/Modules/CompilerRTCompile.cmake @@ -136,7 +136,7 @@ macro(clang_compiler_add_cxx_check) COMMAND bash -c "${CMD}" COMMENT "Checking that just-built clang can find C++ headers..." VERBATIM) - if (TARGET clang) + if (NOT COMPILER_RT_STANDALONE_BUILD) ADD_DEPENDENCIES(CompilerRTUnitTestCheckCxx clang) endif() endif() -- cgit v1.2.3