[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Problem with valgrind-tests: relies on bash not causing error

From: Marc Nieper-Wißkirchen
Subject: Re: Problem with valgrind-tests: relies on bash not causing error
Date: Fri, 14 Apr 2017 22:56:53 +0200
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.7.0

Hi Bruno,

Hi Reuben,

> The test for whether to use valgrind runs:
> /bin/bash -c 'exit 0'
> This looks pretty harmless; unfortunately, bash itself causes problems:

I'd suggest that you change m4/valgrind-tests.m4 to use the AC_CACHE_CHECK
macro instead of "lone" AC_MSG_CHECKING and AC_MSG_RESULT invocations.
Then you have an cache variable that you set as an environment variable
in order to override the result of this test, e.g.
  $ env gl_cv_use_valgrind=yes ./configure

Remember, nowadays that the autoconf cache is disabled by default, the
major benefit of AC_CACHE_CHECK is that it provides the user a way to
selectively override configure test results.

Today I have run into the same problem (namely that valgrind and bash are not going along very well).

While your proposed solution would work for anyone who is aware of this problem, it won't work for an unaware user who would simply run ./configure, wondering why valgrind isn't detected. As it seems rather involved to resolve the incompatibility between bash and valgrind, I would like to ask to have gnulib's valgrind-tests changed upstream. As this change amounts simply in replacing $(SHELL) by any other well-known utility, the changes to be done are trivial.

Having an updated version upstream makes it much easier for everyone  to pick up the necessary changes to make valgrind-tests work.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]