From 47de76b0d42dcb95db85571ab26b93634979276e Mon Sep 17 00:00:00 2001 From: Petr Hosek Date: Tue, 12 Feb 2019 01:09:07 +0000 Subject: [PATCH] [CMake][XRay] Silence llvm-config error when checking library support Otherwise this propagates all the way to CMake and results in an error during configuration. We check and handle the result and report warning separately so this is not changing the behavior. Differential Revision: https://reviews.llvm.org/D58086 llvm-svn: 353784 --- compiler-rt/cmake/Modules/CompilerRTUtils.cmake | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/compiler-rt/cmake/Modules/CompilerRTUtils.cmake b/compiler-rt/cmake/Modules/CompilerRTUtils.cmake index 5348f2064b67..3ebd9273949c 100644 --- a/compiler-rt/cmake/Modules/CompilerRTUtils.cmake +++ b/compiler-rt/cmake/Modules/CompilerRTUtils.cmake @@ -233,7 +233,8 @@ macro(load_llvm_config) execute_process( COMMAND ${LLVM_CONFIG_PATH} "--ldflags" "--libs" "xray" RESULT_VARIABLE HAD_ERROR - OUTPUT_VARIABLE CONFIG_OUTPUT) + OUTPUT_VARIABLE CONFIG_OUTPUT + ERROR_QUIET) if (HAD_ERROR) message(WARNING "llvm-config finding xray failed with status ${HAD_ERROR}") set(COMPILER_RT_HAS_LLVMXRAY FALSE) @@ -250,7 +251,8 @@ macro(load_llvm_config) execute_process( COMMAND ${LLVM_CONFIG_PATH} "--ldflags" "--libs" "testingsupport" RESULT_VARIABLE HAD_ERROR - OUTPUT_VARIABLE CONFIG_OUTPUT) + OUTPUT_VARIABLE CONFIG_OUTPUT + ERROR_QUIET) if (HAD_ERROR) message(WARNING "llvm-config finding testingsupport failed with status ${HAD_ERROR}") else() -- GitLab