File tree Expand file tree Collapse file tree 1 file changed +6
-2
lines changed
Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Original file line number Diff line number Diff line change @@ -449,12 +449,16 @@ if(ENABLE_OV_TF_LITE_FRONTEND OR ENABLE_INTEL_NPU)
449449 add_subdirectory (thirdparty/flatbuffers EXCLUDE_FROM_ALL )
450450 if (ENABLE_INTEL_NPU)
451451 # NPU plugin requires flatbuffers to be built always
452- add_custom_target (npu_compiler_flatbuffers ALL DEPENDS flatbuffers flatc )
452+ add_custom_target (npu_compiler_flatbuffers ALL DEPENDS flatbuffers ${flatbuffers_DEPENDENCY} )
453453 set (flatbuffers_root "${CMAKE_CURRENT_SOURCE_DIR} /thirdparty/flatbuffers/flatbuffers" )
454454 ov_developer_package_export_targets(TARGET flatbuffers
455455 INSTALL_INCLUDE_DIRECTORIES "${flatbuffers_root} /include/" )
456456 ov_developer_package_export_targets(TARGET ProjectConfig)
457- install (TARGETS flatc DESTINATION "developer_package/bin" COMPONENT developer_package EXCLUDE_FROM_ALL )
457+ install (FILES ${flatbuffers_COMPILER} DESTINATION "developer_package/bin" COMPONENT developer_package EXCLUDE_FROM_ALL )
458+ if (CMAKE_CROSSCOMPILING )
459+ # NPU compiler requires flatbuffers and flatc defined as target
460+ add_executable (flatc ALIAS flatbuffers::flatc)
461+ endif ()
458462 endif ()
459463 endif ()
460464
You can’t perform that action at this time.
0 commit comments