diff --git a/modules/dnn/3rdparty/protobuf/CMakeLists.txt b/modules/dnn/3rdparty/protobuf/CMakeLists.txt index eb4ebbe72..7aa669851 100644 --- a/modules/dnn/3rdparty/protobuf/CMakeLists.txt +++ b/modules/dnn/3rdparty/protobuf/CMakeLists.txt @@ -22,6 +22,11 @@ else() -Wunused-function -Wunused-const-variable ) endif() +if(CV_ICC) + ocv_warnings_disable(CMAKE_CXX_FLAGS + -wd265 -wd858 -wd873 -wd2196 + ) +endif() # Easier to support different versions of protobufs function(append_if_exist OUTPUT_LIST) diff --git a/modules/dnn/cmake/OpenCVFindLibProtobuf.cmake b/modules/dnn/cmake/OpenCVFindLibProtobuf.cmake index 572770585..25b4f4760 100644 --- a/modules/dnn/cmake/OpenCVFindLibProtobuf.cmake +++ b/modules/dnn/cmake/OpenCVFindLibProtobuf.cmake @@ -47,8 +47,10 @@ endif() add_definitions(-DHAVE_PROTOBUF=1) #supress warnings in autogenerated caffe.pb.* files -ocv_warnings_disable(CMAKE_CXX_FLAGS -Wunused-parameter -Wundef -Wignored-qualifiers -Wno-enum-compare - -Wdeprecated-declarations) -ocv_warnings_disable(CMAKE_CXX_FLAGS /wd4125 /wd4267 /wd4127 /wd4244 /wd4512 /wd4702 - /wd4456 /wd4510 /wd4610 /wd4800 +ocv_warnings_disable(CMAKE_CXX_FLAGS + -Wunused-parameter -Wundef -Wignored-qualifiers -Wno-enum-compare + -Wdeprecated-declarations + /wd4125 /wd4267 /wd4127 /wd4244 /wd4512 /wd4702 + /wd4456 /wd4510 /wd4610 /wd4800 + -wd858 -wd2196 ) diff --git a/modules/saliency/CMakeLists.txt b/modules/saliency/CMakeLists.txt index e32058e3f..1d0d40ee2 100644 --- a/modules/saliency/CMakeLists.txt +++ b/modules/saliency/CMakeLists.txt @@ -1,3 +1,7 @@ +if(CV_ICC AND NOT MSVC) + ocv_module_disable(saliency) +endif() + set(the_description "Saliency API") set(OPENCV_MODULE_IS_PART_OF_WORLD OFF)