From 096598691de246c23902d49d228c7562ba2c9cc5 Mon Sep 17 00:00:00 2001 From: Chin Huat Ang Date: Fri, 27 Sep 2019 06:11:51 +0800 Subject: dldt-inference-engine: add recipe MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This recipe builds the inference engine from opencv/dldt 2019 R1.1 release. OpenVINO™ toolkit, short for Open Visual Inference and Neural network Optimization toolkit, provides developers with improved neural network performance on a variety of Intel® processors and helps further unlock cost-effective, real-time vision applications. The toolkit enables deep learning inference and easy heterogeneous execution across multiple Intel® platforms (CPU, Intel® Processor Graphics)—providing implementations across cloud architectures to edge device. For more details, see: https://01.org/openvinotoolkit The recipe needs components from meta-oe so move it to dynamic-layers/openembedded-layer. GPU plugin support needs intel-compute-runtime which can be built by including clang layer in the mix as well. CPU and GPU plugins have been sanity tested to work using classification_sample. Further fine-tuning is still needed to improve the performance. Original patch by Anuj Mittal. Signed-off-by: Chin Huat Ang Signed-off-by: Anuj Mittal --- .../files/0001-Supply-firmware-at-build-time.patch | 45 +++++++ .../opencv/files/0001-disable-tests.patch | 40 +++++++ .../opencv/files/0001-disable-werror.patch | 82 +++++++++++++ .../opencv/files/0001-fix-openmp-checking.patch | 61 ++++++++++ .../opencv/files/0001-use-provided-paths.patch | 33 ++++++ .../0002-use-ade-and-pugixml-from-system.patch | 32 +++++ ...all-sample-apps-and-format_reader-library.patch | 130 +++++++++++++++++++++ 7 files changed, 423 insertions(+) create mode 100644 dynamic-layers/openembedded-layer/recipes-support/opencv/files/0001-Supply-firmware-at-build-time.patch create mode 100644 dynamic-layers/openembedded-layer/recipes-support/opencv/files/0001-disable-tests.patch create mode 100644 dynamic-layers/openembedded-layer/recipes-support/opencv/files/0001-disable-werror.patch create mode 100644 dynamic-layers/openembedded-layer/recipes-support/opencv/files/0001-fix-openmp-checking.patch create mode 100644 dynamic-layers/openembedded-layer/recipes-support/opencv/files/0001-use-provided-paths.patch create mode 100644 dynamic-layers/openembedded-layer/recipes-support/opencv/files/0002-use-ade-and-pugixml-from-system.patch create mode 100644 dynamic-layers/openembedded-layer/recipes-support/opencv/files/0007-Install-sample-apps-and-format_reader-library.patch (limited to 'dynamic-layers/openembedded-layer/recipes-support/opencv/files') diff --git a/dynamic-layers/openembedded-layer/recipes-support/opencv/files/0001-Supply-firmware-at-build-time.patch b/dynamic-layers/openembedded-layer/recipes-support/opencv/files/0001-Supply-firmware-at-build-time.patch new file mode 100644 index 00000000..dcc65ed6 --- /dev/null +++ b/dynamic-layers/openembedded-layer/recipes-support/opencv/files/0001-Supply-firmware-at-build-time.patch @@ -0,0 +1,45 @@ +From e58226a399be7cf2cc6d91b66facb65d7dfb5018 Mon Sep 17 00:00:00 2001 +From: Anuj Mittal +Date: Tue, 20 Aug 2019 15:40:18 +0800 +Subject: [PATCH] Supply firmware at build time + +We'd like to supply firmware when fetching the sources. Disable runtime +fetching and point to fetched firmware instead. + +Upstream-Status: Submitted + +Signed-off-by: Anuj Mittal + +--- + inference-engine/cmake/dependencies.cmake | 18 ------------------ + 1 file changed, 18 deletions(-) + +diff --git a/inference-engine/cmake/dependencies.cmake b/inference-engine/cmake/dependencies.cmake +index 64435ca..217fbc9 100644 +--- a/inference-engine/cmake/dependencies.cmake ++++ b/inference-engine/cmake/dependencies.cmake +@@ -37,24 +37,6 @@ else() + set(MODELS_BRANCH "master") + endif() + +-if (ENABLE_MYRIAD) +- RESOLVE_DEPENDENCY(VPU_FIRMWARE_MA2450 +- ARCHIVE_UNIFIED firmware_ma2450_491.zip +- TARGET_PATH "${TEMP}/vpu/firmware/ma2450" +- ENVIRONMENT "VPU_FIRMWARE_MA2450" +- FOLDER) +- debug_message(STATUS "ma2450=" ${VPU_FIRMWARE_MA2450}) +-endif () +- +-if (ENABLE_MYRIAD) +- RESOLVE_DEPENDENCY(VPU_FIRMWARE_MA2480 +- ARCHIVE_UNIFIED firmware_ma2480_mdk_R7_9.zip +- TARGET_PATH "${TEMP}/vpu/firmware/ma2480" +- ENVIRONMENT "VPU_FIRMWARE_MA2480" +- FOLDER) +- debug_message(STATUS "ma2480=" ${VPU_FIRMWARE_MA2480}) +-endif () +- + ## enable cblas_gemm from OpenBLAS package + if (GEMM STREQUAL "OPENBLAS") + if(NOT BLAS_LIBRARIES OR NOT BLAS_INCLUDE_DIRS) diff --git a/dynamic-layers/openembedded-layer/recipes-support/opencv/files/0001-disable-tests.patch b/dynamic-layers/openembedded-layer/recipes-support/opencv/files/0001-disable-tests.patch new file mode 100644 index 00000000..af6febde --- /dev/null +++ b/dynamic-layers/openembedded-layer/recipes-support/opencv/files/0001-disable-tests.patch @@ -0,0 +1,40 @@ +From 888db5ced39bba933753c7f8b0b0ef4f900578a9 Mon Sep 17 00:00:00 2001 +From: Anuj Mittal +Date: Tue, 27 Aug 2019 08:06:46 +0800 +Subject: [PATCH] disable tests + +Disable tests for now since they build a local copy of gflags etc. + +Upstream-Status: Inappropriate [Configuration] + +Signed-off-by: Anuj Mittal + +--- + inference-engine/CMakeLists.txt | 1 - + inference-engine/samples/CMakeLists.txt | 1 - + 2 files changed, 2 deletions(-) + +diff --git a/inference-engine/CMakeLists.txt b/inference-engine/CMakeLists.txt +index 9e15382..bdf874e 100644 +--- a/inference-engine/CMakeLists.txt ++++ b/inference-engine/CMakeLists.txt +@@ -131,7 +131,6 @@ include(CheckCXXCompilerFlag) + include(cpplint) + + add_subdirectory(src) +-add_subdirectory(tests) + add_subdirectory(thirdparty) + set(InferenceEngine_DIR "${CMAKE_BINARY_DIR}") + +diff --git a/inference-engine/samples/CMakeLists.txt b/inference-engine/samples/CMakeLists.txt +index 4e13c11..a8a9946 100644 +--- a/inference-engine/samples/CMakeLists.txt ++++ b/inference-engine/samples/CMakeLists.txt +@@ -93,7 +93,6 @@ set (GFLAGS_IS_SUBPROJECT TRUE) + set (HAVE_SYS_STAT_H 1) + set (HAVE_INTTYPES_H 1) + +-add_subdirectory(thirdparty/gflags) + + if (${CMAKE_CXX_COMPILER_ID} STREQUAL GNU) + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall") diff --git a/dynamic-layers/openembedded-layer/recipes-support/opencv/files/0001-disable-werror.patch b/dynamic-layers/openembedded-layer/recipes-support/opencv/files/0001-disable-werror.patch new file mode 100644 index 00000000..5ba1e763 --- /dev/null +++ b/dynamic-layers/openembedded-layer/recipes-support/opencv/files/0001-disable-werror.patch @@ -0,0 +1,82 @@ +From 434cf332e8c368b626d230b79e8dccecf2b0525b Mon Sep 17 00:00:00 2001 +From: Anuj Mittal +Date: Tue, 20 Aug 2019 19:39:37 +0800 +Subject: [PATCH] disable werror + +This shouldn't be enabled and leads to multiple errors when compiling cldnn. + +Upstream-Status: Submitted + +Signed-off-by: Anuj Mittal + +--- + inference-engine/cmake/os_flags.cmake | 2 +- + inference-engine/samples/CMakeLists.txt | 1 - + inference-engine/thirdparty/clDNN/CMakeLists.txt | 2 -- + inference-engine/thirdparty/mkl-dnn/cmake/platform.cmake | 1 - + inference-engine/tools/CMakeLists.txt | 2 -- + 5 files changed, 1 insertion(+), 7 deletions(-) + +diff --git a/inference-engine/cmake/os_flags.cmake b/inference-engine/cmake/os_flags.cmake +index 29608ea..2c189d8 100644 +--- a/inference-engine/cmake/os_flags.cmake ++++ b/inference-engine/cmake/os_flags.cmake +@@ -28,7 +28,7 @@ if (WIN32) + endif() + + else() +- set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Werror -Werror=return-type ") ++ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Werror=return-type ") + if (APPLE) + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-error=unused-command-line-argument") + elseif(UNIX) +diff --git a/inference-engine/samples/CMakeLists.txt b/inference-engine/samples/CMakeLists.txt +index a8a9946..8ac5454 100644 +--- a/inference-engine/samples/CMakeLists.txt ++++ b/inference-engine/samples/CMakeLists.txt +@@ -68,7 +68,6 @@ if (WIN32) + set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /wd4251 /wd4275 /wd4267") #disable some warnings + endif() + else() +- set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Werror") #treating warnings as errors + if (APPLE) + set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-error=unused-command-line-argument") + elseif(UNIX) +diff --git a/inference-engine/thirdparty/clDNN/CMakeLists.txt b/inference-engine/thirdparty/clDNN/CMakeLists.txt +index 624d95c..5646ff1 100644 +--- a/inference-engine/thirdparty/clDNN/CMakeLists.txt ++++ b/inference-engine/thirdparty/clDNN/CMakeLists.txt +@@ -757,8 +757,6 @@ foreach(__CLDNN_CompilerFlagName IN ITEMS "CMAKE_CXX_FLAGS" "CMAKE_C_FLAGS") + MultiProcessorCompilation + DeadCodeEliminate + ExtensionsEnabled +- TreatWarnAsErrorEnabled +- WarnLevel4 + NoFastMath + StackProtector + ) +diff --git a/inference-engine/thirdparty/mkl-dnn/cmake/platform.cmake b/inference-engine/thirdparty/mkl-dnn/cmake/platform.cmake +index a541215..bed8a59 100644 +--- a/inference-engine/thirdparty/mkl-dnn/cmake/platform.cmake ++++ b/inference-engine/thirdparty/mkl-dnn/cmake/platform.cmake +@@ -63,7 +63,6 @@ if(MSVC) + endif() + elseif(UNIX OR MINGW) + append(CMAKE_CCXX_FLAGS "-Wall -Wno-unknown-pragmas") +- append_if_product(CMAKE_CCXX_FLAGS "-Werror") + append(CMAKE_CCXX_FLAGS "-fvisibility=internal") + append(CMAKE_C_FLAGS "-std=c99") + append(CMAKE_CXX_FLAGS "-std=c++11 -fvisibility-inlines-hidden") +diff --git a/inference-engine/tools/CMakeLists.txt b/inference-engine/tools/CMakeLists.txt +index 13ab365..feacf33 100644 +--- a/inference-engine/tools/CMakeLists.txt ++++ b/inference-engine/tools/CMakeLists.txt +@@ -23,8 +23,6 @@ endif() + + if (WIN32) + # add_compile_options("/WX") +-else() +- add_compile_options("-Werror") + endif() + + add_subdirectory(vpu) diff --git a/dynamic-layers/openembedded-layer/recipes-support/opencv/files/0001-fix-openmp-checking.patch b/dynamic-layers/openembedded-layer/recipes-support/opencv/files/0001-fix-openmp-checking.patch new file mode 100644 index 00000000..6053a315 --- /dev/null +++ b/dynamic-layers/openembedded-layer/recipes-support/opencv/files/0001-fix-openmp-checking.patch @@ -0,0 +1,61 @@ +From 46520b6fa766aabcb8c8bc0ead485d30bae965ea Mon Sep 17 00:00:00 2001 +From: Chin Huat Ang +Date: Tue, 20 Aug 2019 12:20:33 +0800 +Subject: [PATCH] fix openmp checking + +Make sure that we supply -fopenmp when using OpenMP supplied by compiler +and dont look for it locally. + +Upstream-Status: Submitted +Signed-off-by: Anuj Mittal +Signed-off-by: Chin Huat Ang +--- + inference-engine/cmake/dependencies.cmake | 6 +----- + inference-engine/cmake/ie_parallel.cmake | 4 ++-- + inference-engine/src/mkldnn_plugin/CMakeLists.txt | 1 + + 3 files changed, 4 insertions(+), 7 deletions(-) + +diff --git a/inference-engine/cmake/dependencies.cmake b/inference-engine/cmake/dependencies.cmake +index d3cdf95..64435ca 100644 +--- a/inference-engine/cmake/dependencies.cmake ++++ b/inference-engine/cmake/dependencies.cmake +@@ -86,11 +86,7 @@ if (WIN32) + ENVIRONMENT "OMP" + VERSION_REGEX ".*_([a-z]*_([a-z0-9]+\\.)*[0-9]+).*") + elseif(LINUX) +- RESOLVE_DEPENDENCY(OMP +- ARCHIVE_LIN "iomp.tgz" +- TARGET_PATH "${TEMP}/omp" +- ENVIRONMENT "OMP" +- VERSION_REGEX ".*_([a-z]*_([a-z0-9]+\\.)*[0-9]+).*") ++ set(OMP "-fopenmp") + else(APPLE) + RESOLVE_DEPENDENCY(OMP + ARCHIVE_MAC "iomp_20190130_mac.tgz" +diff --git a/inference-engine/cmake/ie_parallel.cmake b/inference-engine/cmake/ie_parallel.cmake +index 18ccdf0..2738ee5 100644 +--- a/inference-engine/cmake/ie_parallel.cmake ++++ b/inference-engine/cmake/ie_parallel.cmake +@@ -68,8 +68,8 @@ function(set_ie_threading_interface_for TARGET_NAME) + endif () + + if (NOT OMP_LIBRARIES_RELEASE OR NOT OMP_LIBRARIES_DEBUG) +- find_library(OMP_LIBRARIES_RELEASE ${omp_lib_name} ${lib_rel_path} NO_DEFAULT_PATH) +- find_library(OMP_LIBRARIES_DEBUG ${omp_lib_name} ${lib_dbg_path} NO_DEFAULT_PATH) ++ find_library(OMP_LIBRARIES_RELEASE ${omp_lib_name}) ++ find_library(OMP_LIBRARIES_DEBUG ${omp_lib_name}) + ext_message(STATUS "OMP Release lib: ${OMP_LIBRARIES_RELEASE}") + ext_message(STATUS "OMP Debug lib: ${OMP_LIBRARIES_DEBUG}") + endif () +diff --git a/inference-engine/src/mkldnn_plugin/CMakeLists.txt b/inference-engine/src/mkldnn_plugin/CMakeLists.txt +index df81a5a..96c7f1c 100644 +--- a/inference-engine/src/mkldnn_plugin/CMakeLists.txt ++++ b/inference-engine/src/mkldnn_plugin/CMakeLists.txt +@@ -50,6 +50,7 @@ if (THREADING STREQUAL "TBB") + set(MKLDNN_THR MKLDNN_THR_TBB) + elseif (THREADING STREQUAL "OMP") + set(MKLDNN_THR MKLDNN_THR_OMP) ++ target_link_options(${TARGET_NAME} PRIVATE -fopenmp) + else() + set(MKLDNN_THR MKLDNN_THR_SEQ) + endif() diff --git a/dynamic-layers/openembedded-layer/recipes-support/opencv/files/0001-use-provided-paths.patch b/dynamic-layers/openembedded-layer/recipes-support/opencv/files/0001-use-provided-paths.patch new file mode 100644 index 00000000..d20ea111 --- /dev/null +++ b/dynamic-layers/openembedded-layer/recipes-support/opencv/files/0001-use-provided-paths.patch @@ -0,0 +1,33 @@ +From 3700b244d0906f339f33bcdbfc198f3ba97bf1a0 Mon Sep 17 00:00:00 2001 +From: Anuj Mittal +Date: Tue, 20 Aug 2019 15:58:04 +0800 +Subject: [PATCH] use provided paths + +Use the CMake paths provided by environment instead of hardcoding them here. + +Upstream-Status: Pending +Signed-off-by: Anuj Mittal + +--- + inference-engine/CMakeLists.txt | 8 -------- + 1 file changed, 8 deletions(-) + +diff --git a/inference-engine/CMakeLists.txt b/inference-engine/CMakeLists.txt +index 1c3d6ea..9e15382 100644 +--- a/inference-engine/CMakeLists.txt ++++ b/inference-engine/CMakeLists.txt +@@ -99,14 +99,6 @@ if(NOT(UNIX)) + set (CMAKE_RUNTIME_OUTPUT_DIRECTORY ${OUTPUT_ROOT}/${BIN_FOLDER}) + set (LIBRARY_OUTPUT_DIRECTORY ${OUTPUT_ROOT}/${BIN_FOLDER}) + set (LIBRARY_OUTPUT_PATH ${LIBRARY_OUTPUT_DIRECTORY}) # compatibility issue: linux uses LIBRARY_OUTPUT_PATH, windows uses LIBRARY_OUTPUT_DIRECTORY +-else () +- set (CMAKE_LIBRARY_OUTPUT_DIRECTORY ${OUTPUT_ROOT}/${BIN_FOLDER}/${IE_BUILD_CONFIGURATION}/lib) +- set (CMAKE_ARCHIVE_OUTPUT_DIRECTORY ${OUTPUT_ROOT}/${BIN_FOLDER}/${IE_BUILD_CONFIGURATION}/lib) +- set (CMAKE_COMPILE_PDB_OUTPUT_DIRECTORY ${OUTPUT_ROOT}/${BIN_FOLDER}/${IE_BUILD_CONFIGURATION}) +- set (CMAKE_PDB_OUTPUT_DIRECTORY ${OUTPUT_ROOT}/${BIN_FOLDER}/${IE_BUILD_CONFIGURATION}) +- set (CMAKE_RUNTIME_OUTPUT_DIRECTORY ${OUTPUT_ROOT}/${BIN_FOLDER}/${IE_BUILD_CONFIGURATION}) +- set (LIBRARY_OUTPUT_DIRECTORY ${OUTPUT_ROOT}/${BIN_FOLDER}/${IE_BUILD_CONFIGURATION}/lib) +- set (LIBRARY_OUTPUT_PATH ${LIBRARY_OUTPUT_DIRECTORY}/lib) + endif() + + if (APPLE) diff --git a/dynamic-layers/openembedded-layer/recipes-support/opencv/files/0002-use-ade-and-pugixml-from-system.patch b/dynamic-layers/openembedded-layer/recipes-support/opencv/files/0002-use-ade-and-pugixml-from-system.patch new file mode 100644 index 00000000..8af9527e --- /dev/null +++ b/dynamic-layers/openembedded-layer/recipes-support/opencv/files/0002-use-ade-and-pugixml-from-system.patch @@ -0,0 +1,32 @@ +From 6e225e85d5763e883128ee7b8a97ac247c46b465 Mon Sep 17 00:00:00 2001 +From: Anuj Mittal +Date: Tue, 20 Aug 2019 12:40:09 +0800 +Subject: [PATCH] use ade and pugixml from system + +Don't build a local copy and use the one from sysroot. + +Upstream-Status: Submitted + +Signed-off-by: Anuj Mittal +--- + inference-engine/thirdparty/CMakeLists.txt | 5 ++--- + 1 file changed, 2 insertions(+), 3 deletions(-) + +diff --git a/inference-engine/thirdparty/CMakeLists.txt b/inference-engine/thirdparty/CMakeLists.txt +index f65f38c..7f23e8f 100644 +--- a/inference-engine/thirdparty/CMakeLists.txt ++++ b/inference-engine/thirdparty/CMakeLists.txt +@@ -7,11 +7,10 @@ if("${CMAKE_CXX_COMPILER_ID}" STREQUAL "Clang") + set(CMAKE_CC_FLAGS "${CMAKE_CC_FLAGS} -Wno-unknown-warning-option -Wno-inconsistent-missing-override -Wno-pass-failed") + endif() + +-add_subdirectory(pugixml) +-export(TARGETS pugixml NAMESPACE IE:: APPEND FILE "${CMAKE_BINARY_DIR}/targets.cmake") ++# add_subdirectory(pugixml) ++# export(TARGETS pugixml NAMESPACE IE:: APPEND FILE "${CMAKE_BINARY_DIR}/targets.cmake") + + add_subdirectory(stb_lib) +-add_subdirectory(ade) + + if (ENABLE_CLDNN) + set(CLDNN__OUTPUT_BIN_DIR ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}) diff --git a/dynamic-layers/openembedded-layer/recipes-support/opencv/files/0007-Install-sample-apps-and-format_reader-library.patch b/dynamic-layers/openembedded-layer/recipes-support/opencv/files/0007-Install-sample-apps-and-format_reader-library.patch new file mode 100644 index 00000000..6f0eb517 --- /dev/null +++ b/dynamic-layers/openembedded-layer/recipes-support/opencv/files/0007-Install-sample-apps-and-format_reader-library.patch @@ -0,0 +1,130 @@ +From d96a9413face4e8540400848d9a25a5458bad74a Mon Sep 17 00:00:00 2001 +From: "Brett T. Warden" +Date: Mon, 28 Jan 2019 13:58:03 -0800 +Subject: [PATCH] Install sample apps and format_reader library + +Make sure that we install format_reader library as well. + +Upstream-Status: Submitted + +Signed-off-by: Chin Huat Ang +--- + inference-engine/samples/classification_sample/CMakeLists.txt | 1 + + inference-engine/samples/classification_sample_async/CMakeLists.txt | 1 + + inference-engine/samples/common/format_reader/CMakeLists.txt | 1 + + inference-engine/samples/hello_autoresize_classification/CMakeLists.txt | 1 + + inference-engine/samples/hello_classification/CMakeLists.txt | 1 + + inference-engine/samples/hello_request_classification/CMakeLists.txt | 1 + + inference-engine/samples/object_detection_sample_ssd/CMakeLists.txt | 1 + + inference-engine/samples/style_transfer_sample/CMakeLists.txt | 1 + + inference-engine/samples/validation_app/CMakeLists.txt | 1 + + 9 files changed, 9 insertions(+) + +diff --git a/inference-engine/samples/classification_sample/CMakeLists.txt b/inference-engine/samples/classification_sample/CMakeLists.txt +index 1dab0c9..b2c67ea 100644 +--- a/inference-engine/samples/classification_sample/CMakeLists.txt ++++ b/inference-engine/samples/classification_sample/CMakeLists.txt +@@ -16,6 +16,7 @@ link_directories(${LIB_FOLDER}) + + # Create library file from sources. + add_executable(${TARGET_NAME} ${SRC}) ++install(TARGETS ${TARGET_NAME} DESTINATION bin) + + set_target_properties(${TARGET_NAME} PROPERTIES "CMAKE_CXX_FLAGS" "${CMAKE_CXX_FLAGS} -fPIE" + COMPILE_PDB_NAME ${TARGET_NAME}) +diff --git a/inference-engine/samples/classification_sample_async/CMakeLists.txt b/inference-engine/samples/classification_sample_async/CMakeLists.txt +index 9e37440..3fc0082 100644 +--- a/inference-engine/samples/classification_sample_async/CMakeLists.txt ++++ b/inference-engine/samples/classification_sample_async/CMakeLists.txt +@@ -16,6 +16,7 @@ link_directories(${LIB_FOLDER}) + + # Create library file from sources. + add_executable(${TARGET_NAME} ${SRC}) ++install(TARGETS ${TARGET_NAME} DESTINATION bin) + + set_target_properties(${TARGET_NAME} PROPERTIES "CMAKE_CXX_FLAGS" "${CMAKE_CXX_FLAGS} -fPIE" + COMPILE_PDB_NAME ${TARGET_NAME}) +diff --git a/inference-engine/samples/common/format_reader/CMakeLists.txt b/inference-engine/samples/common/format_reader/CMakeLists.txt +index e3ecd58..cc30fec 100644 +--- a/inference-engine/samples/common/format_reader/CMakeLists.txt ++++ b/inference-engine/samples/common/format_reader/CMakeLists.txt +@@ -35,6 +35,7 @@ source_group("include" FILES ${LIBRARY_HEADERS}) + + # Create library file from sources. + add_library(${TARGET_NAME} SHARED ${MAIN_SRC} ${LIBRARY_HEADERS}) ++install(TARGETS ${TARGET_NAME} DESTINATION lib) + target_link_libraries(${TARGET_NAME} ${OpenCV_LIBRARIES}) + + if(CMAKE_VERSION VERSION_LESS "2.8.11") +diff --git a/inference-engine/samples/hello_autoresize_classification/CMakeLists.txt b/inference-engine/samples/hello_autoresize_classification/CMakeLists.txt +index 01deda6..5ef2900 100644 +--- a/inference-engine/samples/hello_autoresize_classification/CMakeLists.txt ++++ b/inference-engine/samples/hello_autoresize_classification/CMakeLists.txt +@@ -21,6 +21,7 @@ link_directories(${LIB_FOLDER}) + + # Create library file from sources. + add_executable(${TARGET_NAME} ${SRC}) ++install(TARGETS ${TARGET_NAME} DESTINATION bin) + + set_target_properties(${TARGET_NAME} PROPERTIES "CMAKE_CXX_FLAGS" "${CMAKE_CXX_FLAGS} -fPIE" + COMPILE_PDB_NAME ${TARGET_NAME}) +diff --git a/inference-engine/samples/hello_classification/CMakeLists.txt b/inference-engine/samples/hello_classification/CMakeLists.txt +index 845f7e9..276be87 100644 +--- a/inference-engine/samples/hello_classification/CMakeLists.txt ++++ b/inference-engine/samples/hello_classification/CMakeLists.txt +@@ -23,6 +23,7 @@ link_directories(${LIB_FOLDER}) + + # Create library file from sources. + add_executable(${TARGET_NAME} ${SRC}) ++install(TARGETS ${TARGET_NAME} DESTINATION bin) + + if(WIN32) + # This target supports UNICODE on Windows +diff --git a/inference-engine/samples/hello_request_classification/CMakeLists.txt b/inference-engine/samples/hello_request_classification/CMakeLists.txt +index c7dbb1e..3e5ab8f 100644 +--- a/inference-engine/samples/hello_request_classification/CMakeLists.txt ++++ b/inference-engine/samples/hello_request_classification/CMakeLists.txt +@@ -23,6 +23,7 @@ link_directories(${LIB_FOLDER}) + + # Create library file from sources. + add_executable(${TARGET_NAME} ${SRC}) ++install(TARGETS ${TARGET_NAME} DESTINATION bin) + + set_target_properties(${TARGET_NAME} PROPERTIES "CMAKE_CXX_FLAGS" "${CMAKE_CXX_FLAGS} -fPIE" + COMPILE_PDB_NAME ${TARGET_NAME}) +diff --git a/inference-engine/samples/object_detection_sample_ssd/CMakeLists.txt b/inference-engine/samples/object_detection_sample_ssd/CMakeLists.txt +index 436edc2..adba758 100644 +--- a/inference-engine/samples/object_detection_sample_ssd/CMakeLists.txt ++++ b/inference-engine/samples/object_detection_sample_ssd/CMakeLists.txt +@@ -21,6 +21,7 @@ link_directories(${LIB_FOLDER}) + + # Create library file from sources. + add_executable(${TARGET_NAME} ${MAIN_SRC} ${MAIN_HEADERS}) ++install(TARGETS ${TARGET_NAME} DESTINATION bin) + + add_dependencies(${TARGET_NAME} gflags) + +diff --git a/inference-engine/samples/style_transfer_sample/CMakeLists.txt b/inference-engine/samples/style_transfer_sample/CMakeLists.txt +index ac2a170..d8e624b 100644 +--- a/inference-engine/samples/style_transfer_sample/CMakeLists.txt ++++ b/inference-engine/samples/style_transfer_sample/CMakeLists.txt +@@ -22,6 +22,7 @@ link_directories(${LIB_FOLDER}) + + # Create library file from sources. + add_executable(${TARGET_NAME} ${MAIN_SRC} ${MAIN_HEADERS}) ++install(TARGETS ${TARGET_NAME} DESTINATION bin) + + add_dependencies(${TARGET_NAME} gflags) + +diff --git a/inference-engine/samples/validation_app/CMakeLists.txt b/inference-engine/samples/validation_app/CMakeLists.txt +index 87b337c..07f48b7 100644 +--- a/inference-engine/samples/validation_app/CMakeLists.txt ++++ b/inference-engine/samples/validation_app/CMakeLists.txt +@@ -36,6 +36,7 @@ link_directories(${LIB_FOLDER}) + + # Create library file from sources. + add_executable(${TARGET_NAME} ${MAIN_SRC} ${MAIN_HEADERS}) ++install(TARGETS ${TARGET_NAME} DESTINATION bin) + + set_target_properties(${TARGET_NAME} PROPERTIES "CMAKE_CXX_FLAGS" "${CMAKE_CXX_FLAGS} -fPIE" + COMPILE_PDB_NAME ${TARGET_NAME}) -- cgit v1.2.3-54-g00ecf