[flexbuild v24.12][imx8mpevk] debian build failed in ml(tflite_ethosu_delegate)

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

[flexbuild v24.12][imx8mpevk] debian build failed in ml(tflite_ethosu_delegate)

1,229 Views
yoooh8668
Contributor III

Hi,

We are now trying the flexbuild of Debian 12, but it build failed on "tflite_ethosu_delegate"

 

We know the in v24.06 does not include the ml(machine learning) in build process.

But we do want to enable the ml in debian.

 

Here is the log:

[root@fbdebian tn_debian_flexbuild]$ bld tflite_ethosu_delegate

Building tflite_ethosu_delegate ... 
repo: tflite_ethosu_delegate
tag: lf-6.6.36-2.1.0
-- Setting build type to Release, for debug builds use'-DCMAKE_BUILD_TYPE=Debug'.
-- Cloning absl repository revision fb3621f4f897824c0dbe0615fa94543df6192f30, found in /home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/../third_party/absl/workspace.bzl
CMake Warning at build_debian_arm64/abseil-cpp/CMakeLists.txt:77 (message):
  A future Abseil release will default ABSL_PROPAGATE_CXX_STD to ON for CMake
  3.8 and up.  We recommend enabling this option to ensure your project still
  builds correctly.


-- Cloning eigen repository revision aa6964bf3a34fd607837dd8123bc42465185c4f8, found in /home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/../third_party/eigen3/workspace.bzl
-- Standard libraries to link to explicitly: none
-- The Fortran compiler identification is unknown
-- Could NOT find CLANG_FORMAT: Found unsuitable version "0.0", but required is exact version "9" (found CLANG_FORMAT_EXECUTABLE-NOTFOUND)
-- 
-- Configured Eigen 3.4.90
-- 
-- Cloning farmhash repository revision 0d859a811870d10f53a594927d0d0b97573ad06d, found in /home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/../third_party/farmhash/workspace.bzl
-- Cloning fft2d repository from https://storage.googleapis.com/mirror.tensorflow.org/github.com/petewarden/OouraFFT/archive/v1.0.tar.gz, found in /home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/workspace2.bzl
CMake Warning (dev) at /usr/share/cmake-3.25/Modules/FetchContent.cmake:1279 (message):
  The DOWNLOAD_EXTRACT_TIMESTAMP option was not given and policy CMP0135 is
  not set.  The policy's OLD behavior will be used.  When using a URL
  download, the timestamps of extracted files should preferably be that of
  the time of extraction, otherwise code that depends on the extracted
  contents might not be rebuilt if the URL changes.  The OLD behavior
  preserves the timestamps from the archive instead, but this is usually not
  what you want.  Update your project to the NEW behavior or specify the
  DOWNLOAD_EXTRACT_TIMESTAMP option with a value of true to avoid this
  robustness issue.
Call Stack (most recent call first):
  /home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/tools/cmake/modules/OverridableFetchContent.cmake:398 (FetchContent_Declare)
  /home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/tools/cmake/modules/fft2d.cmake:25 (OverridableFetchContent_Declare)
  /home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/tools/cmake/modules/Findfft2d.cmake:18 (include)
  /home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/CMakeLists.txt:166 (find_package)
This warning is for project developers.  Use -Wno-dev to suppress it.

-- Cloning flatbuffers repository from https://github.com/google/flatbuffers/archive/7d6d99c6befa635780a4e944d37ebfd58e68a108.tar.gz, found in /home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/../third_party/flatbuffers/workspace.bzl
-- Cloning flatbuffers repository revision 7d6d99c6befa635780a4e944d37ebfd58e68a108, found in /home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/../third_party/flatbuffers/workspace.bzl
CMake Warning (dev) at /usr/share/cmake-3.25/Modules/FetchContent.cmake:1279 (message):
  The DOWNLOAD_EXTRACT_TIMESTAMP option was not given and policy CMP0135 is
  not set.  The policy's OLD behavior will be used.  When using a URL
  download, the timestamps of extracted files should preferably be that of
  the time of extraction, otherwise code that depends on the extracted
  contents might not be rebuilt if the URL changes.  The OLD behavior
  preserves the timestamps from the archive instead, but this is usually not
  what you want.  Update your project to the NEW behavior or specify the
  DOWNLOAD_EXTRACT_TIMESTAMP option with a value of true to avoid this
  robustness issue.
Call Stack (most recent call first):
  /home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/tools/cmake/modules/OverridableFetchContent.cmake:398 (FetchContent_Declare)
  /home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/tools/cmake/modules/flatbuffers.cmake:33 (OverridableFetchContent_Declare)
  /home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/tools/cmake/modules/FindFlatBuffers.cmake:18 (include)
  /home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/CMakeLists.txt:167 (find_package)
This warning is for project developers.  Use -Wno-dev to suppress it.

