Hello ArmNN experts,I'm currently facing an issue at runtime when using a statically built ArmNN lib.
I have been able to build a STATIC version of libarmnn with all dependancies and then build my own app for a Wandboard target (armv7).At runtime I got this error: "ERROR: None of the preferred backends [CpuRef ] are supported. Current platform provides "
When I compile SHARED libraries (*.so) the exact same app is running fine, and the inference is done as expected.
ArmNN version: 21.02Model/Target: TFLite on armv7Build options: cmake .. -DCMAKE_LINKER=/usr/bin/arm-linux-gnueabihf-ld -DCMAKE_C_COMPILER=/usr/bin/arm-linux-gnueabihf-gcc -DCMAKE_CXX_COMPILER=/usr/bin/arm-linux-gnueabihf-g++ -DCMAKE_BUILD_TYPE=Release -DCMAKE_CXX_STANDARD=14 -DCMAKE_CXX_FLAGS=-mfpu=neon -DARMCOMPUTE_ROOT=$BASEDIR/ComputeLibrary -DARMCOMPUTE_BUILD_DIR=$BASEDIR/ComputeLibrary/build -DBOOST_ROOT=$BASEDIR/boost_1_64_0 -DTF_GENERATED_SOURCES=$BASEDIR/tensorflow-protobuf -DBUILD_TF_PARSER=0 -DBUILD_ONNX_PARSER=0 -DONNX_GENERATED_SOURCES=$BASEDIR/onnx -DBUILD_TF_LITE_PARSER=1 -DTF_LITE_GENERATED_PATH=$BASEDIR/tflite -DFLATBUFFERS_ROOT=$BASEDIR/flatbuffers-arm32 -DFLATC_DIR=$BASEDIR/flatbuffers/build -DPROTOBUF_ROOT=$BASEDIR/protobuf-arm -DARMCOMPUTENEON=1 -DARMNNREF=1
Does anyone have an idea of a fix or additionnal investigations ??Thanks!!
When you run CMake, do you see any messages like "Including backend into the build: ..."?
I see you explicitly set -DARMNNREF=1, so it should be included into the build, but for some reason is treated as unsupported at runtime.
when running CMake I have something like what you said:
-- Including backend common library into the build: /home/projects/armnn-pi/armnn/src/backends/aclCommon/common.cmake-- Including backend common library into the build: /home/projects/armnn-pi/armnn/src/backends/backendsCommon/common.cmake-- Including backend into the build: /home/projects/armnn-pi/armnn/src/backends/cl/backend.cmake-- CL backend is disabled-- Including backend into the build: /home/projects/armnn-pi/armnn/src/backends/neon/backend.cmake-- Including backend into the build: /home/projects/armnn-pi/armnn/src/backends/reference/backend.cmake
Thanks for you help!