getting unresolved external symbols Visual Studio 2015

asked 2016-09-04 15:54:46 -0600

I'm tring to build a solution that uses openCV. I'm now down to 12 errors in the link stage. What library would have the cv::String::allocate, cv::String::deallocate, and cv::Mat::Mat. What additional libraries do I need to add to the list below to clean these last one up?

I'm using visual studio 2015 C++ with the following

opencv-2.4.13

Linker additional dependencies

opencv_core2413d.lib opencv_imgproc2413d.lib opencv_highgui2413d.lib opencv_ml2413d.lib opencv_video2413d.lib opencv_features2d2413d.lib opencv_calib3d2413d.lib opencv_objdetect2413d.lib opencv_contrib2413d.lib opencv_legacy2413d.lib opencv_flann2413d.lib

VC++ Directories, Library Directories C:\Darrah\openCV-2-4-13\opencv\build\x86\vc12

Severity Code Description Project File Line Suppression State Error LNK2019 unresolved external symbol "private: char * __thiscall cv::String::allocate(unsigned int)" (?allocate@String@cv@@AAEPADI@Z) referenced in function "public: __thiscall cv::String::String(char const *)" (??0String@cv@@QAE@PBD@Z) Pixmicro C:\Darrah\PCB\Pixmicro-master\Pixmicro\CaptureThread.obj

Severity Code Description Project File Line Suppression State Error LNK2019 unresolved external symbol "private: void __thiscall cv::String::deallocate(void)" (?deallocate@String@cv@@AAEXXZ) referenced in function "public: __thiscall cv::String::~String(void)" (??1String@cv@@QAE@XZ) Pixmicro C:\Darrah\PCB\Pixmicro-master\Pixmicro\CaptureThread.ob)

Severity Code Description Project File Line Suppression State Error LNK2019 unresolved external symbol "void __cdecl cv::error(int,class cv::String const &,char const *,char const *,int)" (?error@cv@@YAXHABVString@1@PBD1H@Z) referenced in function "public: __thiscall cv::Mat::Mat(class cv::Mat &&)" (??0Mat@cv@@QAE@$$QAV01@@Z) Pixmicro C:\Darrah\PCB\Pixmicro-master\Pixmicro\CaptureThread.obj 1

edit retag flag offensive close merge delete

Comments

do you actually have those libs ? the prebuild binary packages come with a single opencv_world2413.lib , which contains all other modules, just liink against that.

berak gravatar imageberak ( 2016-09-04 20:13:31 -0600 )edit

I looked and the release I have doesn't have openCV-world2413.lib. Instead the x86 library directory has 38 individual libraries. The software I'm trying to compile was written by someone else but his environment was 64-bit. on his blog he said he didn't have time to do the 32-bit version. Since he posted the code I decided to try. After a day or so I've added enough library and include references to get me down to 12 linking error mostly based on the three errors I put in my original post.

Jim Darrah gravatar imageJim Darrah ( 2016-09-04 20:45:02 -0600 )edit