[PATCH] D31702: Append -w when LLVM_ENABLE_WARNINGS is Off.
Vassil Vassilev via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Wed Apr 5 02:35:08 PDT 2017
v.g.vassilev created this revision.
Herald added a subscriber: mgorny.
This is very useful for projects which embed LLVM in their codebases.
Repository:
rL LLVM
https://reviews.llvm.org/D31702
Files:
cmake/modules/HandleLLVMOptions.cmake
Index: cmake/modules/HandleLLVMOptions.cmake
===================================================================
--- cmake/modules/HandleLLVMOptions.cmake
+++ cmake/modules/HandleLLVMOptions.cmake
@@ -559,6 +559,8 @@
# Enable -Wstring-conversion to catch misuse of string literals.
add_flag_if_supported("-Wstring-conversion" STRING_CONVERSION_FLAG)
+else()
+ append("-w" CMAKE_C_FLAGS CMAKE_CXX_FLAGS)
endif (LLVM_ENABLE_WARNINGS AND (LLVM_COMPILER_IS_GCC_COMPATIBLE OR CLANG_CL))
macro(append_common_sanitizer_flags)
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D31702.94178.patch
Type: text/x-patch
Size: 532 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20170405/e4530cb9/attachment.bin>
More information about the cfe-commits
mailing list