Fix CMake scripts --- --- a/docs/template_extension/CMakeLists.txt +++ b/docs/template_extension/CMakeLists.txt @@ -5,7 +5,10 @@ # [cmake:extension] set(TARGET_NAME "template_extension") -find_package(ngraph REQUIRED) +find_package(ngraph QUIET) +if(NOT ngraph_FOUND) + set(ngraph_DIR ${CMAKE_BINARY_DIR}/ngraph) +endif() find_package(InferenceEngine REQUIRED) file(GLOB_RECURSE SRC *.cpp) --- a/inference-engine/thirdparty/clDNN/CMakeLists.txt +++ b/inference-engine/thirdparty/clDNN/CMakeLists.txt @@ -465,8 +465,8 @@ # ====================================================================================================== # Check for python 2.7 interpreter (required tool). -find_package(PythonInterp 2.7) -if(NOT PYTHONINTERP_FOUND) +find_package(Python) +if(NOT Python_FOUND) message(WARNING "[clDNN] Project requires Python 2.7 interpreter to build (with python loader). CMake could not detect it correctly. If you have installed this interpreter, please disregard this warning or specify PYTHON_EXECUTABLE in CMake command-line." ) --- a/inference-engine/thirdparty/clDNN/kernel_selector/CMakeLists.txt +++ b/inference-engine/thirdparty/clDNN/kernel_selector/CMakeLists.txt @@ -167,7 +167,7 @@ # =================================== Custom pre- and post-steps ======================================= add_custom_command(OUTPUT "${__CLDNN_CGDirectory__cg_cache}/${__CLDNN_File__cg_cache__prim_db}" COMMAND "${CMAKE_COMMAND}" -E make_directory "${__CLDNN_CGDirectory__cg_cache}" - COMMAND "${PYTHON_EXECUTABLE}" "${__CLDNN_Directory__core_common}/primitive_db_gen.py" -out_path "${__CLDNN_CGDirectory__cg_cache}" -out_file_name "${__CLDNN_File__cg_cache__prim_db}" -kernels "${__CLDNN_Directory__cl_kernels}" + COMMAND "${Python_EXECUTABLE}" "${__CLDNN_Directory__core_common}/primitive_db_gen.py" -out_path "${__CLDNN_CGDirectory__cg_cache}" -out_file_name "${__CLDNN_File__cg_cache__prim_db}" -kernels "${__CLDNN_Directory__cl_kernels}" DEPENDS ${__CLDNN_Sources__cl_kernels} "${__CLDNN_Directory__core_common}/primitive_db_gen.py" COMMENT "Generating ${__CLDNN_File__cg_cache__prim_db} ..." ) --- a/ngraph/CMakeLists.txt +++ b/ngraph/CMakeLists.txt @@ -258,13 +258,8 @@ set(NGRAPH_INSTALL_DOC "${NGRAPH_COMPONENT_PREFIX}${CMAKE_INSTALL_DOCDIR}") set(NGRAPH_INSTALL_BIN "${NGRAPH_COMPONENT_PREFIX}${CMAKE_INSTALL_BINDIR}") if (LINUX) - if (DEFINED NGRAPH_RPATH) - set(CMAKE_BUILD_RPATH "$ORIGIN:${NGRAPH_RPATH}") - set(CMAKE_INSTALL_RPATH "$ORIGIN:${NGRAPH_RPATH}") - else() - set(CMAKE_BUILD_RPATH "$ORIGIN") - set(CMAKE_INSTALL_RPATH "$ORIGIN") - endif() + set(CMAKE_BUILD_RPATH "$ORIGIN") + set(CMAKE_INSTALL_RPATH "$ORIGIN") endif() #----------------------------------------------------------------------------------------------- --- a/inference-engine/src/inference_engine/CMakeLists.txt +++ b/inference-engine/src/inference_engine/CMakeLists.txt @@ -230,30 +230,6 @@ list(APPEND core_components ngraph) -if(THREADING STREQUAL "TBB" OR THREADING STREQUAL "TBB_AUTO") - ie_cpack_add_component(tbb REQUIRED) - list(APPEND core_components tbb) - - install(DIRECTORY "${TBB}/include" - DESTINATION ${IE_CPACK_IE_DIR}/external/tbb - COMPONENT tbb) - install(DIRECTORY "${TBB}/lib" - DESTINATION ${IE_CPACK_IE_DIR}/external/tbb - COMPONENT tbb) - if(EXISTS "${TBB}/bin") - install(DIRECTORY "${TBB}/bin" - DESTINATION ${IE_CPACK_IE_DIR}/external/tbb - COMPONENT tbb) - endif() - install(FILES "${TBB}/LICENSE" - DESTINATION ${IE_CPACK_IE_DIR}/external/tbb - COMPONENT tbb) - install(FILES "${TBB}/cmake/TBBConfig.cmake" - "${TBB}/cmake/TBBConfigVersion.cmake" - DESTINATION ${IE_CPACK_IE_DIR}/external/tbb/cmake - COMPONENT tbb) -endif() - ie_cpack_add_component(core REQUIRED DEPENDS ${core_components}) install(DIRECTORY "${IE_MAIN_SOURCE_DIR}/include" DESTINATION ${IE_CPACK_IE_DIR}