Hi all,
I'm trying to use ARM NN SDK with Cortex-A53 and NEON.
So referenced this link and did whole things(clone repo, build with aarch64 toolchain)
(https://developer.arm.com/technologies/machine-learning-on-arm/developer-material/how-to-guides/configuring-the-arm-nn-sdk-build-environment-for-tensorflow)
But I faced an build error when ARM NN SDK build.
This is my error log when did 'make' after cmake
[ 58%] Linking CXX shared library libarmnn.so /usr/bin/ld: /home/soongk/Workspace/common/ML/ComputeLibrary/build/libarm_compute_core-static.a(TensorInfo.o): Relocations in generic ELF (EM: 183) /usr/bin/ld: /home/soongk/Workspace/common/ML/ComputeLibrary/build/libarm_compute_core-static.a(TensorInfo.o): Relocations in generic ELF (EM: 183) /usr/bin/ld: /home/soongk/Workspace/common/ML/ComputeLibrary/build/libarm_compute_core-static.a(TensorInfo.o): Relocations in generic ELF (EM: 183) /usr/bin/ld: /home/soongk/Workspace/common/ML/ComputeLibrary/build/libarm_compute_core-static.a(TensorInfo.o): Relocations in generic ELF (EM: 183) /usr/bin/ld: /home/soongk/Workspace/common/ML/ComputeLibrary/build/libarm_compute_core-static.a(TensorInfo.o): Relocations in generic ELF (EM: 183) /usr/bin/ld: /home/soongk/Workspace/common/ML/ComputeLibrary/build/libarm_compute_core-static.a(TensorInfo.o): Relocations in generic ELF (EM: 183) /usr/bin/ld: /home/soongk/Workspace/common/ML/ComputeLibrary/build/libarm_compute_core-static.a(TensorInfo.o): Relocations in generic ELF (EM: 183) /usr/bin/ld: /home/soongk/Workspace/common/ML/ComputeLibrary/build/libarm_compute_core-static.a(TensorInfo.o): Relocations in generic ELF (EM: 183) /usr/bin/ld: /home/soongk/Workspace/common/ML/ComputeLibrary/build/libarm_compute_core-static.a(TensorInfo.o): Relocations in generic ELF (EM: 183) /usr/bin/ld: /home/soongk/Workspace/common/ML/ComputeLibrary/build/libarm_compute_core-static.a(TensorInfo.o): Relocations in generic ELF (EM: 183) /usr/bin/ld: /home/soongk/Workspace/common/ML/ComputeLibrary/build/libarm_compute_core-static.a(TensorInfo.o): Relocations in generic ELF (EM: 183) /home/soongk/Workspace/common/ML/ComputeLibrary/build/libarm_compute_core-static.a: error adding symbols: File in wrong format collect2: error: ld returned 1 exit status CMakeFiles/armnn.dir/build.make:3248: recipe for target 'libarmnn.so' failed make[2]: *** [libarmnn.so] Error 1 CMakeFiles/Makefile2:67: recipe for target 'CMakeFiles/armnn.dir/all' failed make[1]: *** [CMakeFiles/armnn.dir/all] Error 2 Makefile:127: recipe for target 'all' failed make: *** [all] Error 2 soongk:fserver12 build $
This error comes from libarmnn.so file link time with libarm_compute_core-static.a from ARM ComputeLibrary.
I tried with pre-built ComputeLibrary(https://github.com/ARM-software/ComputeLibrary/releases/download/v18.05/arm_compute-v18.05-bin-linux.tar.gz)
but it brings same error too.
How could I build ARM NN SDK?
Hi,
I will try the steps to compile Arm NN.
Are you native compiling on an Arm Linux machine?
If you are doing something else like cross compiling or using Android NDK please post more info on your environment.
Thanks,
Jason
I've completed compile ARM NN now. So this could be my question's self-answer.
I tried to use aarch64 linux kernel so I refered ARM_NN for tensorflow.(https://developer.arm.com/technologies/machine-learning-on-arm/developer-material/how-to-guides/configuring-the-arm-nn-sdk-build-environment-for-tensorflow)
But I confused which libs compile for aarch64 but solved after read build_howto_for_Android (https://github.com/ARM-software/armnn/blob/master/BuildGuideAndroidNDK.md) with some fixes; toolchain, build directory and etc.
It's better guide than prev one because it describes which one to be cross-compiled.
Now I solved my problem. Thank you :)
Good work, glad you got it figured out. The first guide definitely needs more information.