From: Petr Hosek Date: Wed, 26 Jul 2017 23:49:18 +0000 (+0000) Subject: [CMake] Disable -Werror for CMake checks X-Git-Tag: llvmorg-6.0.0-rc1~11649 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=b88afb3fbd26327947a9eaf793b9ab0d4dc568a5;p=platform%2Fupstream%2Fllvm.git [CMake] Disable -Werror for CMake checks -Werror may cause some of the CMake checks to fail, so we disable it even if it's enabled for the build itself. Differential Revision: https://reviews.llvm.org/D35924 llvm-svn: 309235 --- diff --git a/llvm/cmake/modules/HandleLLVMOptions.cmake b/llvm/cmake/modules/HandleLLVMOptions.cmake index 0676317..5efdb0f 100644 --- a/llvm/cmake/modules/HandleLLVMOptions.cmake +++ b/llvm/cmake/modules/HandleLLVMOptions.cmake @@ -381,6 +381,7 @@ if( MSVC ) elseif( LLVM_COMPILER_IS_GCC_COMPATIBLE ) append_if(LLVM_ENABLE_WERROR "-Werror" CMAKE_C_FLAGS CMAKE_CXX_FLAGS) + append_if(LLVM_ENABLE_WERROR "-Wno-error" CMAKE_REQUIRED_FLAGS) add_flag_if_supported("-Werror=date-time" WERROR_DATE_TIME) if (LLVM_ENABLE_CXX1Y) check_cxx_compiler_flag("-std=c++1y" CXX_SUPPORTS_CXX1Y)