Skip to content
Advertisement

Valgrind does not work with WSL?

When I installed WSL for my computer I was very excited to have a more natively supported Linux system rather than using VirtualBox. However I get this error when I try to run it. Is there a reason why?

I am happy to give more information as required.

JavaScript

Advertisement

Answer

It’s definitely possible

I’ve encountered some problems installing it directly with apt, however it can be installed manually with some very simple steps:

  • Download the source file: wget http://valgrind.org/downloads/valgrind-3.12.0.tar.bz2 (by the time you read this there could be a newer version)
  • Extract the archive: tar -xvjf valgrind-3.12.0.tar.bz2
  • Configure the installation process: cd into the exctracted folder valgrind-3.12.0 and then launch ./configure
  • Make: simply launch make while in the valgrind-3.12.0 folder
  • Check the dependencies: launch make check to see whether all the dependencies necessary for the installation are satisfied (e.g: you’ll have to install g++, just launch sudo apt install g++)
  • Install valgrind: type sudo make install to install it
Advertisement