diff options
author | Chris Robinson <[email protected]> | 2019-09-11 15:55:37 -0700 |
---|---|---|
committer | Chris Robinson <[email protected]> | 2019-09-11 15:55:37 -0700 |
commit | 474d478854ef2ec46bf7b0cb6148c91b7fb8cc2c (patch) | |
tree | a96aa559670d3efba19f3fdc86289661853d804f | |
parent | 07e2aa3bc0c7dde66b332e400f71bfd0d9cb1c5f (diff) |
Only pass -Wold-style-cast for C++
-rw-r--r-- | CMakeLists.txt | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index c37a2d18..4effb94a 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -220,7 +220,7 @@ IF(MSVC) ENDFOREACH(flag_var) ENDIF() ELSE() - SET(C_FLAGS ${C_FLAGS} -Winline -Wall -Wold-style-cast) + SET(C_FLAGS ${C_FLAGS} -Winline -Wall $<$<COMPILE_LANGUAGE:CXX>:-Wold-style-cast>) CHECK_C_COMPILER_FLAG(-Wextra HAVE_W_EXTRA) IF(HAVE_W_EXTRA) SET(C_FLAGS ${C_FLAGS} -Wextra) |