Less argressive chages (#18591)
This commit is contained in:
parent
2f3d4df342
commit
700677c5c6
@ -69,16 +69,22 @@ if(NOT OV_GLIBC_VERSION VERSION_EQUAL 0.0)
|
|||||||
message (STATUS "GLIBC_VERSION ......................... " ${OV_GLIBC_VERSION})
|
message (STATUS "GLIBC_VERSION ......................... " ${OV_GLIBC_VERSION})
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
# remove file with exported developer targets to force its regeneration
|
# remove file with exported targets to force its regeneration
|
||||||
file(REMOVE "${CMAKE_BINARY_DIR}/ngraphTargets.cmake")
|
file(REMOVE "${CMAKE_BINARY_DIR}/ngraphTargets.cmake")
|
||||||
file(REMOVE "${CMAKE_BINARY_DIR}/InferenceEngineTargets.cmake")
|
file(REMOVE "${CMAKE_BINARY_DIR}/InferenceEngineTargets.cmake")
|
||||||
file(REMOVE "${CMAKE_BINARY_DIR}/OpenVINOTargets.cmake")
|
file(REMOVE "${CMAKE_BINARY_DIR}/OpenVINOTargets.cmake")
|
||||||
foreach(component IN LISTS openvino_export_components)
|
|
||||||
file(REMOVE "${CMAKE_BINARY_DIR}/${component}_dev_targets.cmake")
|
# remove exported developer targets to force its regeneration
|
||||||
file(REMOVE "${CMAKE_BINARY_DIR}/ov_${component}_dev_targets.cmake")
|
macro(ov_clean_dev_targets)
|
||||||
unset(${component} CACHE)
|
foreach(component IN LISTS openvino_export_components)
|
||||||
endforeach()
|
file(REMOVE "${CMAKE_BINARY_DIR}/${component}_dev_targets.cmake")
|
||||||
unset(openvino_export_components CACHE)
|
file(REMOVE "${CMAKE_BINARY_DIR}/ov_${component}_dev_targets.cmake")
|
||||||
|
unset(${component} CACHE)
|
||||||
|
endforeach()
|
||||||
|
unset(openvino_export_components CACHE)
|
||||||
|
unset(openvino_installed_targets CACHE)
|
||||||
|
endmacro()
|
||||||
|
ov_clean_dev_targets()
|
||||||
|
|
||||||
#
|
#
|
||||||
# Build
|
# Build
|
||||||
|
@ -16,6 +16,12 @@ macro(ov_install_static_lib target comp)
|
|||||||
if(target_type STREQUAL "STATIC_LIBRARY")
|
if(target_type STREQUAL "STATIC_LIBRARY")
|
||||||
set_target_properties(${target} PROPERTIES EXCLUDE_FROM_ALL OFF)
|
set_target_properties(${target} PROPERTIES EXCLUDE_FROM_ALL OFF)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
# save all internal installed targets to filter them later in 'ov_generate_dev_package_config'
|
||||||
|
list(APPEND openvino_installed_targets ${target})
|
||||||
|
set(openvino_installed_targets "${openvino_installed_targets}" CACHE INTERNAL
|
||||||
|
"A list of OpenVINO internal targets" FORCE)
|
||||||
|
|
||||||
install(TARGETS ${target} EXPORT OpenVINOTargets
|
install(TARGETS ${target} EXPORT OpenVINOTargets
|
||||||
ARCHIVE DESTINATION ${OV_CPACK_ARCHIVEDIR} COMPONENT ${comp} ${ARGN})
|
ARCHIVE DESTINATION ${OV_CPACK_ARCHIVEDIR} COMPONENT ${comp} ${ARGN})
|
||||||
endif()
|
endif()
|
||||||
|
@ -135,7 +135,7 @@ function(ov_add_plugin)
|
|||||||
LIBRARY DESTINATION ${OV_CPACK_PLUGINSDIR}
|
LIBRARY DESTINATION ${OV_CPACK_PLUGINSDIR}
|
||||||
COMPONENT ${install_component})
|
COMPONENT ${install_component})
|
||||||
else()
|
else()
|
||||||
ov_install_static_lib(${OV_PLUGIN_NAME} ${install_component})
|
ov_install_static_lib(${OV_PLUGIN_NAME} ${OV_CPACK_COMP_CORE})
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
@ -39,15 +39,17 @@ function(ov_generate_dev_package_config)
|
|||||||
find_package(OpenCV QUIET)
|
find_package(OpenCV QUIET)
|
||||||
|
|
||||||
foreach(component IN LISTS openvino_export_components)
|
foreach(component IN LISTS openvino_export_components)
|
||||||
# TODO: remove legacy targets from tests
|
# filter out targets which are installed by OpenVINOConfig.cmake static build case
|
||||||
# string(FIND "${component}" "_legacy" index)
|
set(exported_targets)
|
||||||
# if(index EQUAL -1)
|
foreach(target IN LISTS ${component})
|
||||||
|
if(NOT target IN_LIST openvino_installed_targets)
|
||||||
# export all targets with prefix and use them during extra modules build
|
list(APPEND exported_targets ${target})
|
||||||
export(TARGETS ${${component}} NAMESPACE openvino::
|
endif()
|
||||||
|
endforeach()
|
||||||
|
# export all developer targets with prefix and use them during extra modules build
|
||||||
|
export(TARGETS ${exported_targets} NAMESPACE openvino::
|
||||||
APPEND FILE "${CMAKE_BINARY_DIR}/ov_${component}_dev_targets.cmake")
|
APPEND FILE "${CMAKE_BINARY_DIR}/ov_${component}_dev_targets.cmake")
|
||||||
list(APPEND all_dev_targets ${${component}})
|
list(APPEND all_dev_targets ${${component}})
|
||||||
# endif()
|
|
||||||
endforeach()
|
endforeach()
|
||||||
add_custom_target(ov_dev_targets DEPENDS ${all_dev_targets})
|
add_custom_target(ov_dev_targets DEPENDS ${all_dev_targets})
|
||||||
|
|
||||||
@ -76,10 +78,6 @@ endfunction()
|
|||||||
#
|
#
|
||||||
|
|
||||||
function(register_extra_modules)
|
function(register_extra_modules)
|
||||||
# post export
|
|
||||||
openvino_developer_export_targets(COMPONENT core_legacy TARGETS inference_engine)
|
|
||||||
openvino_developer_export_targets(COMPONENT core_legacy TARGETS ngraph)
|
|
||||||
|
|
||||||
set(InferenceEngineDeveloperPackage_DIR "${CMAKE_CURRENT_BINARY_DIR}/build-modules")
|
set(InferenceEngineDeveloperPackage_DIR "${CMAKE_CURRENT_BINARY_DIR}/build-modules")
|
||||||
set(OpenVINODeveloperPackage_DIR "${CMAKE_BINARY_DIR}/build-modules")
|
set(OpenVINODeveloperPackage_DIR "${CMAKE_BINARY_DIR}/build-modules")
|
||||||
set(OpenVINO_DIR "${CMAKE_BINARY_DIR}")
|
set(OpenVINO_DIR "${CMAKE_BINARY_DIR}")
|
||||||
@ -94,12 +92,12 @@ function(register_extra_modules)
|
|||||||
|
|
||||||
file(WRITE "${devconfig_file}" "\# !! AUTOGENERATED: DON'T EDIT !!\n\n")
|
file(WRITE "${devconfig_file}" "\# !! AUTOGENERATED: DON'T EDIT !!\n\n")
|
||||||
|
|
||||||
foreach(target IN LISTS ${openvino_export_components})
|
foreach(targets_list IN LISTS ${openvino_export_components})
|
||||||
if(target)
|
foreach(target IN LISTS targets_list)
|
||||||
file(APPEND "${devconfig_file}" "if(NOT TARGET ${NS}::${target})
|
file(APPEND "${devconfig_file}" "if(NOT TARGET ${NS}::${target})
|
||||||
add_library(${NS}::${target} ALIAS ${target})
|
add_library(${NS}::${target} ALIAS ${target})
|
||||||
endif()\n")
|
endif()\n")
|
||||||
endif()
|
endforeach()
|
||||||
endforeach()
|
endforeach()
|
||||||
endfunction()
|
endfunction()
|
||||||
|
|
||||||
|
@ -343,7 +343,8 @@ endmacro()
|
|||||||
macro(_ov_find_intel_cpu_dependencies)
|
macro(_ov_find_intel_cpu_dependencies)
|
||||||
set(_OV_ENABLE_CPU_ACL "@DNNL_USE_ACL@")
|
set(_OV_ENABLE_CPU_ACL "@DNNL_USE_ACL@")
|
||||||
if(_OV_ENABLE_CPU_ACL)
|
if(_OV_ENABLE_CPU_ACL)
|
||||||
if(_ov_as_external_package)
|
set(_ov_in_install_tree "@PACKAGE_ARM_COMPUTE_LIB_DIR@")
|
||||||
|
if(_ov_in_install_tree)
|
||||||
set_and_check(ARM_COMPUTE_LIB_DIR "@PACKAGE_ARM_COMPUTE_LIB_DIR@")
|
set_and_check(ARM_COMPUTE_LIB_DIR "@PACKAGE_ARM_COMPUTE_LIB_DIR@")
|
||||||
set(ACL_DIR "${CMAKE_CURRENT_LIST_DIR}")
|
set(ACL_DIR "${CMAKE_CURRENT_LIST_DIR}")
|
||||||
else()
|
else()
|
||||||
@ -352,8 +353,8 @@ macro(_ov_find_intel_cpu_dependencies)
|
|||||||
|
|
||||||
_ov_find_dependency(ACL)
|
_ov_find_dependency(ACL)
|
||||||
|
|
||||||
|
unset(_ov_in_install_tree)
|
||||||
unset(ARM_COMPUTE_LIB_DIR)
|
unset(ARM_COMPUTE_LIB_DIR)
|
||||||
unset(_ov_find_acl_path)
|
|
||||||
endif()
|
endif()
|
||||||
unset(_OV_ENABLE_CPU_ACL)
|
unset(_OV_ENABLE_CPU_ACL)
|
||||||
endmacro()
|
endmacro()
|
||||||
|
@ -5,14 +5,7 @@
|
|||||||
add_subdirectory(cpp)
|
add_subdirectory(cpp)
|
||||||
add_subdirectory(c)
|
add_subdirectory(c)
|
||||||
|
|
||||||
# used by tests_deprecated
|
openvino_developer_export_targets(COMPONENT samples TARGETS format_reader ie_samples_utils)
|
||||||
if(TARGET format_reader)
|
|
||||||
install(TARGETS format_reader
|
|
||||||
ARCHIVE DESTINATION tests COMPONENT tests EXCLUDE_FROM_ALL
|
|
||||||
LIBRARY DESTINATION tests COMPONENT tests EXCLUDE_FROM_ALL)
|
|
||||||
endif()
|
|
||||||
|
|
||||||
openvino_developer_export_targets(COMPONENT openvino_common TARGETS format_reader ie_samples_utils)
|
|
||||||
|
|
||||||
#
|
#
|
||||||
# Install
|
# Install
|
||||||
|
@ -38,24 +38,24 @@ set_target_properties(${TARGET_NAME} PROPERTIES EXPORT_NAME runtime::c)
|
|||||||
ov_add_library_version(${TARGET_NAME})
|
ov_add_library_version(${TARGET_NAME})
|
||||||
|
|
||||||
export(TARGETS ${TARGET_NAME} NAMESPACE openvino::
|
export(TARGETS ${TARGET_NAME} NAMESPACE openvino::
|
||||||
APPEND FILE "${CMAKE_BINARY_DIR}/OpenVINOTargets.cmake")
|
APPEND FILE "${CMAKE_BINARY_DIR}/OpenVINOTargets.cmake")
|
||||||
|
|
||||||
# install
|
# install
|
||||||
ov_cpack_add_component(${OV_CPACK_COMP_CORE_C} HIDDEN)
|
ov_cpack_add_component(${OV_CPACK_COMP_CORE_C} HIDDEN)
|
||||||
ov_cpack_add_component(${OV_CPACK_COMP_CORE_C_DEV} HIDDEN)
|
ov_cpack_add_component(${OV_CPACK_COMP_CORE_C_DEV} HIDDEN)
|
||||||
|
|
||||||
install(TARGETS ${TARGET_NAME} EXPORT OpenVINOTargets
|
install(TARGETS ${TARGET_NAME} EXPORT OpenVINOTargets
|
||||||
RUNTIME DESTINATION ${OV_CPACK_RUNTIMEDIR} COMPONENT ${OV_CPACK_COMP_CORE_C}
|
RUNTIME DESTINATION ${OV_CPACK_RUNTIMEDIR} COMPONENT ${OV_CPACK_COMP_CORE_C}
|
||||||
ARCHIVE DESTINATION ${OV_CPACK_ARCHIVEDIR} COMPONENT ${OV_CPACK_COMP_CORE_C}
|
ARCHIVE DESTINATION ${OV_CPACK_ARCHIVEDIR} COMPONENT ${OV_CPACK_COMP_CORE_C}
|
||||||
LIBRARY DESTINATION ${OV_CPACK_LIBRARYDIR} COMPONENT ${OV_CPACK_COMP_CORE_C}
|
LIBRARY DESTINATION ${OV_CPACK_LIBRARYDIR} COMPONENT ${OV_CPACK_COMP_CORE_C}
|
||||||
NAMELINK_COMPONENT ${OV_CPACK_COMP_CORE_C_DEV}
|
NAMELINK_COMPONENT ${OV_CPACK_COMP_CORE_C_DEV}
|
||||||
INCLUDES DESTINATION ${OV_CPACK_INCLUDEDIR}
|
INCLUDES DESTINATION ${OV_CPACK_INCLUDEDIR}
|
||||||
${OV_CPACK_INCLUDEDIR}/ie)
|
${OV_CPACK_INCLUDEDIR}/ie)
|
||||||
|
|
||||||
install(DIRECTORY ${OpenVINO_C_API_SOURCE_DIR}/include/c_api
|
install(DIRECTORY ${OpenVINO_C_API_SOURCE_DIR}/include/c_api
|
||||||
DESTINATION ${OV_CPACK_INCLUDEDIR}/ie
|
DESTINATION ${OV_CPACK_INCLUDEDIR}/ie
|
||||||
COMPONENT ${OV_CPACK_COMP_CORE_C_DEV})
|
COMPONENT ${OV_CPACK_COMP_CORE_C_DEV})
|
||||||
|
|
||||||
install(DIRECTORY ${OpenVINO_C_API_SOURCE_DIR}/include/openvino/
|
install(DIRECTORY ${OpenVINO_C_API_SOURCE_DIR}/include/openvino/
|
||||||
DESTINATION ${OV_CPACK_INCLUDEDIR}/openvino
|
DESTINATION ${OV_CPACK_INCLUDEDIR}/openvino
|
||||||
COMPONENT ${OV_CPACK_COMP_CORE_C_DEV})
|
COMPONENT ${OV_CPACK_COMP_CORE_C_DEV})
|
||||||
|
@ -12,8 +12,13 @@ add_library(openvino::itt ALIAS ${TARGET_NAME})
|
|||||||
target_link_libraries(${TARGET_NAME} PUBLIC openvino::util)
|
target_link_libraries(${TARGET_NAME} PUBLIC openvino::util)
|
||||||
|
|
||||||
if(ENABLE_PROFILING_ITT)
|
if(ENABLE_PROFILING_ITT)
|
||||||
target_link_libraries(${TARGET_NAME} PUBLIC
|
if(TARGET ittapi::ittnotify)
|
||||||
$<IF:$<TARGET_EXISTS:ittapi::ittnotify>,ittapi::ittnotify,ittapi::ittapi>)
|
set(itt_dependency ittapi::ittnotify)
|
||||||
|
else()
|
||||||
|
set(itt_dependency ittapi::ittapi)
|
||||||
|
endif()
|
||||||
|
target_link_libraries(${TARGET_NAME} PUBLIC ${itt_dependency})
|
||||||
|
|
||||||
if(ENABLE_PROFILING_FILTER STREQUAL "ALL")
|
if(ENABLE_PROFILING_FILTER STREQUAL "ALL")
|
||||||
target_compile_definitions(${TARGET_NAME} PUBLIC
|
target_compile_definitions(${TARGET_NAME} PUBLIC
|
||||||
ENABLE_PROFILING_ALL
|
ENABLE_PROFILING_ALL
|
||||||
|
@ -53,10 +53,6 @@ target_include_directories(${TARGET_NAME} INTERFACE
|
|||||||
|
|
||||||
set_target_properties(${TARGET_NAME}_obj PROPERTIES INTERPROCEDURAL_OPTIMIZATION_RELEASE ${ENABLE_LTO})
|
set_target_properties(${TARGET_NAME}_obj PROPERTIES INTERPROCEDURAL_OPTIMIZATION_RELEASE ${ENABLE_LTO})
|
||||||
|
|
||||||
# developer package
|
|
||||||
|
|
||||||
openvino_developer_export_targets(COMPONENT core_legacy TARGETS ${TARGET_NAME})
|
|
||||||
|
|
||||||
if(ENABLE_TESTS)
|
if(ENABLE_TESTS)
|
||||||
add_subdirectory(tests)
|
add_subdirectory(tests)
|
||||||
endif()
|
endif()
|
||||||
|
@ -58,10 +58,6 @@ ov_abi_free_target(${TARGET_NAME}_obj)
|
|||||||
|
|
||||||
set_target_properties(${TARGET_NAME}_obj PROPERTIES INTERPROCEDURAL_OPTIMIZATION_RELEASE ${ENABLE_LTO})
|
set_target_properties(${TARGET_NAME}_obj PROPERTIES INTERPROCEDURAL_OPTIMIZATION_RELEASE ${ENABLE_LTO})
|
||||||
|
|
||||||
# developer package
|
|
||||||
|
|
||||||
openvino_developer_export_targets(COMPONENT core_legacy TARGETS ${TARGET_NAME})
|
|
||||||
|
|
||||||
# temporary workaround for fatal error LNK1248: image size (1004722F6) exceeds maximum
|
# temporary workaround for fatal error LNK1248: image size (1004722F6) exceeds maximum
|
||||||
# allowable size (FFFFFFFF)
|
# allowable size (FFFFFFFF)
|
||||||
# the symbolic debugging information will be stored in a separate .pdb file.
|
# the symbolic debugging information will be stored in a separate .pdb file.
|
||||||
|
@ -75,8 +75,6 @@ add_library(ngraph::${TARGET_NAME} ALIAS ${TARGET_NAME})
|
|||||||
add_library(openvino::frontend::common ALIAS ${TARGET_NAME})
|
add_library(openvino::frontend::common ALIAS ${TARGET_NAME})
|
||||||
add_library(${TARGET_NAME}::static ALIAS ${TARGET_NAME})
|
add_library(${TARGET_NAME}::static ALIAS ${TARGET_NAME})
|
||||||
|
|
||||||
openvino_developer_export_targets(COMPONENT core_legacy TARGETS ${TARGET_NAME})
|
|
||||||
|
|
||||||
# Installation rules header files
|
# Installation rules header files
|
||||||
|
|
||||||
install(DIRECTORY ${FRONTEND_INCLUDE_DIR}/openvino
|
install(DIRECTORY ${FRONTEND_INCLUDE_DIR}/openvino
|
||||||
|
@ -83,10 +83,6 @@ set_target_properties(${TARGET_NAME}_s PROPERTIES
|
|||||||
set_target_properties(${TARGET_NAME} ${TARGET_NAME}_obj
|
set_target_properties(${TARGET_NAME} ${TARGET_NAME}_obj
|
||||||
PROPERTIES INTERPROCEDURAL_OPTIMIZATION_RELEASE ${ENABLE_LTO})
|
PROPERTIES INTERPROCEDURAL_OPTIMIZATION_RELEASE ${ENABLE_LTO})
|
||||||
|
|
||||||
# developer package
|
|
||||||
|
|
||||||
openvino_developer_export_targets(COMPONENT core_legacy TARGETS ${TARGET_NAME})
|
|
||||||
|
|
||||||
# install
|
# install
|
||||||
|
|
||||||
ov_install_static_lib(${TARGET_NAME} ${OV_CPACK_COMP_CORE} OPTIONAL)
|
ov_install_static_lib(${TARGET_NAME} ${OV_CPACK_COMP_CORE} OPTIONAL)
|
||||||
|
@ -42,8 +42,3 @@ if (ENABLE_DATA)
|
|||||||
add_dependencies(${TARGET_NAME} data)
|
add_dependencies(${TARGET_NAME} data)
|
||||||
add_dependencies(${TARGET_NAME}_s data)
|
add_dependencies(${TARGET_NAME}_s data)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
# developer package
|
|
||||||
|
|
||||||
openvino_developer_export_targets(COMPONENT tests
|
|
||||||
TARGETS ieTestHelpers ieTestHelpers_s)
|
|
||||||
|
2
thirdparty/ittapi/CMakeLists.txt
vendored
2
thirdparty/ittapi/CMakeLists.txt
vendored
@ -26,5 +26,5 @@ else()
|
|||||||
add_library(ittapi::ittnotify ALIAS ittnotify)
|
add_library(ittapi::ittnotify ALIAS ittnotify)
|
||||||
|
|
||||||
openvino_developer_export_targets(COMPONENT openvino_common TARGETS ittapi::ittnotify)
|
openvino_developer_export_targets(COMPONENT openvino_common TARGETS ittapi::ittnotify)
|
||||||
ov_install_static_lib(ittapi::ittnotify ${OV_CPACK_COMP_CORE})
|
ov_install_static_lib(ittnotify ${OV_CPACK_COMP_CORE})
|
||||||
endif()
|
endif()
|
||||||
|
Loading…
Reference in New Issue
Block a user