[OE-core] [PATCH 1/1] systemd: add option for valgrind header checking

Burton, Ross ross.burton at intel.com
Wed Nov 12 15:55:28 UTC 2014


On 12 November 2014 10:45, Chen Qi <Qi.Chen at windriver.com> wrote:

> +-AC_CHECK_HEADERS_ONCE([valgrind/memcheck.h valgrind/valgrind.h])
> ++AC_ARG_ENABLE(valgrindheader, AS_HELP_STRING([--disable-valgrindheader],
> [disable valgrind header checking]))
> ++if test "x$enable_valgrindheader" != "xno"; then
> ++        AC_CHECK_HEADERS_ONCE([valgrind/memcheck.h valgrind/valgrind.h])
> ++fi
>

If the user passes --enable-valgrindheader and valgrind isn't present, it
doesn't fail.  Combined with the lack of a valgrind build dependency in the
PACKAGECONFIG statement this isn't a very useful PACKAGECONFIG option as it
only works when not specified, and if it's specified is non-deterministic.

It appears that this valgrind support is for running the test suite under
valgrind for leak detection, which is something we're unlikely to do.  A
quick fix would be to comment out the check.

A proper fix would be to use AC_ARG_WITH(valgrind), default to "auto", use
the pkg-config macros and respect yes/no/auto as appropriate.  The mantra
here being to spend ten minutes fixing it properly upstream instead of
having to rewrite the patch often as upstream changes their configure
script.

Ross
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openembedded.org/pipermail/openembedded-core/attachments/20141112/5d45b6b8/attachment-0002.html>


More information about the Openembedded-core mailing list