[PATCH] build: Make valgrind tests append all output into a single log file
--- extratests/Makefile.am | 8 ++++++-- 1 files changed, 6 insertions(+), 2 deletions(-) diff --git a/extratests/Makefile.am b/extratests/Makefile.am index bf6b3f9..519d0b9 100644 --- a/extratests/Makefile.am +++ b/extratests/Makefile.am @@ -52,12 +52,16 @@ EXTRA_DIST = suppressions +VG_FIFO=$(abs_builddir)/valgrind.fifo +VG_LOG=$(abs_builddir)/valgrind.log VG = valgrind \ - --log-file=$(abs_builddir)/valgrind.log \ + --log-file=$(VG_FIFO) \ --leak-check=full \ --error-exitcode=119 \ --suppressions=$(abs_srcdir)/suppressions -RUN_VG = $(abs_top_builddir)/run $(VG) +RUN_VG = [ ! -p $(VG_FIFO) ] && mkfifo $(VG_FIFO); \ + ( cat $(VG_FIFO) >> $(VG_LOG)) & \ + $(abs_top_builddir)/run $(VG) export LIBVIRT_DEFAULT_URI = \ qemu+unix:///system?socket=/var/run/libvirt/libvirt-sock-ro -- 1.7.7.3
Looking at the man page, I think a better idea might be something like this (untested): VG = valgrind --log-fd=100 100>>valgrind.log [...] I guess we will also need .NOTPARALLEL: too. Alternatively, using the %p specifier so that at least there's a very high chance that each instance will go to a separate file. Rich. -- Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones virt-p2v converts physical machines to virtual machines. Boot with a live CD or over the network (PXE) and turn machines into Xen guests. http://et.redhat.com/~rjones/virt-p2v
participants (2)
-
Matthew Booth -
Richard W.M. Jones