Disable add_cxx_compiler_flag calls for MSVC.

GitOrigin-RevId: 2b440e969d892240bc0e78a8c1b07e9ef74e1cc2
This commit is contained in:
levlam 2018-02-22 20:20:22 +03:00
parent 35d0ac2985
commit 81b3afe762

View File

@ -158,7 +158,6 @@ endif()
include(AddCXXCompilerFlag) include(AddCXXCompilerFlag)
if (NOT MSVC) if (NOT MSVC)
add_cxx_compiler_flag("-Wall") add_cxx_compiler_flag("-Wall")
endif()
add_cxx_compiler_flag("-Wextra") add_cxx_compiler_flag("-Wextra")
add_cxx_compiler_flag("-Wimplicit-fallthrough=2") add_cxx_compiler_flag("-Wimplicit-fallthrough=2")
add_cxx_compiler_flag("-Wpointer-arith") add_cxx_compiler_flag("-Wpointer-arith")
@ -185,10 +184,11 @@ add_cxx_compiler_flag("-flto-odr-type-merging")
# add_cxx_compiler_flag("-Wcast-align") # add_cxx_compiler_flag("-Wcast-align")
#std::int32_t <-> int and off_t <-> std::size_t/std::int64_t #std::int32_t <-> int and off_t <-> std::size_t/std::int64_t
#set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wuseless-cast") # add_cxx_compiler_flag("-Wuseless-cast")
#external headers like openssl #external headers like openssl
#set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wzero-as-null-pointer-constant") # add_cxx_compiler_flag("-Wzero-as-null-pointer-constant")
endif()
#set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -isystem /usr/include/c++/v1") #set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -isystem /usr/include/c++/v1")
#set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -stdlib=libc++") #set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -stdlib=libc++")