diff --git a/llvm/cmake/config-ix.cmake b/llvm/cmake/config-ix.cmake index 0aae13e30f2a..aba28e40d9a2 100644 --- a/llvm/cmake/config-ix.cmake +++ b/llvm/cmake/config-ix.cmake @@ -266,10 +266,10 @@ set(BACKTRACE_HEADER ${Backtrace_HEADER}) # Prevent check_symbol_exists from using API that is not supported for a given # deployment target. -check_c_compiler_flag("-Werror=unguarded-availability-new" "C_SUPPORTS_WERROR_UNGUARDED_AVAILABILITY_NEW") -if(C_SUPPORTS_WERROR_UNGUARDED_AVAILABILITY_NEW) - set(CMAKE_REQUIRED_FLAGS "${CMAKE_REQUIRED_FLAGS} -Werror=unguarded-availability-new") -endif() +#check_c_compiler_flag("-Werror=unguarded-availability-new" "C_SUPPORTS_WERROR_UNGUARDED_AVAILABILITY_NEW") +#if(C_SUPPORTS_WERROR_UNGUARDED_AVAILABILITY_NEW) +# set(CMAKE_REQUIRED_FLAGS "${CMAKE_REQUIRED_FLAGS} -Werror=unguarded-availability-new") +#endif() # Determine whether we can register EH tables. check_symbol_exists(__register_frame "${CMAKE_CURRENT_LIST_DIR}/unwind.h" HAVE_REGISTER_FRAME) diff --git a/llvm/cmake/modules/HandleLLVMOptions.cmake b/llvm/cmake/modules/HandleLLVMOptions.cmake index 5ca580fbb59c..ea0e026e5d31 100644 --- a/llvm/cmake/modules/HandleLLVMOptions.cmake +++ b/llvm/cmake/modules/HandleLLVMOptions.cmake @@ -668,9 +668,9 @@ if ( LLVM_COMPILER_IS_GCC_COMPATIBLE OR CMAKE_CXX_COMPILER_ID MATCHES "XL" ) append("-Werror=date-time" CMAKE_C_FLAGS CMAKE_CXX_FLAGS) endif( LLVM_COMPILER_IS_GCC_COMPATIBLE OR CMAKE_CXX_COMPILER_ID MATCHES "XL" ) -if (CMAKE_CXX_COMPILER_ID MATCHES "Clang") - append("-Werror=unguarded-availability-new" CMAKE_C_FLAGS CMAKE_CXX_FLAGS) -endif() +#if (CMAKE_CXX_COMPILER_ID MATCHES "Clang") +# append("-Werror=unguarded-availability-new" CMAKE_C_FLAGS CMAKE_CXX_FLAGS) +#endif() if (CMAKE_CXX_COMPILER_ID STREQUAL "GNU") # LLVM data structures like llvm::User and llvm::MDNode rely on