1. Download the source code:
Http://valgrind.org/downloads/valgrind-3.9.0.tar.bz2 2. Add compression: mkdir swcd swtar zxf valgrind-3.9.0.tar.bz2 3. Modify code: CD Valgrind-3.9.0/vim COREGRIND/M_DEBUGINFO/READSTABS.C line 57th: Comment off//#include <-a.out.h> then add: struct Nlist { union { char *n_name; struct nlist*n_next; long n_strx; } n_un; unsigned char N_type; char n_other; Short n_desc; unsigned long N_value;}; Solve Valgrind compile-time dependent on some column a.out.h header file problem, the above code is from the system:/usr/include/a.out.h file, the nlist structure is copied over. 4. Start compiling: Export path=: $PATH./configure \ --prefix=/home/nianzhong/sw/install_vg\ --host= Mipsel-linux \ --build=i686-linux \ cppflags=-i make make install 5. Deployment run: Copy the install_vg/to the nfs/directory. Into the embedded system, the NFS directory in the Mount server to the embedded system: MOUNT-T nfs-o vers=2,nolock/mnt/nfs/export valgrind_lib=/mnt/nfs/install_vg/lib/ Valgrind/mnt/nfs/install_vg/bin/valgrindLs-l export Valgrind_lib To resolve error: valgrind:failed to start tool ' Memcheck ' for Platform:nosuch file or directory
Compiling Valgrind arm cross-compilation