PDA

View Full Version : Linking openCV with qt



harvey_slash
17th December 2013, 03:22
I am using a static build of qt. I Just downloaded the latest version of openCV, and ran cmake ,mingw32-make, mingw32-install ,etc.
in the config file, I added the correct include paths, and also the libs I want(.dlls).
weird things are happenening:
first, if I run the project from Qtcentre, it runs fine, but the image doesn't load(the image is in the same folder as the build) , but if I run the exe from the build folder, it runs just fine.
I have two .dlls in the same folder, core.dll, and highgui.dll.
but when I give the file to my friend, it show a lot of dlls missing.

something like -6 .js-1 etc (I don't remember the names clearly)
what should I do to make my app (windows) distributable?

ChrisW67
17th December 2013, 04:11
first, if I run the project from Qtcentre, it runs fine, but the image doesn't load(the image is in the same folder as the build) , but if I run the exe from the build folder, it runs just fine.
Qt Creator? I'll give you a wild guess because there's nothing else for it. You are using a relative path to the image file and not accounting for the fact that the current working directory is not necessarily in the same place as the executable.

I have two .dlls in the same folder, core.dll, and highgui.dll.
Congratulations ;)

but when I give the file to my friend, it show a lot of dlls missing.
something like -6 .js-1 etc (I don't remember the names clearly)
what should I do to make my app (windows) distributable?
Well, you cannot fix the problem unless you actually have some information to go on. I suggest you find out the names clearly and work from there.

harvey_slash
17th December 2013, 07:49
okay, first error :
libgcc_s_sjlj-1.dll missing

libstdc++-6.dll missing
libgcc_s_dw2-1 missing

after I add all these dlls , I get


The procedure entry point -ZNSt8_setail15_List_node_base7_M_hookEPS0_ could not be located in the dynamic link library D:\Test\libopencv_highgui247.dll

amaiaman
24th January 2014, 17:12
Hello!

I have the same problem. I need using my application Qt + Opencv in other computer.
Can you help me, please?

I'm desperated!

ChrisW67
24th January 2014, 19:57
Do not cross post to ask the same question multiple times. Go here