| View previous topic :: View next topic |
| Author |
Message |
Bart
Joined: 20 Oct 2009 Posts: 4
|
Posted: Tue Oct 20, 2009 3:09 am Post subject: GDB failed with unknown target |
|
|
Running Netbeans 6.7.1 with Cygwin on Windows XP2.
When trying to debug an OpenCV program that is statically linked to the OpenCV libraries I get 'GDB failed with an "unknown target exception" error'. The program compiles and runs fine, but will not debug. If I comment out the statement that uses the OpenCV library function, then the debugging works fine (but not the program).
My guess is that the debugger is trying to find the OpenCV library built in debug mode, but it is not available. Is this this problem then how do I tell the debugger to ignore this library?
A web search on the error finds a number of people with the same error message, but no solution. |
|
| Back to top |
|
 |
Bart
Joined: 20 Oct 2009 Posts: 4
|
Posted: Sat Oct 24, 2009 4:12 am Post subject: |
|
|
This was not really an OpenCV problem, I found I had the same problem with a very simple source program and a simple one-function external library.
Instead of Cygwin I tried Mingw and then finally TDM-Mingw. This allowed me to compile the Cmake make files in OpenCV and solved my simple test program compiling and debugging problems as well.
I still have a problem linking to .dll's using the project properties/linker page to specify .dll's. I set the Runtime Search Directories field and listed the .dll's in the Libraries dialogue. It compiles fine but I get the following when trying to run the program ...
RUN FAILED (exit value -1,073,741,515, total time: 312ms)
My temporary solution is to copy the .dll's to the same directory as the executable. If anyone has some advice how to use the linker properties page in Netbeans with C++ it would be much appreciated. |
|
| Back to top |
|
 |
Bart
Joined: 20 Oct 2009 Posts: 4
|
Posted: Sat Oct 24, 2009 4:43 am Post subject: |
|
|
More information ...
The compiled executable runs fine from a Windows command prompt, including dynamically linking to the OpenCV dll's in an OpenCV subdirectory.
The program will not run from Netbeans/TDM-Mingw Run or Debug without throwing up the previously mentioned runtime error. |
|
| Back to top |
|
 |
Bart
Joined: 20 Oct 2009 Posts: 4
|
Posted: Sat Oct 24, 2009 6:09 am Post subject: |
|
|
Putting "C:\OpenCV2\bin" in the system path command (advanced tab on My Computer) seem to do the trick. This is where the DLL's sit. I was under the mis-impression that setting the Linker properties Runtime Search Directories would do the same thing.
Pretty simple once you figure it out. |
|
| Back to top |
|
 |
Egor Ushakov Posted via mailing list.
|
Posted: Mon Oct 26, 2009 11:06 am Post subject: GDB failed with unknown target |
|
|
This is interesting how libs were found during run if you did not have
C:\OpenCV2\bin in path?
Egor
Bart wrote:
| Quote: | Putting "C:\OpenCV2\bin" in the system path command (advanced tab on My Computer) seem to do the trick. This is where the DLL's sit. I was under the mis-impression that setting the Linker properties Runtime Search Directories would do the same thing.
Pretty simple once you figure it out.
|
|
|
| Back to top |
|
 |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum You can attach files in this forum You can download files in this forum
|
|
|
|