Fixed build with cmake 3.21 (#6757)

This commit is contained in:
Ilya Lavrenov authored and GitHub committed 2021-07-22 19:55:38 +03:00
1 parent bfdd1a199f
commit eaa5a22979
9 files changed
+15 -11

No files matched your search

+1 -1
View File
@@ -34,7 +34,7 @@ macro(onnx_set_target_properties)
if(CMAKE_CXX_COMPILER_ID STREQUAL "MSVC")
target_compile_options(onnx PRIVATE /WX-)
elseif(CMAKE_COMPILER_IS_GNUCXX OR CMAKE_CXX_COMPILER_ID MATCHES "^(Apple)?Clang$")
elseif(CMAKE_COMPILER_IS_GNUCXX OR OV_COMPILER_IS_CLANG)
target_compile_options(onnx PRIVATE -Wno-all)
target_compile_options(onnx_proto PRIVATE -Wno-all -Wno-unused-variable)
+1 -1
View File
@@ -65,7 +65,7 @@ if(NGRAPH_USE_PROTOBUF_LITE)
target_compile_definitions(onnx_importer PRIVATE NGRAPH_USE_PROTOBUF_LITE)
endif()
if (CMAKE_CXX_COMPILER_ID MATCHES "^(Apple)?Clang$")
if (OV_COMPILER_IS_CLANG)
target_compile_options(onnx_importer PRIVATE -Wno-undef -Wno-reserved-id-macro -Wno-switch-enum
-Wno-invalid-offsetof -Wno-shorten-64-to-32 -Wno-unused-macros -Wno-missing-variable-declarations
-Wno-unused-private-field -Wno-shadow -Wno-deprecated PUBLIC -Wno-undefined-func-template)