Problem building Opencv with IPP and TBB using Mingw32

asked 2015-08-18 04:21:57 -0500

updated 2015-08-18 04:26:51 -0500

Hello,

I got following error after setting cmake -DWITH_IPP=OFF and -DWITH_TBB=ON.

[ 32%] Building CXX object modules/core/CMakeFiles/opencv_core.dir/src/system.cp p.obj C:\opencv\sources\modules\core\src\system.cpp: In function 'BOOL cv::DllMain(HIN STANCE, DWORD, LPVOID)': C:\opencv\sources\modules\core\src\system.cpp:918:13: warning: no previous decla ration for 'BOOL cv::DllMain(HINSTANCE, DWORD, LPVOID)' [-Wmissing-declarations]

BOOL WINAPI DllMain(HINSTANCE, DWORD fdwReason, LPVOID lpReserved) ^ [ 32%] Building CXX object modules/core/CMakeFiles/opencv_core.dir/src/tables.cp p.obj [ 32%] Building CXX object modules/core/CMakeFiles/opencv_core.dir/src/types.cpp .obj [ 32%] Building CXX object modules/core/CMakeFiles/opencv_core.dir/src/umatrix.c pp.obj [ 33%] Building CXX object modules/core/CMakeFiles/opencv_core.dir/opencl_kernel s_core.cpp.obj Linking CXX shared library ....\bin\libopencv_core300.dll CMakeFiles\opencv_core.dir/objects.a(parallel.cpp.obj):parallel.cpp:(.text$_ZN3t bb10interface78internal9start_forINS_13blocked_rangeIiEEN12_GLOBAL__N_113ProxyLo opBodyEKNS_16auto_partitionerEED2Ev+0x2): undefined reference to vtable for tbb ::task' CMakeFiles\opencv_core.dir/objects.a(parallel.cpp.obj):parallel.cpp:(.text$_ZN3t bb10interface78internal9flag_taskD1Ev[__ZN3tbb10interface78internal9flag_taskD1E v]+0x2): undefined reference tovtable for tbb::task' c:/mingw/bin/../lib/gcc/mingw32/4.8.1/../../../../mingw32/bin/ld.exe: CMakeFiles \opencv_core.dir/objects.a(parallel.cpp.obj): bad reloc address 0x2 in section ` .text$_ZN3tbb10interface78internal9flag_taskD1Ev[__ZN3tbb10interface78internal9f lag_taskD1Ev]' collect2.exe: error: ld returned 1 exit status modules\core\CMakeFiles\opencv_core.dir\build.make:1233: recipe for target 'bin/ libopencv_core300.dll' failed mingw32-make[2]: * [bin/libopencv_core300.dll] Error 1 CMakeFiles\Makefile2:1325: recipe for target 'modules/core/CMakeFiles/opencv_cor e.dir/all' failed mingw32-make[1]: [modules/core/CMakeFiles/opencv_core.dir/all] Error 2 Makefile:136: recipe for target 'all' failed mingw32-make: ** [all] Error 2

Thank you

edit retag flag offensive close merge delete

Comments

1

might even be, that this is not related to mingw, but to opencv's current build scripts : https://github.com/Itseez/opencv/issu...

berak gravatar imageberak ( 2015-08-18 04:38:09 -0500 )edit

Hi,

Thanks, I have tried that fix given on github but, while configuring opencv with cmake I got following error.

Configuring incomplete, errors occurred! See also "C:/opencv/mybuild/CMakeFiles/CMakeOutput.log". See also "C:/opencv/mybuild/CMakeFiles/CMakeError.log". (https://github.com/kachhadiyatushar/O...) you can find those two file and its log from here.

Thanks

Tushar Kachhadiya gravatar imageTushar Kachhadiya ( 2015-08-18 05:24:10 -0500 )edit