Problem at compiling (libopencv_core300.dll not found) [closed]

asked 2015-06-22 16:54:54 -0500

Dr. Console gravatar image

updated 2015-06-23 14:51:33 -0500

Hey guys,

I'm just installing OpenCV for a project controling a SMD mounting machine but I'm not abled to comile the Project for usage with Code::Blocks with mingw.

I'm using this tutorial:

Everytime I'm running the command "mingw-make" it stops at 31% with following message:

[ 31%] Linking CXX shared library ....\bin\libopencv_core300.dll

c:/mingw/bin/../lib/gcc/mingw32/4.8.1/../../../../mingw32/bin/ld.exe: cannot fin d -lRunTmChk

collect2.exe: error: ld returned 1 exit status

modules\core\CMakeFiles\opencv_core.dir\build.make:1286: recipe for target 'bin/ libopencv_core300.dll' failed

mingw32-make[2]: * [bin/libopencv_core300.dll] Error 1

CMakeFiles\Makefile2:1654: 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:148: recipe for target 'all' failed

mingw32-make: * [all] Error 2

My Systems is WIN7 64bit and the newest versions of cmake, mingw, opencv and Code::Blocks

Hope someone can help me.

NG from Germany Dr. Console


Found a solution, it's a mingw bug... I needed to disable IPP and comment out the line 'add_extra_compiler_option(-Werror=non-virtual-dtor)' in C:opencv\sources\cmake\OpenCVCompilerOptions.cmake So the make command worked.

edit retag flag offensive reopen merge delete

Closed for the following reason the question is answered, right answer was accepted by Dr. Console
close date 2015-06-23 14:41:47.626055


blind guess: are youi trying with IPP ? you'll have to disable it: cmake -DWITH:_IPP=OFF

also see here

berak gravatar imageberak ( 2015-06-22 23:06:57 -0500 )edit

Well, yes i left everything as is in cmake. :D I never used cmake before so i thought i could do more damage than help... I'll try it now and report if it works.

Thanks already!

Dr. Console gravatar imageDr. Console ( 2015-06-23 12:50:09 -0500 )edit

Well now I get further than before but now getting this error: [ 37%] Building CXX object modules/videoio/CMakeFiles/opencv_videoio.dir/src/cap _dshow.cpp.obj C:\OpenCV\opencv\sources\modules\videoio\src\cap_dshow.cpp:122:11: error: 'struc t IEnumPIDMap' has virtual functions and accessible non-virtual destructor [-Wer ror=non-virtual-dtor] interface IEnumPIDMap : public IUnknown ^ C:\OpenCV\opencv\sources\modules\videoio\src\cap_dshow.cpp:139:11: error: 'struc t IMPEG2PIDMap' has virtual functions and accessible non-virtual destructor [-We rror=non-virtual-dtor] interface IMPEG2PIDMap : public IUnknown ^ C:\OpenCV\opencv\sources\modules\videoio\src\cap_dshow.cpp:227:11: error: 'struc t ISampleGrabberCB' has virtual functions and accessible non-virtual destructor [-

Dr. Console gravatar imageDr. Console ( 2015-06-23 12:57:34 -0500 )edit

oh, cool, that you highlighted the -Werror=non-virtual-dtor thing. that sure will be helpful for the next one trying to get opencv running with mingw ;9

berak gravatar imageberak ( 2015-06-23 14:45:25 -0500 )edit

Better? :D

Dr. Console gravatar imageDr. Console ( 2015-06-23 14:52:10 -0500 )edit