simple Windows installer POC (#12308)
* Fixes for cases when TBB_DIR env var is set * Don't use make in build_samples.sh script * First version of Windows installer * WIndows NSIS installer
This commit is contained in:
parent
1dd13e2cf6
commit
101e1ea5ad
@ -114,6 +114,6 @@ add_subdirectory(licensing)
|
||||
#
|
||||
|
||||
# provides a callback function to describe each component in repo
|
||||
include(cmake/debian.cmake)
|
||||
include(cmake/packaging/packaging.cmake)
|
||||
|
||||
ie_cpack(${IE_CPACK_COMPONENTS_ALL})
|
||||
|
@ -83,7 +83,7 @@ if(THREADING STREQUAL "OMP")
|
||||
update_deps_cache(OMP "${OMP}" "Path to OMP root folder")
|
||||
debug_message(STATUS "intel_omp=" ${OMP})
|
||||
|
||||
ie_cpack_add_component(omp REQUIRED)
|
||||
ie_cpack_add_component(omp HIDDEN)
|
||||
file(GLOB_RECURSE source_list "${OMP}/*${CMAKE_SHARED_LIBRARY_SUFFIX}*")
|
||||
install(FILES ${source_list}
|
||||
DESTINATION ${OV_CPACK_RUNTIMEDIR}
|
||||
|
41
cmake/developer_package/packaging/nsis.cmake
Normal file
41
cmake/developer_package/packaging/nsis.cmake
Normal file
@ -0,0 +1,41 @@
|
||||
# Copyright (C) 2018-2022 Intel Corporation
|
||||
# SPDX-License-Identifier: Apache-2.0
|
||||
#
|
||||
|
||||
# installation directory
|
||||
set(CPACK_PACKAGE_INSTALL_DIRECTORY "Intel")
|
||||
|
||||
# TODO: provide icons
|
||||
# set(CPACK_NSIS_MUI_ICON "")
|
||||
# set(CPACK_NSIS_MUI_UNIICON "${CPACK_NSIS_MUI_ICON}")
|
||||
# set(CPACK_NSIS_MUI_WELCOMEFINISHPAGE_BITMAP "")
|
||||
# set(CPACK_NSIS_MUI_UNWELCOMEFINISHPAGE_BITMAP "")
|
||||
# set(CPACK_NSIS_MUI_HEADERIMAGE "")
|
||||
|
||||
# we allow to install several packages at once
|
||||
set(CPACK_NSIS_ENABLE_UNINSTALL_BEFORE_INSTALL OFF)
|
||||
set(CPACK_NSIS_MODIFY_PATH OFF)
|
||||
|
||||
set(CPACK_NSIS_DISPLAY_NAME "Intel(R) OpenVINO(TM) ${OpenVINO_VERSION}")
|
||||
set(CPACK_NSIS_PACKAGE_NAME "Intel(R) OpenVINO(TM) ToolKit, v. ${OpenVINO_VERSION}.${OpenVINO_PATCH_VERSION}")
|
||||
|
||||
# contact
|
||||
set(CPACK_NSIS_CONTACT "CPACK_NSIS_CONTACT")
|
||||
|
||||
# links in menu
|
||||
set(CPACK_NSIS_MENU_LINKS
|
||||
"https://docs.openvinoo.ai" "OpenVINO Documentation")
|
||||
|
||||
# welcome and finish titles
|
||||
set(CPACK_NSIS_WELCOME_TITLE "Welcome to Intel(R) Distribution of OpenVINO(TM) Toolkit installation")
|
||||
set(CPACK_NSIS_FINISH_TITLE "")
|
||||
|
||||
# autoresize?
|
||||
set(CPACK_NSIS_MANIFEST_DPI_AWARE ON)
|
||||
|
||||
# branding text
|
||||
set(CPACK_NSIS_BRANDING_TEXT "Intel(R) Corp.")
|
||||
set(CPACK_NSIS_BRANDING_TEXT_TRIM_POSITION RIGHT)
|
||||
|
||||
# don't set this variable since we need a user to agree with a lincense
|
||||
# set(CPACK_NSIS_IGNORE_LICENSE_PAGE OFF)
|
@ -51,19 +51,27 @@ ov_cpack_set_dirs()
|
||||
#
|
||||
# Wraps original `cpack_add_component` and adds component to internal IE list
|
||||
#
|
||||
unset(IE_CPACK_COMPONENTS_ALL CACHE)
|
||||
function(ie_cpack_add_component name)
|
||||
if(NOT ${name} IN_LIST IE_CPACK_COMPONENTS_ALL)
|
||||
cpack_add_component(${name} ${args})
|
||||
cpack_add_component(${name} ${ARGN})
|
||||
|
||||
# need to store informarion about cpack_add_component arguments in CMakeCache.txt
|
||||
# to restore it later
|
||||
set(_${name}_cpack_component_args "${ARGN}" CACHE STRING "Argument for cpack_add_component for ${name} cpack component" FORCE)
|
||||
|
||||
list(APPEND IE_CPACK_COMPONENTS_ALL ${name})
|
||||
set(IE_CPACK_COMPONENTS_ALL "${IE_CPACK_COMPONENTS_ALL}" CACHE STRING "" FORCE)
|
||||
endif()
|
||||
endfunction()
|
||||
|
||||
foreach(comp IN LISTS IE_CPACK_COMPONENTS_ALL)
|
||||
unset(_${comp}_cpack_component_args)
|
||||
endforeach()
|
||||
unset(IE_CPACK_COMPONENTS_ALL CACHE)
|
||||
|
||||
# create `tests` component
|
||||
if(ENABLE_TESTS)
|
||||
cpack_add_component(tests DISABLED)
|
||||
cpack_add_component(tests HIDDEN)
|
||||
endif()
|
||||
|
||||
#
|
||||
@ -110,6 +118,10 @@ if(CPACK_GENERATOR STREQUAL "DEB")
|
||||
include(packaging/debian)
|
||||
endif()
|
||||
|
||||
if(CPACK_GENERATOR STREQUAL "NSIS")
|
||||
include(packaging/nsis)
|
||||
endif()
|
||||
|
||||
macro(ie_cpack)
|
||||
if(NOT DEFINED CPACK_GENERATOR)
|
||||
set(CPACK_GENERATOR "TGZ")
|
||||
@ -122,6 +134,8 @@ macro(ie_cpack)
|
||||
set(CPACK_PACKAGE_CONTACT "OpenVINO Developers <openvino@intel.com>")
|
||||
set(CPACK_VERBATIM_VARIABLES ON)
|
||||
set(CPACK_COMPONENTS_ALL ${ARGN})
|
||||
# TODO: set proper license file
|
||||
set(CPACK_RESOURCE_FILE_LICENSE "${OpenVINO_SOURCE_DIR}/LICENSE")
|
||||
|
||||
# TODO: check whether we need it
|
||||
# default permissions for directories creation
|
||||
@ -159,15 +173,17 @@ macro(ie_cpack)
|
||||
|
||||
# generator specific variables
|
||||
if(CPACK_GENERATOR MATCHES "^(7Z|TBZ2|TGZ|TXZ|TZ|ZIP)$")
|
||||
# New in version 3.18
|
||||
set(CPACK_ARCHIVE_THREADS 8)
|
||||
# multiple packages are generated
|
||||
set(CPACK_ARCHIVE_COMPONENT_INSTALL ON)
|
||||
elseif(CPACK_GENERATOR STREQUAL "DEB")
|
||||
# include Debian dedicated per-component configuration file
|
||||
# NOTE: private modules need to define ov_debian_components macro
|
||||
# for custom debian packages configuration
|
||||
if(COMMAND ov_debian_components)
|
||||
ov_debian_components()
|
||||
endif()
|
||||
endif()
|
||||
|
||||
# include GENERATOR dedicated per-component configuration file
|
||||
# NOTE: private modules need to define ov_cpack_settings macro
|
||||
# for custom packages configuration
|
||||
if(COMMAND ov_cpack_settings)
|
||||
ov_cpack_settings()
|
||||
endif()
|
||||
|
||||
include(CPack)
|
||||
|
@ -20,6 +20,7 @@ endif()
|
||||
#
|
||||
# ie_add_plugin(NAME <targetName>
|
||||
# DEVICE_NAME <deviceName>
|
||||
# [PSEUDO_DEVICE]
|
||||
# [PSEUDO_PLUGIN_FOR <actual_device>]
|
||||
# [AS_EXTENSION]
|
||||
# [DEFAULT_CONFIG <key:value;...>]
|
||||
@ -32,7 +33,7 @@ endif()
|
||||
# )
|
||||
#
|
||||
function(ie_add_plugin)
|
||||
set(options SKIP_INSTALL ADD_CLANG_FORMAT AS_EXTENSION SKIP_REGISTRATION)
|
||||
set(options SKIP_INSTALL PSEUDO_DEVICE ADD_CLANG_FORMAT AS_EXTENSION SKIP_REGISTRATION)
|
||||
set(oneValueArgs NAME DEVICE_NAME VERSION_DEFINES_FOR PSEUDO_PLUGIN_FOR)
|
||||
set(multiValueArgs DEFAULT_CONFIG SOURCES OBJECT_LIBRARIES CPPLINT_FILTERS)
|
||||
cmake_parse_arguments(IE_PLUGIN "${options}" "${oneValueArgs}" "${multiValueArgs}" ${ARGN})
|
||||
@ -135,12 +136,23 @@ function(ie_add_plugin)
|
||||
# install rules
|
||||
if(NOT IE_PLUGIN_SKIP_INSTALL OR NOT BUILD_SHARED_LIBS)
|
||||
string(TOLOWER "${IE_PLUGIN_DEVICE_NAME}" install_component)
|
||||
ie_cpack_add_component(${install_component} REQUIRED DEPENDS core)
|
||||
|
||||
if(IE_PLUGIN_PSEUDO_DEVICE)
|
||||
set(plugin_hidden HIDDEN)
|
||||
endif()
|
||||
ie_cpack_add_component(${install_component}
|
||||
DISPLAY_NAME "${IE_PLUGIN_DEVICE_NAME} runtime"
|
||||
DESCRIPTION "${IE_PLUGIN_DEVICE_NAME} runtime"
|
||||
${plugin_hidden}
|
||||
DEPENDS ${OV_CPACK_COMP_CORE})
|
||||
|
||||
if(BUILD_SHARED_LIBS)
|
||||
install(TARGETS ${IE_PLUGIN_NAME}
|
||||
LIBRARY DESTINATION ${OV_CPACK_PLUGINSDIR}
|
||||
COMPONENT ${install_component})
|
||||
install(TARGETS ${IE_PLUGIN_NAME}
|
||||
LIBRARY DESTINATION ${OV_CPACK_PLUGINSDIR}
|
||||
COMPONENT ${install_component})
|
||||
else()
|
||||
ov_install_static_lib(${IE_PLUGIN_NAME} ${install_component})
|
||||
endif()
|
||||
|
@ -6,11 +6,11 @@
|
||||
# OpenVINO Core components including frontends, plugins, etc
|
||||
#
|
||||
|
||||
macro(ov_debian_components)
|
||||
macro(ov_cpack_settings)
|
||||
# fill a list of components which are part of debian
|
||||
set(cpack_components_all ${CPACK_COMPONENTS_ALL})
|
||||
unset(CPACK_COMPONENTS_ALL)
|
||||
foreach(item ${cpack_components_all})
|
||||
foreach(item IN LISTS cpack_components_all)
|
||||
# filter out some components, which are not needed to be wrapped to .deb package
|
||||
if(# NOT ${item} MATCHES ".*(python).*" AND
|
||||
# python wheels are not needed to be wrapped by debian packages
|
27
cmake/packaging/nsis.cmake
Normal file
27
cmake/packaging/nsis.cmake
Normal file
@ -0,0 +1,27 @@
|
||||
# Copyright (C) 2018-2022 Intel Corporation
|
||||
# SPDX-License-Identifier: Apache-2.0
|
||||
#
|
||||
|
||||
# Components
|
||||
|
||||
macro(ov_cpack_settings)
|
||||
# fill a list of components which are part of NSIS or other GUI installer
|
||||
set(cpack_components_all ${CPACK_COMPONENTS_ALL})
|
||||
unset(CPACK_COMPONENTS_ALL)
|
||||
foreach(item IN LISTS cpack_components_all)
|
||||
# filter out some components, which are not needed to be wrapped to Windows package
|
||||
if(# python wheels are not needed to be wrapped by NSIS installer
|
||||
NOT item STREQUAL OV_CPACK_COMP_PYTHON_WHEELS)
|
||||
list(APPEND CPACK_COMPONENTS_ALL ${item})
|
||||
endif()
|
||||
endforeach()
|
||||
|
||||
# restore the components settings
|
||||
|
||||
foreach(comp IN LISTS CPACK_COMPONENTS_ALL)
|
||||
cpack_add_component(${comp} ${_${comp}_cpack_component_args})
|
||||
endforeach()
|
||||
|
||||
# override package file name
|
||||
set(CPACK_PACKAGE_FILE_NAME "w_openvino_toolkit_p_${OpenVINO_VERSION}.${OpenVINO_VERSION_BUILD}_offline")
|
||||
endmacro()
|
9
cmake/packaging/packaging.cmake
Normal file
9
cmake/packaging/packaging.cmake
Normal file
@ -0,0 +1,9 @@
|
||||
# Copyright (C) 2018-2022 Intel Corporation
|
||||
# SPDX-License-Identifier: Apache-2.0
|
||||
#
|
||||
|
||||
if(CPACK_GENERATOR STREQUAL "DEB")
|
||||
include(cmake/packaging/debian.cmake)
|
||||
elseif(CPACK_GENERATOR STREQUAL "NSIS")
|
||||
include(cmake/packaging/nsis.cmake)
|
||||
endif()
|
@ -6,7 +6,7 @@
|
||||
# Install licensing
|
||||
#
|
||||
|
||||
ie_cpack_add_component(${OV_CPACK_COMP_LICENSING})
|
||||
ie_cpack_add_component(${OV_CPACK_COMP_LICENSING} HIDDEN)
|
||||
|
||||
install(DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/
|
||||
DESTINATION ${OV_CPACK_DOCDIR}/licensing
|
||||
|
@ -20,27 +20,31 @@ openvino_developer_export_targets(COMPONENT openvino_common TARGETS format_reade
|
||||
|
||||
# install C++ samples
|
||||
|
||||
ie_cpack_add_component(${OV_CPACK_COMP_CPP_SAMPLES} DEPENDS ${OV_CPACK_COMP_CORE_DEV})
|
||||
ie_cpack_add_component(${OV_CPACK_COMP_CPP_SAMPLES}
|
||||
HIDDEN
|
||||
DEPENDS ${OV_CPACK_COMP_CORE_DEV})
|
||||
|
||||
if(UNIX)
|
||||
install(DIRECTORY cpp/
|
||||
DESTINATION ${OV_CPACK_SAMPLESDIR}/cpp
|
||||
COMPONENT ${OV_CPACK_COMP_CPP_SAMPLES}
|
||||
USE_SOURCE_PERMISSIONS
|
||||
COMPONENT ${OV_CPACK_COMP_CPP_SAMPLES}
|
||||
PATTERN *.bat EXCLUDE
|
||||
PATTERN .clang-format EXCLUDE)
|
||||
elseif(WIN32)
|
||||
install(DIRECTORY cpp/
|
||||
DESTINATION ${OV_CPACK_SAMPLESDIR}/cpp
|
||||
COMPONENT ${OV_CPACK_COMP_CPP_SAMPLES}
|
||||
USE_SOURCE_PERMISSIONS
|
||||
COMPONENT ${OV_CPACK_COMP_CPP_SAMPLES}
|
||||
PATTERN *.sh EXCLUDE
|
||||
PATTERN .clang-format EXCLUDE)
|
||||
endif()
|
||||
|
||||
# install C samples
|
||||
|
||||
ie_cpack_add_component(${OV_CPACK_COMP_C_SAMPLES} DEPENDS ${OV_CPACK_COMP_CORE_C})
|
||||
ie_cpack_add_component(${OV_CPACK_COMP_C_SAMPLES}
|
||||
HIDDEN
|
||||
DEPENDS ${OV_CPACK_COMP_CORE_C_DEV})
|
||||
|
||||
if(UNIX)
|
||||
install(PROGRAMS cpp/build_samples.sh
|
||||
@ -64,7 +68,7 @@ install(FILES cpp/CMakeLists.txt
|
||||
|
||||
# install Python samples
|
||||
|
||||
ie_cpack_add_component(${OV_CPACK_COMP_PYTHON_SAMPLES})
|
||||
ie_cpack_add_component(${OV_CPACK_COMP_PYTHON_SAMPLES} HIDDEN)
|
||||
|
||||
install(DIRECTORY python/
|
||||
DESTINATION ${OV_CPACK_SAMPLESDIR}/python
|
||||
|
@ -28,7 +28,7 @@ ie_shellcheck_process(DIRECTORY "${OpenVINO_SOURCE_DIR}"
|
||||
|
||||
# install setupvars
|
||||
|
||||
ie_cpack_add_component(${OV_CPACK_COMP_SETUPVARS} REQUIRED)
|
||||
ie_cpack_add_component(${OV_CPACK_COMP_SETUPVARS} HIDDEN)
|
||||
|
||||
if(UNIX)
|
||||
set(_setupvars_file setupvars/setupvars.sh)
|
||||
@ -53,7 +53,8 @@ install(PROGRAMS "${_setupvars_file}"
|
||||
# install install_dependencies
|
||||
|
||||
if(LINUX)
|
||||
ie_cpack_add_component(${OV_CPACK_COMP_INSTALL_DEPENDENCIES} REQUIRED)
|
||||
ie_cpack_add_component(${OV_CPACK_COMP_INSTALL_DEPENDENCIES} HIDDEN)
|
||||
|
||||
install(DIRECTORY install_dependencies/
|
||||
DESTINATION install_dependencies
|
||||
COMPONENT ${OV_CPACK_COMP_INSTALL_DEPENDENCIES}
|
||||
|
@ -36,8 +36,8 @@ export(TARGETS ${TARGET_NAME} NAMESPACE openvino::
|
||||
|
||||
# install
|
||||
|
||||
ie_cpack_add_component(${OV_CPACK_COMP_CORE_C} DEPENDS ${OV_CPACK_COMP_CORE})
|
||||
ie_cpack_add_component(${OV_CPACK_COMP_CORE_C_DEV} DEPENDS ${OV_CPACK_COMP_CORE_C})
|
||||
ie_cpack_add_component(${OV_CPACK_COMP_CORE_C} HIDDEN)
|
||||
ie_cpack_add_component(${OV_CPACK_COMP_CORE_C_DEV} HIDDEN)
|
||||
|
||||
install(TARGETS ${TARGET_NAME} EXPORT OpenVINOTargets
|
||||
RUNTIME DESTINATION ${OV_CPACK_RUNTIMEDIR} COMPONENT ${OV_CPACK_COMP_CORE_C}
|
||||
|
@ -42,8 +42,8 @@ export(TARGETS ${TARGET_NAME} NAMESPACE openvino::
|
||||
|
||||
# install
|
||||
|
||||
ie_cpack_add_component(${OV_CPACK_COMP_CORE_C} DEPENDS core)
|
||||
ie_cpack_add_component(${OV_CPACK_COMP_CORE_C_DEV} DEPENDS ${OV_CPACK_COMP_CORE_C})
|
||||
ie_cpack_add_component(${OV_CPACK_COMP_CORE_C} HIDDEN)
|
||||
ie_cpack_add_component(${OV_CPACK_COMP_CORE_C_DEV} HIDDEN)
|
||||
|
||||
install(TARGETS ${TARGET_NAME} EXPORT OpenVINOTargets
|
||||
RUNTIME DESTINATION ${OV_CPACK_RUNTIMEDIR} COMPONENT ${OV_CPACK_COMP_CORE_C}
|
||||
|
@ -67,7 +67,7 @@ endif()
|
||||
|
||||
# install
|
||||
|
||||
ie_cpack_add_component(${PYTHON_COMPONENT})
|
||||
ie_cpack_add_component(${PYTHON_COMPONENT} HIDDEN)
|
||||
|
||||
install(FILES requirements.txt
|
||||
DESTINATION ${PYTHON_BRIDGE_CPACK_PATH}/${PYTHON_VERSION}
|
||||
|
@ -72,7 +72,7 @@ if(OpenVINO_SOURCE_DIR OR InferenceEngineDeveloperPackage_FOUND)
|
||||
ie_python_minimal_api(_${PROJECT_NAME})
|
||||
add_clang_format_target(_${PROJECT_NAME}_clang FOR_TARGETS _${PROJECT_NAME})
|
||||
|
||||
ie_cpack_add_component(${OV_CPACK_COMP_PYTHON_NGRAPH}_${PYTHON_VERSION})
|
||||
ie_cpack_add_component(${OV_CPACK_COMP_PYTHON_NGRAPH}_${PYTHON_VERSION} HIDDEN)
|
||||
|
||||
install(TARGETS _${PROJECT_NAME}
|
||||
DESTINATION ${OV_CPACK_PYTHONDIR}/${PYTHON_VERSION}
|
||||
|
@ -92,7 +92,8 @@ if(OpenVINO_SOURCE_DIR OR InferenceEngineDeveloperPackage_FOUND)
|
||||
ie_python_minimal_api(${PROJECT_NAME})
|
||||
add_clang_format_target(${PROJECT_NAME}_clang FOR_TARGETS ${PROJECT_NAME})
|
||||
|
||||
ie_cpack_add_component(${OV_CPACK_COMP_PYTHON_OPENVINO}_${PYTHON_VERSION})
|
||||
ie_cpack_add_component(${OV_CPACK_COMP_PYTHON_OPENVINO}_${PYTHON_VERSION}
|
||||
HIDDEN)
|
||||
|
||||
install(DIRECTORY ${PYTHON_SOURCE_DIR}/openvino
|
||||
DESTINATION ${OV_CPACK_PYTHONDIR}/${PYTHON_VERSION}
|
||||
|
@ -66,10 +66,7 @@ add_custom_target(ie_wheel ALL DEPENDS ${openvino_wheel_path})
|
||||
|
||||
# install
|
||||
|
||||
ie_cpack_add_component(${OV_CPACK_COMP_PYTHON_WHEELS}
|
||||
DEPENDS ${OV_CPACK_COMP_PYTHON_OPENVINO}_${PYTHON_VERSION}
|
||||
${OV_CPACK_COMP_PYTHON_IE_API}_${PYTHON_VERSION}
|
||||
${OV_CPACK_COMP_PYTHON_NGRAPH}_${PYTHON_VERSION})
|
||||
ie_cpack_add_component(${OV_CPACK_COMP_PYTHON_WHEELS} HIDDEN)
|
||||
|
||||
install(FILES ${openvino_wheel_path}
|
||||
DESTINATION ${OV_CPACK_WHEELSDIR}
|
||||
|
@ -46,7 +46,7 @@ if(THREADING MATCHES "^(TBB|TBB_AUTO)$" AND
|
||||
( (DEFINED TBB AND TBB MATCHES ${TEMP}) OR
|
||||
(DEFINED TBBROOT OR DEFINED TBB_DIR OR DEFINED ENV{TBBROOT} OR
|
||||
DEFINED ENV{TBB_DIR}) OR ENABLE_SYSTEM_TBB ) )
|
||||
ie_cpack_add_component(tbb REQUIRED)
|
||||
ie_cpack_add_component(tbb HIDDEN)
|
||||
list(APPEND core_components tbb)
|
||||
|
||||
if(TBB MATCHES ${TEMP})
|
||||
@ -131,7 +131,9 @@ if(THREADING MATCHES "^(TBB|TBB_AUTO)$" AND
|
||||
|
||||
# install development files
|
||||
|
||||
ie_cpack_add_component(tbb_dev REQUIRED)
|
||||
ie_cpack_add_component(tbb_dev
|
||||
HIDDEN
|
||||
DEPENDS tbb)
|
||||
list(APPEND core_dev_components tbb_dev)
|
||||
|
||||
install(FILES "${TBB}/cmake/TBBConfig.cmake"
|
||||
|
@ -112,13 +112,17 @@ if(ENABLE_INTEL_GNA)
|
||||
list(APPEND PATH_VARS "GNA_PATH")
|
||||
endif()
|
||||
|
||||
ie_cpack_add_component(core REQUIRED DEPENDS ${core_components})
|
||||
ie_cpack_add_component(core_dev REQUIRED DEPENDS core ${core_dev_components})
|
||||
ie_cpack_add_component(${OV_CPACK_COMP_CORE}
|
||||
HIDDEN
|
||||
DEPENDS ${core_components})
|
||||
ie_cpack_add_component(${OV_CPACK_COMP_CORE_DEV}
|
||||
HIDDEN
|
||||
DEPENDS ${OV_CPACK_COMP_CORE} ${core_dev_components})
|
||||
|
||||
if(BUILD_SHARED_LIBS)
|
||||
install(FILES $<TARGET_FILE_DIR:${TARGET_NAME}>/plugins.xml
|
||||
DESTINATION ${OV_CPACK_PLUGINSDIR}
|
||||
COMPONENT core)
|
||||
COMPONENT ${OV_CPACK_COMP_CORE})
|
||||
|
||||
# for InferenceEngineUnitTest
|
||||
# For public tests
|
||||
|
@ -9,20 +9,24 @@ file(GLOB SOURCES ${CMAKE_CURRENT_SOURCE_DIR}/*.cpp ${CMAKE_CURRENT_SOURCE_DIR}/
|
||||
if(ENABLE_AUTO AND ENABLE_MULTI)
|
||||
ie_add_plugin(NAME ${TARGET_NAME}
|
||||
DEVICE_NAME "MULTI"
|
||||
PSEUDO_DEVICE
|
||||
SOURCES ${SOURCES}
|
||||
VERSION_DEFINES_FOR plugin.cpp)
|
||||
|
||||
ie_add_plugin(NAME ${TARGET_NAME}
|
||||
DEVICE_NAME "AUTO"
|
||||
PSEUDO_DEVICE
|
||||
PSEUDO_PLUGIN_FOR "MULTI")
|
||||
elseif(ENABLE_AUTO)
|
||||
ie_add_plugin(NAME ${TARGET_NAME}
|
||||
DEVICE_NAME "AUTO"
|
||||
PSEUDO_DEVICE
|
||||
SOURCES ${SOURCES}
|
||||
VERSION_DEFINES_FOR plugin.cpp)
|
||||
elseif(ENABLE_MULTI)
|
||||
ie_add_plugin(NAME ${TARGET_NAME}
|
||||
DEVICE_NAME "MULTI"
|
||||
PSEUDO_DEVICE
|
||||
SOURCES ${SOURCES}
|
||||
VERSION_DEFINES_FOR plugin.cpp)
|
||||
endif()
|
||||
|
@ -10,6 +10,7 @@ file(GLOB HEADERS ${CMAKE_CURRENT_SOURCE_DIR}/*.hpp)
|
||||
|
||||
ie_add_plugin(NAME ${TARGET_NAME}
|
||||
DEVICE_NAME "BATCH"
|
||||
PSEUDO_DEVICE
|
||||
SOURCES ${SOURCES} ${HEADERS}
|
||||
VERSION_DEFINES_FOR auto_batch.cpp ADD_CLANG_FORMAT)
|
||||
|
||||
|
@ -9,6 +9,7 @@ file(GLOB_RECURSE HEADERS ${CMAKE_CURRENT_SOURCE_DIR}/*.hpp)
|
||||
|
||||
ie_add_plugin(NAME ${TARGET_NAME}
|
||||
DEVICE_NAME "HETERO"
|
||||
PSEUDO_DEVICE
|
||||
SOURCES ${SOURCES} ${HEADERS}
|
||||
VERSION_DEFINES_FOR plugin.cpp
|
||||
ADD_CLANG_FORMAT)
|
||||
|
15
thirdparty/CMakeLists.txt
vendored
15
thirdparty/CMakeLists.txt
vendored
@ -201,21 +201,22 @@ if(CPACK_GENERATOR STREQUAL "DEB")
|
||||
else()
|
||||
install(DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/gflags
|
||||
DESTINATION ${OV_CPACK_SAMPLESDIR}/cpp/thirdparty
|
||||
COMPONENT ${OV_CPACK_COMP_CPP_SAMPLES}
|
||||
USE_SOURCE_PERMISSIONS)
|
||||
USE_SOURCE_PERMISSIONS
|
||||
COMPONENT ${OV_CPACK_COMP_CPP_SAMPLES})
|
||||
|
||||
install(DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/zlib
|
||||
DESTINATION ${OV_CPACK_SAMPLESDIR}/cpp/thirdparty
|
||||
COMPONENT ${OV_CPACK_COMP_CPP_SAMPLES}
|
||||
USE_SOURCE_PERMISSIONS)
|
||||
USE_SOURCE_PERMISSIONS
|
||||
COMPONENT ${OV_CPACK_COMP_CPP_SAMPLES})
|
||||
|
||||
install(DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/json/nlohmann_json
|
||||
DESTINATION ${OV_CPACK_SAMPLESDIR}/cpp/thirdparty
|
||||
USE_SOURCE_PERMISSIONS
|
||||
COMPONENT ${OV_CPACK_COMP_CPP_SAMPLES}
|
||||
USE_SOURCE_PERMISSIONS)
|
||||
REGEX .*json/nlohmann_json/test/.* EXCLUDE)
|
||||
endif()
|
||||
|
||||
install(DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/cnpy
|
||||
DESTINATION ${OV_CPACK_SAMPLESDIR}/cpp/thirdparty
|
||||
COMPONENT ${OV_CPACK_COMP_CPP_SAMPLES}
|
||||
USE_SOURCE_PERMISSIONS)
|
||||
USE_SOURCE_PERMISSIONS
|
||||
COMPONENT ${OV_CPACK_COMP_CPP_SAMPLES})
|
||||
|
@ -17,7 +17,7 @@ endif()
|
||||
|
||||
# install deployment_manager
|
||||
|
||||
ie_cpack_add_component(${OV_CPACK_COMP_DEPLOYMENT_MANAGER} REQUIRED)
|
||||
ie_cpack_add_component(${OV_CPACK_COMP_DEPLOYMENT_MANAGER} HIDDEN)
|
||||
|
||||
install(DIRECTORY deployment_manager
|
||||
DESTINATION ${OV_CPACK_TOOLSDIR}
|
||||
@ -25,6 +25,9 @@ install(DIRECTORY deployment_manager
|
||||
USE_SOURCE_PERMISSIONS)
|
||||
|
||||
# outbound requirements.txt files for openvino-dev package
|
||||
|
||||
ie_cpack_add_component(${OV_CPACK_COMP_DEV_REQ_FILES} HIDDEN)
|
||||
|
||||
if(DEFINED ENV{CI_BUILD_DEV_TAG} AND NOT $ENV{CI_BUILD_DEV_TAG} STREQUAL "")
|
||||
set(WHEEL_VERSION "${OpenVINO_VERSION}.$ENV{CI_BUILD_DEV_TAG}")
|
||||
else()
|
||||
@ -33,7 +36,6 @@ endif()
|
||||
|
||||
set(REQUIREMENTS_IN "${CMAKE_CURRENT_SOURCE_DIR}/requirements_dev.in")
|
||||
set(EXTRAS_LIST _ caffe kaldi mxnet onnx pytorch tensorflow tensorflow2)
|
||||
ie_cpack_add_component(${OV_CPACK_COMP_DEV_REQ_FILES})
|
||||
|
||||
foreach(EXTRAS IN LISTS EXTRAS_LIST)
|
||||
if(EXTRAS STREQUAL "_")
|
||||
|
@ -35,6 +35,10 @@ add_cpplint_target(${TARGET_NAME}_cpplint FOR_TARGETS ${TARGET_NAME})
|
||||
|
||||
# install
|
||||
|
||||
ie_cpack_add_component(${OV_CPACK_COMP_CORE_TOOLS}
|
||||
HIDDEN
|
||||
DEPENDS ${OV_CPACK_COMP_CORE})
|
||||
|
||||
if(CPACK_GENERATOR MATCHES "DEB")
|
||||
install(TARGETS compile_tool
|
||||
RUNTIME DESTINATION ${OV_CPACK_TOOLSDIR}
|
||||
|
@ -24,10 +24,7 @@ add_custom_target(openvino_dev_wheel ALL DEPENDS ${openvino_wheel_path})
|
||||
|
||||
# install
|
||||
|
||||
ie_cpack_add_component(${OV_CPACK_COMP_PYTHON_WHEELS}
|
||||
DEPENDS ${OV_CPACK_COMP_PYTHON_OPENVINO}_${PYTHON_VERSION}
|
||||
${OV_CPACK_COMP_PYTHON_IE_API}_${PYTHON_VERSION}
|
||||
${OV_CPACK_COMP_PYTHON_NGRAPH}_${PYTHON_VERSION})
|
||||
ie_cpack_add_component(${OV_CPACK_COMP_PYTHON_WHEELS} HIDDEN)
|
||||
|
||||
install(FILES ${openvino_wheel_path}
|
||||
DESTINATION ${OV_CPACK_WHEELSDIR}
|
||||
|
Loading…
Reference in New Issue
Block a user