Closed ducroq closed 1 month ago
this can be added as patch https://github.com/tensorflow/tensorflow/commit/9dbee4329ffd0474b939927f6d337959fb72318a
this can be added as patch tensorflow/tensorflow@9dbee43
Thank you. I have adapted the code in the cache .conan/p/b/tenso{$hash$}.
However, when I execute conan install . --build=missing
it simply ignores this and downloads the source again and puts in a different subfolder.
I was hoping to work around the issue by running the patch automatically, and added these methods to conanfile.py
:
def build(self):
apply_conandata_patches(self)
def export_sources(self):
export_conandata_patches(self)
And in my patches folder tensorflow-lite.patch
:
--- a/tensorflow/lite/kernels/internal/spectrogram.cc
+++ b/tensorflow/lite/kernels/internal/spectrogram.cc
@@ -17,6 +17,7 @@
#include "tensorflow/lite/kernels/internal/spectrogram.h"
#include <math.h>
+#include <cstdint>
#include <algorithm>
#include <complex>
But no luck, unfortunately.
@ducroq could you try the recent version added to conan-center? Run conan install . --build=missing --update
sorry, I've dropped conan for now.
Description
When attempting to build TensorFlow Lite 2.12.0 using Conan, the compilation fails due to 'uint32_t' not being declared in scope. The error suggests that the header is missing in the 'spectrogram.cc' file. This prevents the successful building of the package and integration into projects.
Expected behavior: TensorFlow Lite should compile successfully without any 'uint32_t' related errors. Actual behavior: Compilation fails due to 'uint32_t' not being declared. Workaround attempted: Manually adding '#include' to the file, but this change is overwritten on subsequent builds.
Package and Environment Details
Conan profile
Host profile: [settings] arch=x86_64 build_type=Release compiler=gcc compiler.cppstd=gnu17 compiler.libcxx=libstdc++11 compiler.version=13 os=Linux
Build profile: [settings] arch=x86_64 build_type=Release compiler=gcc compiler.cppstd=gnu17 compiler.libcxx=libstdc++11 compiler.version=13 os=Linux
Steps to reproduce
Logs
Click to expand log
``` [ 23%] Building CXX object CMakeFiles/tensorflow-lite.dir/kernels/activations.cc.o /home/jeroen/.conan2/p/b/tenso2afef9412b5fa/b/src/tensorflow/lite/kernels/internal/spectrogram.cc:46:22: error: 'uint32_t' was not declared in this scope 46 | inline int Log2Floor(uint32_t n) { | ^~~~~~~~ /home/jeroen/.conan2/p/b/tenso2afef9412b5fa/b/src/tensorflow/lite/kernels/internal/spectrogram.cc:20:1: note: 'uint32_t' is defined in header '