Skip to content

Commit

Permalink
Removed a lot -Wno-* compile options
Browse files Browse the repository at this point in the history
  • Loading branch information
ilya-lavrenov committed Jul 20, 2021
1 parent b1dd8f8 commit e64ef4a
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 6 deletions.
2 changes: 1 addition & 1 deletion inference-engine/src/mkldnn_plugin/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ ie_mark_target_as_cc(${TARGET_NAME})

if(SELECTIVE_BUILD STREQUAL "ON")
# After disabling a block of code, some variables might be unused.
if(CMAKE_COMPILER_IS_GNUCXX)
if(CMAKE_COMPILER_IS_GNUCXX OR OV_COMPILER_IS_CLANG)
target_compile_options(${TARGET_NAME} PRIVATE -Wno-unused-variable)
endif()
endif()
Expand Down
6 changes: 2 additions & 4 deletions ngraph/frontend/onnx/onnx_import/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -63,10 +63,8 @@ if(NGRAPH_USE_PROTOBUF_LITE)
target_compile_definitions(onnx_importer PRIVATE NGRAPH_USE_PROTOBUF_LITE)
endif()

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)
if(OV_COMPILER_IS_CLANG)
target_compile_options(onnx_importer PRIVATE -Wno-undef)
endif()

install(TARGETS onnx_importer EXPORT ngraphTargets
Expand Down
2 changes: 1 addition & 1 deletion openvino/conditional_compilation/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ elseif(SELECTIVE_BUILD STREQUAL "ON")

target_compile_definitions(${TARGET_NAME} INTERFACE SELECTIVE_BUILD)

if(CMAKE_CXX_COMPILER_ID STREQUAL "GNU" OV_COMPILER_IS_CLANG)
if(CMAKE_CXX_COMPILER_ID STREQUAL "GNU" OR OV_COMPILER_IS_CLANG)
# After disabling a block of code, some variables might be unused.
target_compile_options(${TARGET_NAME} INTERFACE
-Wno-unused-function
Expand Down

0 comments on commit e64ef4a

Please sign in to comment.