NobuoTsukamoto / meta-tensorflow-lite

Yocto layer for TensorFlow Lite interpreter with Python / C++.
MIT License
33 stars 18 forks source link

libedgetpu fails compilation with flatbuffer errors #60

Closed stiggy87 closed 1 year ago

stiggy87 commented 1 year ago

I've been trying to get this to work with Petalinux 2022.2. I've added everything I needed and when I try to build the libedgetpu-std I get various errors related to:

/workspace/zynqpus/os/build/tmp/work/cortexa72-cortexa53-xilinx-linux/libedgetpu-std/grouper-r0/recipe-sysroot/usr/include/flatbuffers/flatbuffers.h:2643:8: note: candidate: 'bool flatbuffers::Table::VerifyField(const flatbuffers::Verifier&, flatbuffers::voffset_t) const [with T = unsigned int; flatbuffers::voffset_t = short unsigned int]'
|  2643 |   bool VerifyField(const Verifier &verifier, voffset_t field) const {
|       |        ^~~~~~~~~~~

I've tried everything to make sure the package uses the flatbuffers, but nothing seems to work. It looks like a dependency isn't being targeted and that there needs to be another patch to the makefile to make it work.

Any suggestions on what changes should be done?

I do want to mention that the libedgetpu repo has a similar open issue: https://github.com/google-coral/libedgetpu/issues/40

stiggy87 commented 1 year ago

This was an issue with my yocto project. I was using Petalinux 2022.2, which is honister, and doesn't have latest flatbuffers/abseil-cpp. Adding these manually fixed it.