Preserve directory structure and add flatbuffers dependency

This commit is contained in:
unda 2024-09-26 23:00:13 +00:00
parent db48d2ff7b
commit c0682b71b3
2 changed files with 6 additions and 1 deletions

View File

@ -138,8 +138,12 @@ cp "${TENSORFLOW_DIR}/bazel-bin/tensorflow/lite/python/interpreter_wrapper/_pywr
bazel ${BAZEL_STARTUP_OPTIONS} build -c opt -s --config=monolithic --config=nogcp --config=nonccl \
${BAZEL_FLAGS} ${CUSTOM_BAZEL_FLAGS} //tensorflow/lite/python:schema_py
mkdir "${BUILD_DIR}/ai_edge_litert/python"
cp "${TENSORFLOW_DIR}/bazel-bin/tensorflow/lite/python/schema_py_generated.py" \
"${BUILD_DIR}/ai_edge_litert"
"${BUILD_DIR}/ai_edge_litert/python/"
touch "${BUILD_DIR}/ai_edge_litert/python/__init__.py"
# Bazel generates the wrapper library with r-x permissions for user.
# At least on Windows, we need write permissions to delete the file.

View File

@ -61,6 +61,7 @@ setup(
package_dir={'': '.'},
package_data={'': ['*.so', '*.pyd']},
install_requires=[
'flatbuffers',
'numpy >= 1.23.2', # Better to keep sync with both TF ci_build
# and OpenCV-Python requirement.
],