diff options
author | Ankit Meel <ankitjmeel@gmail.com> | 2021-04-23 23:24:30 +0300 |
---|---|---|
committer | Ankit Meel <ankitjmeel@gmail.com> | 2021-04-23 23:24:30 +0300 |
commit | aa95f8019e4204ea50210add1b2c2ed1934b92c9 (patch) | |
tree | a656569b0c171c7d162b139fab6fe6650f6aed02 /CMakeLists.txt | |
parent | c46367518827af5aebeb6377d0d04b59432b9107 (diff) |
macOS: Fix unknown -Wsuggest-override warning
Added in rB7cef01b090c4c2d2703274edb91886ae37d3ce82
and rB87bfa2b207b90b5e34ebd835a23c2a82afbed878
Reviewed by: jbakker, #platform_macos
Differential Revision: https://developer.blender.org/D11012
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r-- | CMakeLists.txt | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index ba863cf32b6..f315fa87236 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1526,6 +1526,7 @@ if(CMAKE_COMPILER_IS_GNUCC) ADD_CHECK_CXX_COMPILER_FLAG(CXX_WARNINGS CXX_WARN_UNDEF -Wundef) ADD_CHECK_CXX_COMPILER_FLAG(CXX_WARNINGS CXX_WARN_FORMAT_SIGN -Wformat-signedness) ADD_CHECK_CXX_COMPILER_FLAG(CXX_WARNINGS CXX_WARN_RESTRICT -Wrestrict) + ADD_CHECK_CXX_COMPILER_FLAG(CXX_WARNINGS CXX_WARN_NO_SUGGEST_OVERRIDE -Wno-suggest-override) # gcc 4.2 gives annoying warnings on every file with this if(NOT "${CMAKE_C_COMPILER_VERSION}" VERSION_LESS "4.3") @@ -1589,6 +1590,8 @@ elseif(CMAKE_C_COMPILER_ID MATCHES "Clang") ADD_CHECK_CXX_COMPILER_FLAG(CXX_WARNINGS CXX_WARN_NO_OVERLOADED_VIRTUAL -Wno-overloaded-virtual) # we get a lot of these, if its a problem a dev needs to look into it. ADD_CHECK_CXX_COMPILER_FLAG(CXX_WARNINGS CXX_WARN_NO_SIGN_COMPARE -Wno-sign-compare) ADD_CHECK_CXX_COMPILER_FLAG(CXX_WARNINGS CXX_WARN_NO_INVALID_OFFSETOF -Wno-invalid-offsetof) + # Apple Clang (tested on version 12) doesn't support this flag while LLVM Clang 11 does. + ADD_CHECK_CXX_COMPILER_FLAG(CXX_WARNINGS CXX_WARN_NO_SUGGEST_OVERRIDE -Wno-suggest-override) # gives too many unfixable warnings # ADD_CHECK_C_COMPILER_FLAG(C_WARNINGS C_WARN_UNUSED_MACROS -Wunused-macros) |