@@ -114,6 +114,29 @@ do_install() {
${D}${datadir}/label_image
+ # install the headers also
+ cd ${S}
+ for header in `find ./tensorflow/lite -type f -name *.h`; do
+ install -D -m 0644 $header ${D}${includedir}/$header
+ done
+
+ for header in `find ./tensorflow/compiler/mlir -type f -name *.h`; do
+ install -D -m 0644 $header ${D}${includedir}/$header
+ done
+
+ for header in `find ./tensorflow/core/public -type f -name *.h`; do
+ install -D -m 0644 $header ${D}${includedir}/$header
+ done
+ cd -
+
+ cd ${WORKDIR}/bazel/output_base/external/flatbuffers/include
+ for header in `find ./flatbuffers -type f`; do
+ install -D -m 0644 $header ${D}${includedir}/$header
+ done
+ cd -
+
+ # header installation done
+
#echo "Installing pip package"
install -d ${D}/${PYTHON_SITEPACKAGES_DIR}
${STAGING_BINDIR_NATIVE}/pip3 install --disable-pip-version-check -v \
The headers are not packages with tensorflow-lite, making it not easy to compile any applications using them. This patch copies the headers from the source and output folder to the includedir. The patch was derived from the content of a pre-compiled tflite package[1], and from compilation error messages that were returned by rpicam-apps recipe (which uses this recipe as an optional dependency) [1]: https://github.com/prepkg/tensorflow-lite-raspberrypi/releases/tag/2.20.0 Signed-off-by: Gyorgy Sarvari <skandigraun@gmail.com> --- .../tensorflow/tensorflow-lite_2.19.0.bb | 23 +++++++++++++++++++ 1 file changed, 23 insertions(+)