diff mbox series

[meta-arago,master,1/1] tensorflow-lite: fix undefined Abseil logging symbols in shared library

Message ID 20260312141948.1002945-2-p-deshmukh@ti.com
State Under Review
Delegated to: Ryan Eatmon
Headers show
Series Fix TensorFlow Lite GStreamer pipeline failures | expand

Commit Message

Pratham Deshmukh March 12, 2026, 2:19 p.m. UTC
Add patch to resolve GStreamer pipeline failures when using TensorFlow Lite
object detection models. The tensorflow2-lite NNStreamer plugin was failing
to load due to missing Abseil logging symbols (_ZN4absl12lts_2025012712
log_internal9kCharNullE, _ZN4absl12lts_2025012712log_internal10LogMessage
C1EPKciNS2_8ErrorTagE) in the libtensorflow-lite.so.2 shared library.

The fix adds missing Abseil logging targets to the CMake build system and
links required logging libraries (log_internal_nullguard, log_internal_message,
log_severity, raw_logging_internal) to ensure all symbols are available at
runtime.

Added Patch:
  - 0003-Fix-GStreamer-TensorFlow-Lite-pipeline-failures-due-.patch 

Signed-off-by: Pratham Deshmukh <p-deshmukh@ti.com>
---
 ...nsorFlow-Lite-pipeline-failures-due-.patch | 62 +++++++++++++++++++
 .../tensorflow-lite/tensorflow-lite_2.20.0.bb |  1 +
 2 files changed, 63 insertions(+)
 create mode 100644 meta-arago-extras/recipes-framework/tensorflow-lite/tensorflow-lite/0003-Fix-GStreamer-TensorFlow-Lite-pipeline-failures-due-.patch

Comments

Andrew Davis March 12, 2026, 2:36 p.m. UTC | #1
On 3/12/26 9:19 AM, Pratham Deshmukh wrote:
> Add patch to resolve GStreamer pipeline failures when using TensorFlow Lite
> object detection models. The tensorflow2-lite NNStreamer plugin was failing
> to load due to missing Abseil logging symbols (_ZN4absl12lts_2025012712
> log_internal9kCharNullE, _ZN4absl12lts_2025012712log_internal10LogMessage
> C1EPKciNS2_8ErrorTagE) in the libtensorflow-lite.so.2 shared library.
> 

You could demangle these symbols[0] to make them more readable here, or just
not list them at all, the exact symbols that where missing can be seen in
the patch itself.

Andrew

[0] https://www.demangler.com/

