Fixed compilation on Linux (#15127)

This commit is contained in:
Ilya Lavrenov
2023-01-16 11:01:33 +04:00
committed by GitHub
parent 372699ec49
commit 53e9d7acea
3 changed files with 6 additions and 2 deletions

View File

@@ -80,6 +80,10 @@ list(REMOVE_ITEM SOURCES "${CMAKE_CURRENT_SOURCE_DIR}/dldt_optimization_guide2.c
"${CMAKE_CURRENT_SOURCE_DIR}/dldt_optimization_guide3.cpp"
"${CMAKE_CURRENT_SOURCE_DIR}/dldt_optimization_guide4.cpp")
# build separatelly as ov_integration_snippet and ov_integration_snippet_c
list(REMOVE_ITEM SOURCES "${CMAKE_CURRENT_SOURCE_DIR}/src/main.c"
"${CMAKE_CURRENT_SOURCE_DIR}/src/main.cpp")
# create a static library
add_library(${TARGET_NAME} STATIC ${SOURCES})

View File

@@ -6,7 +6,7 @@
#include <openvino/c/openvino.h>
//! [include]
int main_c() {
int main() {
//! [part1]
ov_core_t* core = NULL;
ov_core_create(&core);

View File

@@ -6,7 +6,7 @@
#include <openvino/openvino.hpp>
//! [include]
int main_cpp() {
int main() {
//! [part1]
ov::Core core;
//! [part1]