-- Proceeding with version: 23.5.26.0
-- CMAKE_CXX_FLAGS: -O2 -pipe -g -fPIC -feliminate-unused-debug-types -I/home/joezhang/workspace/tn_debian_flexbuild/build_lsdk2412/apps/apps_arm64_debian_desktop/usr/include -I/home/joezhang/workspace/tn_debian_flexbuild/build_lsdk2412/rfs/rootfs_lsdk2412_debian_desktop_arm64/usr/include
-- Cloning gemmlowp repository revision 16e8662c34917be0065110bfcd9cc27d30f52fdf, found in /home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/../third_party/gemmlowp/workspace.bzl
-- Cloning neon2sse repository from https://storage.googleapis.com/mirror.tensorflow.org/github.com/intel/ARM_NEON_2_x86_SSE/archive/a15b489e1222b2087007546b4912e21293ea86ff.tar.gz, found in /home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/workspace2.bzl
CMake Warning (dev) at /usr/share/cmake-3.25/Modules/FetchContent.cmake:1279 (message):
  The DOWNLOAD_EXTRACT_TIMESTAMP option was not given and policy CMP0135 is
  not set.  The policy's OLD behavior will be used.  When using a URL
  download, the timestamps of extracted files should preferably be that of
  the time of extraction, otherwise code that depends on the extracted
  contents might not be rebuilt if the URL changes.  The OLD behavior
  preserves the timestamps from the archive instead, but this is usually not
  what you want.  Update your project to the NEW behavior or specify the
  DOWNLOAD_EXTRACT_TIMESTAMP option with a value of true to avoid this
  robustness issue.
Call Stack (most recent call first):
  /home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/tools/cmake/modules/OverridableFetchContent.cmake:398 (FetchContent_Declare)
  /home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/tools/cmake/modules/neon2sse.cmake:25 (OverridableFetchContent_Declare)
  /home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/tools/cmake/modules/FindNEON_2_SSE.cmake:18 (include)
  /home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/CMakeLists.txt:170 (find_package)
This warning is for project developers.  Use -Wno-dev to suppress it.