> The fix adds missing Abseil logging targets to the CMake build system and
> links required logging libraries (log_internal_nullguard, log_internal_message,
> log_severity, raw_logging_internal) to ensure all symbols are available at
> runtime.
> 
> Added Patch:
>    - 0003-Fix-GStreamer-TensorFlow-Lite-pipeline-failures-due-.patch
> 
> Signed-off-by: Pratham Deshmukh <p-deshmukh@ti.com>
> ---
>   ...nsorFlow-Lite-pipeline-failures-due-.patch | 62 +++++++++++++++++++
>   .../tensorflow-lite/tensorflow-lite_2.20.0.bb |  1 +
>   2 files changed, 63 insertions(+)
>   create mode 100644 meta-arago-extras/recipes-framework/tensorflow-lite/tensorflow-lite/0003-Fix-GStreamer-TensorFlow-Lite-pipeline-failures-due-.patch
> 
> diff --git a/meta-arago-extras/recipes-framework/tensorflow-lite/tensorflow-lite/0003-Fix-GStreamer-TensorFlow-Lite-pipeline-failures-due-.patch b/meta-arago-extras/recipes-framework/tensorflow-lite/tensorflow-lite/0003-Fix-GStreamer-TensorFlow-Lite-pipeline-failures-due-.patch
> new file mode 100644
> index 00000000..f286018f
> --- /dev/null
> +++ b/meta-arago-extras/recipes-framework/tensorflow-lite/tensorflow-lite/0003-Fix-GStreamer-TensorFlow-Lite-pipeline-failures-due-.patch
> @@ -0,0 +1,62 @@
> +From 0e6c2c6d0911897e38f54dd0739e13ea15ccedd8 Mon Sep 17 00:00:00 2001
> +From: Pratham Deshmukh <p-deshmukh@ti.com>
> +Date: Thu, 12 Mar 2026 16:50:33 +0530
> +Subject: [PATCH] Fix GStreamer TensorFlow Lite pipeline failures due to
> + missing Abseil logging symbols
> +
> +When running GStreamer pipelines with TensorFlow Lite object detection [0]
> +
> +The pipeline failed with undefined symbol errors:
> +  undefined symbol: _ZN4absl12lts_2025012712log_internal9kCharNullE
> +  undefined symbol: _ZN4absl12lts_2025012712log_internal10LogMessageC1EPKciNS2_8ErrorTagE
> +
> +TensorFlow Lite shared library was missing Abseil logging
> +components that are required at runtime but weren't being linked during build.
> +
> +Add missing Abseil logging targets (log_internal_message, log_internal_nullguard)
> +to the Findabsl.cmake module and link the required Abseil logging libraries in the
> +tensorflow-lite target, including absl::log_internal_nullguard for the kCharNull
> +symbol, absl::log_internal_message for the LogMessage constructor, and absl::log_severity
> +and absl::raw_logging_internal for base logging support.
> +
> +[0] https://texasinstruments.github.io/processor-sdk-doc/processor-sdk-linux-AM62X/esd/docs/master/linux/Foundational_Components/Machine_Learning/tflite.html#example-applications
> +
> +Upstream-Status: Pending
> +
> +Signed-off-by: Pratham Deshmukh <p-deshmukh@ti.com>
> +---
> + tensorflow/lite/CMakeLists.txt                     | 4 ++++
> + tensorflow/lite/tools/cmake/modules/Findabsl.cmake | 2 ++
> + 2 files changed, 6 insertions(+)
> +
> +diff --git a/tensorflow/lite/CMakeLists.txt b/tensorflow/lite/CMakeLists.txt
> +index 7e0004ef..8c43fdac 100644
> +--- a/tensorflow/lite/CMakeLists.txt
> ++++ b/tensorflow/lite/CMakeLists.txt
> +@@ -732,6 +732,10 @@ target_link_libraries(tensorflow-lite
> +     absl::strings
> +     absl::synchronization
> +     absl::variant
> ++    absl::log_internal_nullguard
> ++    absl::log_severity
> ++    absl::raw_logging_internal
> ++    absl::log_internal_message
> +     farmhash
> +     fft2d_fftsg2d
> +     flatbuffers::flatbuffers
> +diff --git a/tensorflow/lite/tools/cmake/modules/Findabsl.cmake b/tensorflow/lite/tools/cmake/modules/Findabsl.cmake
> +index 75041749..685b851b 100644
> +--- a/tensorflow/lite/tools/cmake/modules/Findabsl.cmake
> ++++ b/tensorflow/lite/tools/cmake/modules/Findabsl.cmake
> +@@ -99,6 +99,8 @@ if(abseil-cpp_POPULATED)
> +     leak_check_api_enabled_for_testing
> +     leak_check_disable
> +     log_severity
> ++    log_internal_message
> ++    log_internal_nullguard
> +     main_lib
> +     malloc_internal
> +     memory
> +--
> +2.34.1
> +
> diff --git a/meta-arago-extras/recipes-framework/tensorflow-lite/tensorflow-lite_2.20.0.bb b/meta-arago-extras/recipes-framework/tensorflow-lite/tensorflow-lite_2.20.0.bb
> index 43562303..ee445e75 100644
> --- a/meta-arago-extras/recipes-framework/tensorflow-lite/tensorflow-lite_2.20.0.bb
> +++ b/meta-arago-extras/recipes-framework/tensorflow-lite/tensorflow-lite_2.20.0.bb
> @@ -16,6 +16,7 @@ SRC_URI = " \
>       git://github.com/tensorflow/tensorflow.git;protocol=https;branch=r2.20 \
>       file://0001-Update-CMakeLists-for-building.patch \
>       file://0002-Update-CMakeLists-for-building-shared-object.patch \
> +    file://0003-Fix-GStreamer-TensorFlow-Lite-pipeline-failures-due-.patch \
>       file://tensorflow2-lite.pc.in \
>   "
>
diff mbox series

Patch

diff --git a/meta-arago-extras/recipes-framework/tensorflow-lite/tensorflow-lite/0003-Fix-GStreamer-TensorFlow-Lite-pipeline-failures-due-.patch b/meta-arago-extras/recipes-framework/tensorflow-lite/tensorflow-lite/0003-Fix-GStreamer-TensorFlow-Lite-pipeline-failures-due-.patch
new file mode 100644
index 00000000..f286018f
--- /dev/null
+++ b/meta-arago-extras/recipes-framework/tensorflow-lite/tensorflow-lite/0003-Fix-GStreamer-TensorFlow-Lite-pipeline-failures-due-.patch
@@ -0,0 +1,62 @@ 
+From 0e6c2c6d0911897e38f54dd0739e13ea15ccedd8 Mon Sep 17 00:00:00 2001
+From: Pratham Deshmukh <p-deshmukh@ti.com>
+Date: Thu, 12 Mar 2026 16:50:33 +0530
+Subject: [PATCH] Fix GStreamer TensorFlow Lite pipeline failures due to
+ missing Abseil logging symbols
+
+When running GStreamer pipelines with TensorFlow Lite object detection [0]
+
+The pipeline failed with undefined symbol errors:
+  undefined symbol: _ZN4absl12lts_2025012712log_internal9kCharNullE
+  undefined symbol: _ZN4absl12lts_2025012712log_internal10LogMessageC1EPKciNS2_8ErrorTagE
+
+TensorFlow Lite shared library was missing Abseil logging
+components that are required at runtime but weren't being linked during build.
+
+Add missing Abseil logging targets (log_internal_message, log_internal_nullguard)
+to the Findabsl.cmake module and link the required Abseil logging libraries in the
+tensorflow-lite target, including absl::log_internal_nullguard for the kCharNull
+symbol, absl::log_internal_message for the LogMessage constructor, and absl::log_severity
+and absl::raw_logging_internal for base logging support.
+
+[0] https://texasinstruments.github.io/processor-sdk-doc/processor-sdk-linux-AM62X/esd/docs/master/linux/Foundational_Components/Machine_Learning/tflite.html#example-applications
+
+Upstream-Status: Pending
+
+Signed-off-by: Pratham Deshmukh <p-deshmukh@ti.com>
+---
+ tensorflow/lite/CMakeLists.txt                     | 4 ++++
+ tensorflow/lite/tools/cmake/modules/Findabsl.cmake | 2 ++
+ 2 files changed, 6 insertions(+)
+
+diff --git a/tensorflow/lite/CMakeLists.txt b/tensorflow/lite/CMakeLists.txt
+index 7e0004ef..8c43fdac 100644
+--- a/tensorflow/lite/CMakeLists.txt
++++ b/tensorflow/lite/CMakeLists.txt
+@@ -732,6 +732,10 @@ target_link_libraries(tensorflow-lite
+     absl::strings
+     absl::synchronization
+     absl::variant
++    absl::log_internal_nullguard
++    absl::log_severity
++    absl::raw_logging_internal
++    absl::log_internal_message
+     farmhash
+     fft2d_fftsg2d
+     flatbuffers::flatbuffers
+diff --git a/tensorflow/lite/tools/cmake/modules/Findabsl.cmake b/tensorflow/lite/tools/cmake/modules/Findabsl.cmake
+index 75041749..685b851b 100644
+--- a/tensorflow/lite/tools/cmake/modules/Findabsl.cmake
++++ b/tensorflow/lite/tools/cmake/modules/Findabsl.cmake
+@@ -99,6 +99,8 @@ if(abseil-cpp_POPULATED)
+     leak_check_api_enabled_for_testing
+     leak_check_disable
+     log_severity
++    log_internal_message
++    log_internal_nullguard
+     main_lib
+     malloc_internal
+     memory
+-- 
+2.34.1
+
diff --git a/meta-arago-extras/recipes-framework/tensorflow-lite/tensorflow-lite_2.20.0.bb b/meta-arago-extras/recipes-framework/tensorflow-lite/tensorflow-lite_2.20.0.bb
index 43562303..ee445e75 100644
--- a/meta-arago-extras/recipes-framework/tensorflow-lite/tensorflow-lite_2.20.0.bb
+++ b/meta-arago-extras/recipes-framework/tensorflow-lite/tensorflow-lite_2.20.0.bb
@@ -16,6 +16,7 @@  SRC_URI = " \
     git://github.com/tensorflow/tensorflow.git;protocol=https;branch=r2.20 \
     file://0001-Update-CMakeLists-for-building.patch \
     file://0002-Update-CMakeLists-for-building-shared-object.patch \
+    file://0003-Fix-GStreamer-TensorFlow-Lite-pipeline-failures-due-.patch \
     file://tensorflow2-lite.pc.in \
 "