diff options
author | Chandler Carruth <chandlerc@gmail.com> | 2017-01-04 23:40:06 +0000 |
---|---|---|
committer | Chandler Carruth <chandlerc@gmail.com> | 2017-01-04 23:40:06 +0000 |
commit | dd9c27b3bf77b947ba0bb08ed1ba1ae673b9f067 (patch) | |
tree | 1a723c10b6e0dfe1387d5e82b534a80d6f8d031a /llvm/cmake/modules | |
parent | e5b41f7ccf965756a2fca2e96208bb5885b48b21 (diff) | |
download | bcm5719-llvm-dd9c27b3bf77b947ba0bb08ed1ba1ae673b9f067.tar.gz bcm5719-llvm-dd9c27b3bf77b947ba0bb08ed1ba1ae673b9f067.zip |
[gtest] Fix the way we disable a warning for unittests.
I somehow wrote this fix and then lost it prior to commit. Really sorry
about the noise. This should fix some issues with hacking add_definition
to do things with warning flags.
llvm-svn: 291033
Diffstat (limited to 'llvm/cmake/modules')
-rw-r--r-- | llvm/cmake/modules/AddLLVM.cmake | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/llvm/cmake/modules/AddLLVM.cmake b/llvm/cmake/modules/AddLLVM.cmake index f35fcf444d2..fbef1d04eac 100644 --- a/llvm/cmake/modules/AddLLVM.cmake +++ b/llvm/cmake/modules/AddLLVM.cmake @@ -1014,6 +1014,10 @@ function(add_unittest test_suite test_name) if (SUPPORTS_NO_VARIADIC_MACROS_FLAG) list(APPEND LLVM_COMPILE_FLAGS "-Wno-variadic-macros") endif () + # Some parts of gtest rely on this GNU extension, don't warn on it. + if(SUPPORTS_NO_GNU_ZERO_VARIADIC_MACRO_ARGUMENTS_FLAG) + list(APPEND LLVM_COMPILE_FLAGS "-Wno-gnu-zero-variadic-macro-arguments") + endif() set(LLVM_REQUIRES_RTTI OFF) |