Index: compiler-rt/trunk/cmake/Modules/CompilerRTCompile.cmake =================================================================== --- compiler-rt/trunk/cmake/Modules/CompilerRTCompile.cmake +++ compiler-rt/trunk/cmake/Modules/CompilerRTCompile.cmake @@ -67,8 +67,8 @@ if(NOT COMPILER_RT_STANDALONE_BUILD) list(APPEND SOURCE_DEPS clang compiler-rt-headers) endif() - if (TARGET CompilerRTUnitTestCheckCxx) - list(APPEND SOURCE_DEPS CompilerRTUnitTestCheckCxx) + if (TARGET CheckClangHeaders) + list(APPEND SOURCE_DEPS CheckClangHeaders) endif() string(REGEX MATCH "[.](cc|cpp)$" is_cxx ${source_rpath}) string(REGEX MATCH "[.](m|mm)$" is_objc ${source_rpath}) @@ -132,12 +132,10 @@ " false" "fi" ) - add_custom_target(CompilerRTUnitTestCheckCxx + add_custom_target(CheckClangHeaders COMMAND bash -c "${CMD}" COMMENT "Checking that just-built clang can find C++ headers..." VERBATIM) - if (TARGET clang) - ADD_DEPENDENCIES(CompilerRTUnitTestCheckCxx clang) - endif() + ADD_DEPENDENCIES(CheckClangHeaders clang) endif() endmacro()