title: How to build Valgrind for ARMv5 platforms?
body: <p>I need to debug a multi-threaded program which keeps throwing horrible segmentation faults, and I chose <strong>Valgrind</strong> to do so. The problem, though, is that the code is cross-compiled and run in an ARMv5 machine. I tried to build Valgrind for that architecture, but <code>configure</code> failed because that version is not supported:</p>
  
  <pre><code>$ CC=arm-linux-gnueabi-gcc  ./configure --prefix=/opt/valgrind     \
    --host=armv5-none-linux-gnueabi --target=arm-none-linux-gnueabi  \
    --build=i386-ubuntu-linux
  
  (...)
  checking for a supported CPU... no (armv5)
  configure: error: Unsupported host architecture. Sorry
  </code></pre>
  
  <p>Is there a way to solve this issue? Could it be somehow possible to compile for ARMv7 (which I read is fully supported), and use it in my platform? I found <a href="https://stackoverflow.com/questions/13853124/compile-valgrind-for-armv5">this question</a>, but it was asked two years ago and the answer points to a patch for older versions of Valgrind.</p>