0

I am trying to run a c++ project in eclipse with valgrind leak check. I can't see the output of valgrind in eclipse console, therefore I can't know if I have leaks or not.

I added in run configurations --> arguments the following:
valgrind --leak-check=yes

Do I need to add anything? Is there a different reason that might cause this?

Thank you


EDIT:
The problem is with Valgrind not running on Windows. I used to work in Linux environment and didn't know Windows doesn't work with Valgrind in the same way.

So rephrasing my question:

I am using Eclipse Luna on Windows 8 64bit.

I have looked through some other posts but so far nothing has been working:

1. I tried to get the Visual Leak Detector, but I couldn't debug because of gdb problems (I installed it using apt-get command).
I tried to:
A. set the location of my gdb, like here Eclipse CDT cannot debug using gdb on Mac but couldn't understand it's location in windows (find . -name returned no interesting results).
B. Also I tried to set the Source Lookup Path as mentioned here How to get gdb working with Eclipse CDT under windows (fails to find source code) , but it did not work as well.
C. Also I tried to reinstall cygwin and select the gdb package, but it was N/A (or I at least couldn't understand how to select it).

2. I tried this from Free Application to check Memory Leaks in Windows x64?

#define _CRTDBG_MAP_ALLOC
#include
#include

Add the following right before the program's exit point(s):

_CrtDumpMemoryLeaks();

It doesn't work as well.

I will try and get the other tools in other posts when I have the time, but if anyone has a solution for why what I have tried so far didn't work - I'll be happy to know.

Community
  • 1
  • 1
Achi Even-dar
  • 427
  • 1
  • 10
  • 20

1 Answers1

1

Have you tried installing the plugin?

Try out this link: http://wiki.eclipse.org/Linux_Tools_Project/PluginInstallHelp

Asaf Shveki
  • 736
  • 8
  • 11