Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added extra flatc variables used by NPU #22620

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions thirdparty/dependencies.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -400,6 +400,10 @@ if(ENABLE_OV_TF_LITE_FRONTEND)
set(flatbuffers_COMPILER flatbuffers::flatc)
else()
add_subdirectory(thirdparty/flatbuffers EXCLUDE_FROM_ALL)

# used by NPU repo
set(flatc_COMMAND flatc)
set(flatc_TARGET flatc)
endif()

# set additional variables, used in other places of our cmake scripts
Expand Down
7 changes: 3 additions & 4 deletions thirdparty/flatbuffers/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,6 @@
#

set(FLATBUFFERS_BUILD_TESTS OFF CACHE BOOL "" FORCE)
set(FLATBUFFERS_BUILD_FLATLIB OFF CACHE BOOL "" FORCE)
set(FLATBUFFERS_BUILD_FLATHASH OFF CACHE BOOL "" FORCE)
set(FLATBUFFERS_INSTALL OFF CACHE BOOL "" FORCE)
set(FLATBUFFERS_CPP_STD ${CMAKE_CXX_STANDARD})

Expand Down Expand Up @@ -35,9 +33,10 @@ else()
TARGET_NAME host_flatc
NATIVE_INSTALL_DIR "${HOST_FLATC_INSTALL_DIR}"
CMAKE_ARGS "-DFLATBUFFERS_BUILD_TESTS=${FLATBUFFERS_BUILD_TESTS}"
"-DFLATBUFFERS_BUILD_FLATLIB=${FLATBUFFERS_BUILD_FLATLIB}"
"-DFLATBUFFERS_BUILD_FLATLIB=OFF"
"-DFLATBUFFERS_BUILD_FLATC=ON"
"-DFLATBUFFERS_BUILD_SHAREDLIB=OFF"
"-DFLATBUFFERS_CPP_STD=${FLATBUFFERS_CPP_STD}"
"-DFLATBUFFERS_BUILD_FLATHASH=${FLATBUFFERS_BUILD_FLATHASH}"
NATIVE_SOURCE_SUBDIR "flatbuffers"
NATIVE_TARGETS flatc)

Expand Down
Loading