1

When I try to install opencv-3.0-alpha with python 2.7 to Raspberry pi 2. I got an error.

[ 24%] Building CXX object modules/core/CMakeFiles/opencv_core.dir/src/matmul.cpp.o [ 24%] Building CXX object modules/core/CMakeFiles/opencv_core.dir/opencl_kernels_core.cpp.o Linking CXX shared library ../../lib/libopencv_core.so /usr/bin/ld: ../../../3rdparty/ippicv/unpack/ippicv_lnx/lib/ia32/libippicv.a(ippinit.o): Relocations in generic ELF (EM: 3) ../../../3rdparty/ippicv/unpack/ippicv_lnx/lib/ia32/libippicv.a: error adding symbols: File in wrong format collect2: error: ld returned 1 exit status modules/core/CMakeFiles/opencv_core.dir/build.make:1213: recipe for target 'lib/libopencv_core.so.3.0.0' failed make[2]: * [lib/libopencv_core.so.3.0.0] Error 1 CMakeFiles/Makefile2:1392: recipe for target 'modules/core/CMakeFiles/opencv_core.dir/all' failed make[1]: * [modules/core/CMakeFiles/opencv_core.dir/all] Error 2 Makefile:137: recipe for target 'all' failed make: *** [all] Error 2

What should i do to solve this problem?

1

Bit of googling leads me to believe it might be related to compiling 32bit version of OpenCV on a 64 bit OS where it tries to link against a 64 bit library OR vice versa.

see this here and this has a solution that might work for you

0

Got this error when build static opencv, solve this by disabling IPP in cmake.

WITH_IPP=OFF

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.