-- Cloning cpuinfo repository revision ef634603954d88d2643d5809011288b890ac126e, found in /home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/workspace2.bzl
-- Cloning ruy repository revision 3286a34cc8de6149ac6844107dfdffac91531e72, found in /home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/../third_party/ruy/workspace.bzl
-- Cloning xnnpack repository revision dcbfffb80fb4f6fcfcfb5b3723854ec8797fa546, found in /home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/workspace2.bzl
-- Could NOT find Python (missing: Interpreter Development Development.Module Development.Embed) (found version "3.11.2")
-- Configuring done
-- Generating done
-- Build files have been written to: /home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite_ethosu_delegate/build_debian_arm64
Building CXX object CMakeFiles/ethosu_delegate.dir/ethosu_delegate.cc.o
Building CXX object CMakeFiles/ethosu_delegate.dir/ethosu_delegate_utils.cc.o
Building CXX object CMakeFiles/ethosu_delegate.dir/ethosu_supported_ops.cc.o
In file included from /home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/reference_ops.h:83,
                 from /home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/optimized/optimized_ops.h:56,
                 from /home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite_ethosu_delegate/ethosu_supported_ops.cc:10:
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/string_comparisons.h:28:36: error: 'StringRef' does not name a type
   28 | inline bool StringRefEqualFn(const StringRef& lhs, const StringRef& rhs) {
      |                                    ^~~~~~~~~
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/string_comparisons.h:28:58: error: 'StringRef' does not name a type
   28 | inline bool StringRefEqualFn(const StringRef& lhs, const StringRef& rhs) {
      |                                                          ^~~~~~~~~
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/string_comparisons.h: In function 'bool tflite::reference_ops::StringRefEqualFn(const int&, const int&)':
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/string_comparisons.h:29:11: error: request for member 'len' in 'lhs', which is of non-class type 'const int'
   29 |   if (lhs.len != rhs.len) return false;
      |           ^~~
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/string_comparisons.h:29:22: error: request for member 'len' in 'rhs', which is of non-class type 'const int'
   29 |   if (lhs.len != rhs.len) return false;
      |                      ^~~
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/string_comparisons.h:30:27: error: request for member 'len' in 'lhs', which is of non-class type 'const int'
   30 |   for (int i = 0; i < lhs.len; ++i) {
      |                           ^~~
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/string_comparisons.h:31:13: error: request for member 'str' in 'lhs', which is of non-class type 'const int'
   31 |     if (lhs.str[i] != rhs.str[i]) return false;
      |             ^~~
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/string_comparisons.h:31:27: error: request for member 'str' in 'rhs', which is of non-class type 'const int'
   31 |     if (lhs.str[i] != rhs.str[i]) return false;
      |                           ^~~
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/string_comparisons.h: At global scope:
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/string_comparisons.h:36:39: error: 'StringRef' does not name a type
   36 | inline bool StringRefNotEqualFn(const StringRef& lhs, const StringRef& rhs) {
      |                                       ^~~~~~~~~
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/string_comparisons.h:36:61: error: 'StringRef' does not name a type
   36 | inline bool StringRefNotEqualFn(const StringRef& lhs, const StringRef& rhs) {
      |                                                             ^~~~~~~~~
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/string_comparisons.h:40:50: error: 'StringRef' does not name a type
   40 | inline void ComparisonStringImpl(bool (*F)(const StringRef&, const StringRef&),
      |                                                  ^~~~~~~~~
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/string_comparisons.h:40:68: error: 'StringRef' does not name a type
   40 | inline void ComparisonStringImpl(bool (*F)(const StringRef&, const StringRef&),
      |                                                                    ^~~~~~~~~
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/string_comparisons.h: In function 'void tflite::reference_ops::ComparisonStringImpl(bool (*)(const int&, const int&), const tflite::RuntimeShape&, const TfLiteTensor*, const tflite::RuntimeShape&, const TfLiteTensor*, const tflite::RuntimeShape&, bool*)':
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/string_comparisons.h:50:22: error: 'GetString' was not declared in this scope; did you mean 'testing'?
   50 |     const auto lhs = GetString(input1, i);
      |                      ^~~~~~~~~
      |                      testing
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/string_comparisons.h: At global scope:
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/string_comparisons.h:57:21: error: 'StringRef' does not name a type
   57 |     bool (*F)(const StringRef&, const StringRef&),
      |                     ^~~~~~~~~
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/string_comparisons.h:57:39: error: 'StringRef' does not name a type
   57 |     bool (*F)(const StringRef&, const StringRef&),
      |                                       ^~~~~~~~~
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/string_comparisons.h: In function 'void tflite::reference_ops::BroadcastComparison4DSlowStringImpl(bool (*)(const int&, const int&), const tflite::RuntimeShape&, const TfLiteTensor*, const tflite::RuntimeShape&, const TfLiteTensor*, const tflite::RuntimeShape&, bool*)':
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/string_comparisons.h:71:15: error: 'GetString' was not declared in this scope; did you mean 'testing'?
   71 |               GetString(input1, SubscriptToIndex(dims.desc1, b, y, x, c));
      |               ^~~~~~~~~
      |               testing
In file included from /home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/reference_ops.h:89:
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/tensor.h: At global scope:
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/tensor.h:26:30: error: 'string' was not declared in this scope; did you mean 'std::string'?
   26 | class SequentialTensorWriter<string> {
      |                              ^~~~~~
      |                              std::string
In file included from /usr/aarch64-linux-gnu/include/c++/12/iosfwd:39,
                 from /usr/aarch64-linux-gnu/include/c++/12/bits/shared_ptr.h:52,
                 from /usr/aarch64-linux-gnu/include/c++/12/memory:77,
                 from /home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/optimized/optimized_ops.h:26:
/usr/aarch64-linux-gnu/include/c++/12/bits/stringfwd.h:77:33: note: 'std::string' declared here
   77 |   typedef basic_string<char>    string;
      |                                 ^~~~~~
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/tensor.h:26:36: error: template argument 1 is invalid
   26 | class SequentialTensorWriter<string> {
      |                                    ^
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/reference_ops.h: In function 'TfLiteStatus tflite::reference_ops::GatherNdString(const tflite::RuntimeShape&, const TfLiteTensor*, const tflite::RuntimeShape&, const IndicesT*, const tflite::RuntimeShape&, TfLiteTensor*)':
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/reference_ops.h:641:3: error: 'DynamicBuffer' was not declared in this scope
  641 |   DynamicBuffer buffer;
      |   ^~~~~~~~~~~~~
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/reference_ops.h:651:7: error: 'buffer' was not declared in this scope; did you mean 'setbuffer'?
  651 |       buffer.AddString(GetString(params_data, from_pos + j));
      |       ^~~~~~
      |       setbuffer
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/reference_ops.h:651:24: error: there are no arguments to 'GetString' that depend on a template parameter, so a declaration of 'GetString' must be available [-fpermissive]
  651 |       buffer.AddString(GetString(params_data, from_pos + j));
      |                        ^~~~~~~~~
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/reference_ops.h:651:24: note: (if you use '-fpermissive', G++ will accept your code, but allowing the use of an undeclared name is deprecated)
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/reference_ops.h:654:3: error: 'buffer' was not declared in this scope; did you mean 'setbuffer'?
  654 |   buffer.WriteToTensor(output_data, /*new_shape=*/nullptr);
      |   ^~~~~~
      |   setbuffer
In file included from /home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/reference_ops.h:83,
                 from /home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/optimized/optimized_ops.h:56,
                 from /home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite_ethosu_delegate/ethosu_delegate_utils.h:16,
                 from /home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite_ethosu_delegate/ethosu_delegate.cc:27:
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/string_comparisons.h:28:36: error: 'StringRef' does not name a type
   28 | inline bool StringRefEqualFn(const StringRef& lhs, const StringRef& rhs) {
      |                                    ^~~~~~~~~
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/string_comparisons.h:28:58: error: 'StringRef' does not name a type
   28 | inline bool StringRefEqualFn(const StringRef& lhs, const StringRef& rhs) {
      |                                                          ^~~~~~~~~
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/string_comparisons.h: In function 'bool tflite::reference_ops::StringRefEqualFn(const int&, const int&)':
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/string_comparisons.h:29:11: error: request for member 'len' in 'lhs', which is of non-class type 'const int'
   29 |   if (lhs.len != rhs.len) return false;
      |           ^~~
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/string_comparisons.h:29:22: error: request for member 'len' in 'rhs', which is of non-class type 'const int'
   29 |   if (lhs.len != rhs.len) return false;
      |                      ^~~
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/string_comparisons.h:30:27: error: request for member 'len' in 'lhs', which is of non-class type 'const int'
   30 |   for (int i = 0; i < lhs.len; ++i) {
      |                           ^~~
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/string_comparisons.h:31:13: error: request for member 'str' in 'lhs', which is of non-class type 'const int'
   31 |     if (lhs.str[i] != rhs.str[i]) return false;
      |             ^~~
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/string_comparisons.h:31:27: error: request for member 'str' in 'rhs', which is of non-class type 'const int'
   31 |     if (lhs.str[i] != rhs.str[i]) return false;
      |                           ^~~
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/string_comparisons.h: At global scope:
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/string_comparisons.h:36:39: error: 'StringRef' does not name a type
   36 | inline bool StringRefNotEqualFn(const StringRef& lhs, const StringRef& rhs) {
      |                                       ^~~~~~~~~
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/string_comparisons.h:36:61: error: 'StringRef' does not name a type
   36 | inline bool StringRefNotEqualFn(const StringRef& lhs, const StringRef& rhs) {
      |                                                             ^~~~~~~~~
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/string_comparisons.h:40:50: error: 'StringRef' does not name a type
   40 | inline void ComparisonStringImpl(bool (*F)(const StringRef&, const StringRef&),
      |                                                  ^~~~~~~~~
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/string_comparisons.h:40:68: error: 'StringRef' does not name a type
   40 | inline void ComparisonStringImpl(bool (*F)(const StringRef&, const StringRef&),
      |                                                                    ^~~~~~~~~
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/string_comparisons.h: In function 'void tflite::reference_ops::ComparisonStringImpl(bool (*)(const int&, const int&), const tflite::RuntimeShape&, const TfLiteTensor*, const tflite::RuntimeShape&, const TfLiteTensor*, const tflite::RuntimeShape&, bool*)':
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/string_comparisons.h:50:22: error: 'GetString' was not declared in this scope; did you mean 'testing'?
   50 |     const auto lhs = GetString(input1, i);
      |                      ^~~~~~~~~
      |                      testing
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/string_comparisons.h: At global scope:
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/string_comparisons.h:57:21: error: 'StringRef' does not name a type
   57 |     bool (*F)(const StringRef&, const StringRef&),
      |                     ^~~~~~~~~
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/string_comparisons.h:57:39: error: 'StringRef' does not name a type
   57 |     bool (*F)(const StringRef&, const StringRef&),
      |                                       ^~~~~~~~~
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/string_comparisons.h: In function 'void tflite::reference_ops::BroadcastComparison4DSlowStringImpl(bool (*)(const int&, const int&), const tflite::RuntimeShape&, const TfLiteTensor*, const tflite::RuntimeShape&, const TfLiteTensor*, const tflite::RuntimeShape&, bool*)':
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/string_comparisons.h:71:15: error: 'GetString' was not declared in this scope; did you mean 'testing'?
   71 |               GetString(input1, SubscriptToIndex(dims.desc1, b, y, x, c));
      |               ^~~~~~~~~
      |               testing
In file included from /home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/reference_ops.h:89:
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/tensor.h: At global scope:
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/tensor.h:26:30: error: 'string' was not declared in this scope; did you mean 'std::string'?
   26 | class SequentialTensorWriter<string> {
      |                              ^~~~~~
      |                              std::string
In file included from /usr/aarch64-linux-gnu/include/c++/12/string:39,
                 from /home/joezhang/workspace/tn_debian_flexbuild/build_lsdk2412/apps/apps_arm64_debian_desktop/usr/include/flatbuffers/base.h:41,
                 from /home/joezhang/workspace/tn_debian_flexbuild/build_lsdk2412/apps/apps_arm64_debian_desktop/usr/include/flatbuffers/flexbuffers.h:23,
                 from /home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite_ethosu_delegate/ethosu_delegate.cc:23:
/usr/aarch64-linux-gnu/include/c++/12/bits/stringfwd.h:77:33: note: 'std::string' declared here
   77 |   typedef basic_string<char>    string;
      |                                 ^~~~~~
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/tensor.h:26:36: error: template argument 1 is invalid
   26 | class SequentialTensorWriter<string> {
      |                                    ^
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/reference_ops.h: In function 'TfLiteStatus tflite::reference_ops::GatherNdString(const tflite::RuntimeShape&, const TfLiteTensor*, const tflite::RuntimeShape&, const IndicesT*, const tflite::RuntimeShape&, TfLiteTensor*)':
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/reference_ops.h:641:3: error: 'DynamicBuffer' was not declared in this scope
  641 |   DynamicBuffer buffer;
      |   ^~~~~~~~~~~~~
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/reference_ops.h:651:7: error: 'buffer' was not declared in this scope; did you mean 'setbuffer'?
  651 |       buffer.AddString(GetString(params_data, from_pos + j));
      |       ^~~~~~
      |       setbuffer
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/reference_ops.h:651:24: error: there are no arguments to 'GetString' that depend on a template parameter, so a declaration of 'GetString' must be available [-fpermissive]
  651 |       buffer.AddString(GetString(params_data, from_pos + j));
      |                        ^~~~~~~~~
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/reference_ops.h:651:24: note: (if you use '-fpermissive', G++ will accept your code, but allowing the use of an undeclared name is deprecated)
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/reference_ops.h:654:3: error: 'buffer' was not declared in this scope; did you mean 'setbuffer'?
  654 |   buffer.WriteToTensor(output_data, /*new_shape=*/nullptr);
      |   ^~~~~~
      |   setbuffer
In file included from /home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/reference_ops.h:83,
                 from /home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/optimized/optimized_ops.h:56,
                 from /home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite_ethosu_delegate/ethosu_delegate_utils.h:16,
                 from /home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite_ethosu_delegate/ethosu_delegate_utils.cc:9:
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/string_comparisons.h:28:36: error: 'StringRef' does not name a type
   28 | inline bool StringRefEqualFn(const StringRef& lhs, const StringRef& rhs) {
      |                                    ^~~~~~~~~
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/string_comparisons.h:28:58: error: 'StringRef' does not name a type
   28 | inline bool StringRefEqualFn(const StringRef& lhs, const StringRef& rhs) {
      |                                                          ^~~~~~~~~
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/string_comparisons.h: In function 'bool tflite::reference_ops::StringRefEqualFn(const int&, const int&)':
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/string_comparisons.h:29:11: error: request for member 'len' in 'lhs', which is of non-class type 'const int'
   29 |   if (lhs.len != rhs.len) return false;
      |           ^~~
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/string_comparisons.h:29:22: error: request for member 'len' in 'rhs', which is of non-class type 'const int'
   29 |   if (lhs.len != rhs.len) return false;
      |                      ^~~
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/string_comparisons.h:30:27: error: request for member 'len' in 'lhs', which is of non-class type 'const int'
   30 |   for (int i = 0; i < lhs.len; ++i) {
      |                           ^~~
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/string_comparisons.h:31:13: error: request for member 'str' in 'lhs', which is of non-class type 'const int'
   31 |     if (lhs.str[i] != rhs.str[i]) return false;
      |             ^~~
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/string_comparisons.h:31:27: error: request for member 'str' in 'rhs', which is of non-class type 'const int'
   31 |     if (lhs.str[i] != rhs.str[i]) return false;
      |                           ^~~
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/string_comparisons.h: At global scope:
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/string_comparisons.h:36:39: error: 'StringRef' does not name a type
   36 | inline bool StringRefNotEqualFn(const StringRef& lhs, const StringRef& rhs) {
      |                                       ^~~~~~~~~
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/string_comparisons.h:36:61: error: 'StringRef' does not name a type
   36 | inline bool StringRefNotEqualFn(const StringRef& lhs, const StringRef& rhs) {
      |                                                             ^~~~~~~~~
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/string_comparisons.h:40:50: error: 'StringRef' does not name a type
   40 | inline void ComparisonStringImpl(bool (*F)(const StringRef&, const StringRef&),
      |                                                  ^~~~~~~~~
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/string_comparisons.h:40:68: error: 'StringRef' does not name a type
   40 | inline void ComparisonStringImpl(bool (*F)(const StringRef&, const StringRef&),
      |                                                                    ^~~~~~~~~
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/string_comparisons.h: In function 'void tflite::reference_ops::ComparisonStringImpl(bool (*)(const int&, const int&), const tflite::RuntimeShape&, const TfLiteTensor*, const tflite::RuntimeShape&, const TfLiteTensor*, const tflite::RuntimeShape&, bool*)':
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/string_comparisons.h:50:22: error: 'GetString' was not declared in this scope; did you mean 'flatbuffers::GetString'?
   50 |     const auto lhs = GetString(input1, i);
      |                      ^~~~~~~~~
      |                      flatbuffers::GetString
In file included from /home/joezhang/workspace/tn_debian_flexbuild/build_lsdk2412/apps/apps_arm64_debian_desktop/usr/include/flatbuffers/flatbuffer_builder.h:34,
                 from /home/joezhang/workspace/tn_debian_flexbuild/build_lsdk2412/apps/apps_arm64_debian_desktop/usr/include/flatbuffers/flatbuffers.h:29,
                 from /home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/schema/schema_generated.h:21,
                 from /home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite_ethosu_delegate/tflite_enum_mapping.h:19,
                 from /home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite_ethosu_delegate/ethosu_delegate_utils.cc:8:
/home/joezhang/workspace/tn_debian_flexbuild/build_lsdk2412/apps/apps_arm64_debian_desktop/usr/include/flatbuffers/string.h:44:27: note: 'flatbuffers::GetString' declared here
   44 | static inline std::string GetString(const String *str) {
      |                           ^~~~~~~~~
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/string_comparisons.h: At global scope:
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/string_comparisons.h:57:21: error: 'StringRef' does not name a type
   57 |     bool (*F)(const StringRef&, const StringRef&),
      |                     ^~~~~~~~~
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/string_comparisons.h:57:39: error: 'StringRef' does not name a type
   57 |     bool (*F)(const StringRef&, const StringRef&),
      |                                       ^~~~~~~~~
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/string_comparisons.h: In function 'void tflite::reference_ops::BroadcastComparison4DSlowStringImpl(bool (*)(const int&, const int&), const tflite::RuntimeShape&, const TfLiteTensor*, const tflite::RuntimeShape&, const TfLiteTensor*, const tflite::RuntimeShape&, bool*)':
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/string_comparisons.h:71:15: error: 'GetString' was not declared in this scope; did you mean 'flatbuffers::GetString'?
   71 |               GetString(input1, SubscriptToIndex(dims.desc1, b, y, x, c));
      |               ^~~~~~~~~
      |               flatbuffers::GetString
/home/joezhang/workspace/tn_debian_flexbuild/build_lsdk2412/apps/apps_arm64_debian_desktop/usr/include/flatbuffers/string.h:44:27: note: 'flatbuffers::GetString' declared here
   44 | static inline std::string GetString(const String *str) {
      |                           ^~~~~~~~~
In file included from /home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/reference_ops.h:89:
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/tensor.h: At global scope:
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/tensor.h:26:30: error: 'string' was not declared in this scope; did you mean 'std::string'?
   26 | class SequentialTensorWriter<string> {
      |                              ^~~~~~
      |                              std::string
In file included from /usr/aarch64-linux-gnu/include/c++/12/iosfwd:39,
                 from /usr/aarch64-linux-gnu/include/c++/12/bits/shared_ptr.h:52,
                 from /usr/aarch64-linux-gnu/include/c++/12/memory:77,
                 from /home/joezhang/workspace/tn_debian_flexbuild/build_lsdk2412/apps/apps_arm64_debian_desktop/usr/include/flatbuffers/array.h:21,
                 from /home/joezhang/workspace/tn_debian_flexbuild/build_lsdk2412/apps/apps_arm64_debian_desktop/usr/include/flatbuffers/flatbuffers.h:24:
/usr/aarch64-linux-gnu/include/c++/12/bits/stringfwd.h:77:33: note: 'std::string' declared here
   77 |   typedef basic_string<char>    string;
      |                                 ^~~~~~
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/tensor.h:26:36: error: template argument 1 is invalid
   26 | class SequentialTensorWriter<string> {
      |                                    ^
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/reference_ops.h: In function 'TfLiteStatus tflite::reference_ops::GatherNdString(const tflite::RuntimeShape&, const TfLiteTensor*, const tflite::RuntimeShape&, const IndicesT*, const tflite::RuntimeShape&, TfLiteTensor*)':
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/reference_ops.h:641:3: error: 'DynamicBuffer' was not declared in this scope
  641 |   DynamicBuffer buffer;
      |   ^~~~~~~~~~~~~
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/reference_ops.h:651:7: error: 'buffer' was not declared in this scope; did you mean 'Buffer'?
  651 |       buffer.AddString(GetString(params_data, from_pos + j));
      |       ^~~~~~
      |       Buffer
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/reference_ops.h:651:24: error: there are no arguments to 'GetString' that depend on a template parameter, so a declaration of 'GetString' must be available [-fpermissive]
  651 |       buffer.AddString(GetString(params_data, from_pos + j));
      |                        ^~~~~~~~~
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/reference_ops.h:651:24: note: (if you use '-fpermissive', G++ will accept your code, but allowing the use of an undeclared name is deprecated)
/home/joezhang/workspace/tn_debian_flexbuild/components_lsdk2412/apps/ml/tflite/tensorflow/lite/kernels/internal/reference/reference_ops.h:654:3: error: 'buffer' was not declared in this scope; did you mean 'Buffer'?
  654 |   buffer.WriteToTensor(output_data, /*new_shape=*/nullptr);
      |   ^~~~~~
      |   Buffer
make[5]: *** [CMakeFiles/ethosu_delegate.dir/build.make:160: CMakeFiles/ethosu_delegate.dir/ethosu_supported_ops.cc.o] Error 1
make[5]: *** Waiting for unfinished jobs....
make[5]: *** [CMakeFiles/ethosu_delegate.dir/build.make:104: CMakeFiles/ethosu_delegate.dir/ethosu_delegate.cc.o] Error 1
make[5]: *** [CMakeFiles/ethosu_delegate.dir/build.make:146: CMakeFiles/ethosu_delegate.dir/ethosu_delegate_utils.cc.o] Error 1
make[4]: *** [CMakeFiles/Makefile2:1258: CMakeFiles/ethosu_delegate.dir/all] Error 2
make[3]: *** [CMakeFiles/Makefile2:1265: CMakeFiles/ethosu_delegate.dir/rule] Error 2
make[2]: *** [Makefile:169: ethosu_delegate] Error 2
make[1]: *** [/home/joezhang/workspace/tn_debian_flexbuild/src/apps/ml/tflite_ethosu_delegate.mk:11: tflite_ethosu_delegate] Error 2
make: *** [Makefile:21: tflite_ethosu_delegate] Error 2

Look like there is dependency issue in tensorflow => missing llvm(`StringRef`) library?

But `apt-get install llvm` in docker won't fix.

Add llvm in target rootfs won't fix, too.

joezhang@joezhang-System-Product-Name:~/workspace/tn_debian_flexbuild$ git diff
diff --git a/configs/debian/extra_packages_list b/configs/debian/extra_packages_list
index 54dede1..9064951 100644
--- a/configs/debian/extra_packages_list
+++ b/configs/debian/extra_packages_list
@@ -95,6 +95,7 @@ extra_server_devel_packages=" \
     libvorbis-dev \
     libjpeg62-turbo-dev \
     libjsoncpp-dev \
+    llvm-dev \
 "

Or I missing something in build process?

$ bld docker
$ . setup.env
$ bld host-dep
$ bld apps -p IMX 
# failed here...

 

THANKS~~~

Joe

Labels (1)
0 Kudos
Reply
18 Replies

42 Views
Zhiming_Liu
NXP TechSupport
NXP TechSupport

Hi @yoooh8668  @lvasa3091 @JasonFSYang @charleshuang @Edward_desplaines 

Update:

I test again referring on this github issues and it can be successfully compiled.

https://github.com/NXP/flexbuild/issues/11#issuecomment-2561862237

0 Kudos
Reply

689 Views
JasonFSYang
Contributor II

Dear Sirs,

I am having the same issue, any updates?

0 Kudos
Reply

587 Views
yoooh8668
Contributor III
From 9db918fa37e9448b4cb91dc8b5886166af297326 Mon Sep 17 00:00:00 2001
From: root <root@fbdebian.com>
Date: Fri, 17 Jan 2025 07:34:08 +0000
Subject: [PATCH] flexbuild: disable ml component

---
 configs/technexion.yml                | 2 +-
 src/apps/gopoint/imx_smart_fitness.mk | 2 +-
 tools/create_bootpartition            | 5 +++--
 3 files changed, 5 insertions(+), 4 deletions(-)

diff --git a/configs/technexion.yml b/configs/technexion.yml
index 625b99a..684ab09 100644
--- a/configs/technexion.yml
+++ b/configs/technexion.yml
@@ -26,7 +26,7 @@ PKG_GROUPS_NETWORKING: y
 PKG_GROUPS_CONNECTIVITY: y
 PKG_GROUPS_UTILS: y
 PKG_GROUPS_SECURITY: y
-PKG_GROUPS_ML: y
+PKG_GROUPS_ML: n
 PKG_GROUPS_GOPOINT: y
 PKG_GROUPS_ROBOTICS: n
 
diff --git a/src/apps/gopoint/imx_smart_fitness.mk b/src/apps/gopoint/imx_smart_fitness.mk
index ff57b8d..26fa46f 100644
--- a/src/apps/gopoint/imx_smart_fitness.mk
+++ b/src/apps/gopoint/imx_smart_fitness.mk
@@ -11,7 +11,7 @@ GPNT_APPS_FOLDER = /opt/gopoint-apps
 IMX_SMART_FITNESS_DIR = $(GPNT_APPS_FOLDER)/scripts/machine_learning/imx_smart_fitness
 
 imx_smart_fitness:
-	@[ $(SOCFAMILY) != IMX -o $(DISTROVARIANT) != desktop ] && exit || \
+	@[ $(SOCFAMILY) != IMX -o $(DISTROVARIANT) != desktop -o ${PKG_GROUPS_ML} != y ] && exit || \
 	 $(call fbprint_b,"imx_smart_fitness") && \
 	 $(call repo-mngr,fetch,imx_smart_fitness,apps/gopoint) && \
 	 if [ ! -f $(DESTDIR)/usr/lib/gstreamer-1.0/libnnstreamer.so ]; then \
diff --git a/tools/create_bootpartition b/tools/create_bootpartition
index 0c9e758..92cca87 100644
--- a/tools/create_bootpartition
+++ b/tools/create_bootpartition
@@ -50,7 +50,7 @@ generate_bootpartition_tarball() {
 	[ ! -d $FBOUTDIR/bsp/imx_firmware/lib/firmware/imx/dsp ] && bld imx_dsp -a $DESTARCH -p $SOCFAMILY
 	[ ! -d $FBOUTDIR/bsp/imx_firmware/lib/firmware/imx/easrc ] && bld imx_firmware -a $DESTARCH -p $SOCFAMILY
 	[ ! -d $FBOUTDIR/bsp/imx_mcore_demos/imx93-m33-demo ] && bld mcore_demo -a $DESTARCH -p $SOCFAMILY
-	[ ! -d $DESTDIR/usr/lib/ethosu_firmware ] && bld ethosu_firmware -a $DESTARCH -p $SOCFAMILY
+	[ ! -d $DESTDIR/usr/lib/ethosu_firmware ] && [ "$PKG_GROUPS_ML" = y ] && bld ethosu_firmware -a $DESTARCH -p $SOCFAMILY
 
 	cp -Prf $FBOUTDIR/bsp/imx_firmware/lib/firmware/* $bootpartdir/firmware
     fi
@@ -129,7 +129,8 @@ generate_bootpartition_tarball() {
                 dtb=${brd}*.dtb*
             fi
             ( echo $brd | grep -qE "imx93" ) && \
-                cp -Prf $FBOUTDIR/bsp/imx_mcore_demos/imx93-m33-demo/imx93-*m33*.elf $DESTDIR/usr/lib/ethosu_firmware $bootpartdir/firmware
+                cp -Prf $FBOUTDIR/bsp/imx_mcore_demos/imx93-m33-demo/imx93-*m33*.elf $bootpartdir/firmware && \
+		[ "$PKG_GROUPS_ML" = y ] && cp -Prf $DESTDIR/usr/lib/ethosu_firmware $bootpartdir/firmware
             ls $FBOUTDIR/bsp/u-boot/$socseries*/${brd}*_boot.scr | xargs -I {} cp -v {} $bootpartdir
             cp -f $FBOUTDIR/linux/kernel/$DESTARCH/$SOCFAMILY/${dtb} $bootpartdir
             boottarball=${bootpartname}_${brd}_lts_${kernelver}${imaevmopt}_${timestamp}
-- 
2.39.5

 

This patch disable ML, you can try to apply it.

0 Kudos
Reply

677 Views
Zhiming_Liu
NXP TechSupport
NXP TechSupport

Hi @JasonFSYang 

Please refer this reply:

Zhiming_Liu_0-1737355099734.png

 

0 Kudos
Reply

967 Views
Zhiming_Liu
NXP TechSupport
NXP TechSupport

Hi all @yoooh8668 @charleshuang @Edward_desplaines 

This could be a BUG as I can see same error about Could NOT find CLANG_FORMAT based on Ubuntu22.04(VMware virtual machine).

Have shared this issue with maintainer.

Best Regards,
Zhiming

0 Kudos
Reply

933 Views
Zhiming_Liu
NXP TechSupport
NXP TechSupport

Hello all @yoooh8668  @charleshuang  @Edward_desplaines 

Temporary solution:

1. Keep PKG_GROUPS_ML: y in sdk.yml

2. Comment these packages in ml.yml

Zhiming_Liu_0-1736842265765.png

3. Delete the .mk file about these packages.

 

The flexbuild will be updated after fixing this tflite issue.

 

Update: Gopoint also need to be removed. Any package has Tensorflow dependency should be removed

Best Regards,
Zhiming

0 Kudos
Reply

1,050 Views
charleshuang
Senior Contributor II

Hi all  and @Zhiming_Liu 

I still have the issue about host PC Ubuntu 22.04.

We tried using an Azure VM and follow the NXP SOP.

If possible, do you have sop that compiler it without ml.

 

0 Kudos
Reply

1,213 Views
yoooh8668
Contributor III

Hi,

I know:

For imx93:

tflite_ethosu_delegate.mk

 For imx8M:

tflite_vx_delegate.mk

But both of them build failed and require StringRef.

 

For each target in apps/ml:

sudo apt-get install python3-pybind11 protobuf-compiler


(pass)|-- eiq_examples.mk
(pass)|-- ethosu_driver_stack.mk
(pass)|-- ethosu_firmware.mk
(pass)|-- ethosu_vela.mk
(pass)|-- flatbuffers.mk
(pass)|-- nnshark.mk
(pass)|-- nnstreamer.mk
(pass)|-- nnstreamer_edge.mk
(CONFIG_PYTORCH not define)|-- pytorch.mk
(pass)|-- ssat.mk
(pass)|-- tflite.mk
(NG)|-- tflite_ethosu_delegate.mk
(NG)|-- tflite_vx_delegate.mk => NG
(pass)|-- tim_vx.mk
(pass)`-- tvm.mktflite_ethosu_delegate

 THANKS~~

Joe

0 Kudos
Reply

1,184 Views
Zhiming_Liu
NXP TechSupport
NXP TechSupport

Hello,

We built it from debian docker with ML feature, there is no such issue when in our serveal tests.

You can try to delete the docker container and delete the rootfs build folder in flexbuild as the tflite_ethosu_delegate relies on the debian12 rootfs(not debian docker rootfs).

Best Regards,
Zhiming

0 Kudos
Reply

1,165 Views
yoooh8668
Contributor III

Hi,

Does there any specific environment requirement?

On host of 20.04LTS(v5.4 kernel), it will failed on nnstreamer, and 22.04LTS (v6.8) won't.

Both of them use the same docker image, and run the same command.

Why them got different result?

What's your host environment?

THANKS~~

Joe

0 Kudos
Reply

1,162 Views
Zhiming_Liu
NXP TechSupport
NXP TechSupport

Hello,

The host environment is Ubuntu22.04 on our side. Referring the makefile of tflite_ethosu_delegate, the building should use python environment in container. But from the information you provided, it looks like relate to host python environment.. I need check this with maintainer. Please use Ubunut22.04 as host environment.


Best Regards,
Zhiming

0 Kudos
Reply

1,080 Views
yoooh8668
Contributor III

Hi,

Tested host environment: 18.04, 20.04, 22.04(x2).

Unfortunately, the only one who can build tflite_ethosu/vx_delegate is Ubuntu 18.04LTS...

All of the need to patch nnstreamer (expect one of the 22.04 computer).

Seems the build env is not isolated with host...

Still don't know what cause this happen.

 

And except for the 18.04LTS host, we need to disable the NPU makefile to complete the build...

 

THANKS~~

Joe

0 Kudos
Reply

1,015 Views
Zhiming_Liu
NXP TechSupport
NXP TechSupport

Hello,

Seems the build env is not isolated with host...
--->Yes, from your tests, it looks like the containers still rely on the host environment. This is very strange. Let me try to test under different WSL Ubuntu version.

 

@Edward_desplaines @yoooh8668 @charleshuang 

To remove the ML feature,  set the PKG_GROUPS_ML:n here https://github.com/NXP/flexbuild/blob/LSDK-24.12_DEBIAN-12_LF-6.6.36/configs/sdk.yml



Best Regards,
Zhiming

0 Kudos
Reply

995 Views
charleshuang
Senior Contributor II

Hi @Zhiming_Liu 

Follow your suggest : set the PKG_GROUPS_ML:n

We still can not compiler to success.

Building isp_vvcam_module ...
isp_vvcam_module [Done]
linux-modules [Done]
Installing kernel and dtb ...
Installing kernel modules ...
SOCFAMILY: IMX

Building sof_zephyr ...
sof_zephyr [Done]
SOCFAMILY: IMX
make: *** No rule to make target 'ethosu_firmware'. Stop.
[root@fbdebian flexbuild]$

0 Kudos
Reply

278 Views
lvasa3091
Contributor I

Hello! I did it - PKG_GROUPS_ML:n, delete the build_lsdk2412 folder. But the result - "make: *** No rule to make target 'ethosu_firmware'. Stop."

0 Kudos
Reply

267 Views
yoooh8668
Contributor III
0 Kudos
Reply

977 Views
Zhiming_Liu
NXP TechSupport
NXP TechSupport

Hello @charleshuang 

Please try to delete the build_lsdk2412 folder and try to rebuild it again.

Best Regards,
Zhiming

0 Kudos
Reply

1,065 Views
Edward_desplaines
Contributor I
Is there a way to remove the ml component dependency to build a minimal image? Most people probably don't need tensor flow. Those who do, can add it later.
0 Kudos
Reply