[Top][All Lists]

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

Re: Findutils failure due to reliance /bin/echo

From: Ludovic Courtès
Subject: Re: Findutils failure due to reliance /bin/echo
Date: Thu, 06 May 2010 00:38:35 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/23.1 (gnu/linux)

Hi James,

James Youngman <address@hidden> writes:

> [ CC += address@hidden ]
> On Wed, May 5, 2010 at 3:53 PM, Ludovic Courtès <address@hidden> wrote:
>> Hi James,
>> James Youngman <address@hidden> writes:
>>> On Wed, May 5, 2010 at 9:35 AM, Ludovic Courtès <address@hidden> wrote:
>>>> Hi James,
>>>> Hydra Build Daemon <address@hidden> writes:
>>>>> FAIL: l1, unexpected failure, child process exited abnormally, 
>>>>> /tmp/nix-build-iqdrm25mpg40iivc59hjmdjjay1rfifp-findutils-4.5.10-git.drv-0/findutils-4.5.10-git/xargs/testsuite/../xargs:
>>>>>  /bin/echo: No such file or directory
>>>> This is due to the fact that there’s no /bin/echo in the build
>>>> environment (actually /bin on NixOS contains only /bin/sh).
>>>> If you want to rely on ‘echo’ other than the shell’s built-in, you
>>>> should use AC_PATH_PROG([echo]) in ‘configure.ac’ or something similar.
>>>> (Though I can’t think of any reason why the shell built-in wouldn’t
>>>> work.)
>>> Well, the shell builtin can never work because you can't exec it.
>>> POSIX requires xargs to run echo, though:
>>> utility
>>>     The name of the utility to be invoked, found by search path using
>>> the PATH environment variable, described in the Base Definitions
>>> volume of IEEE Std 1003.1-2001, Chapter 8, Environment Variables. If
>>> utility is omitted, the default shall be the echo utility. If the
>>> utility operand names any of the special built-in utilities in Special
>>> Built-In Utilities , the results are undefined.
>>> So essentially, the echo binary is a runtime dependency for findutils.
>> Understood, thanks for explaining.
>> Still, ‘AC_PATH_PROG([ECHO], [echo])’ and then referring to @ECHO@
>> instead of /bin/echo in xargs.in.c would remove this path assumption.
>> What do you think?
> The idea makes me very nervous indeed.   Implementing things that way
> would mean that the built xargs would fossilise the effect of whatever
> setting was in $PATH at the time xargs is built.

Another option would be to have --with-echo=/path/to/echo and keep
/bin/echo as a default.

Would that address your concerns?


reply via email to

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