[PATCH] configure: use cc/c++ when GCC not installed

Tomi Ollila tomi.ollila at iki.fi
Wed May 21 15:21:09 PDT 2014


On Wed, May 21 2014, David Bremner <david at tethera.net> wrote:

> Tomi Ollila <tomi.ollila at iki.fi> writes:
>>
>> hash is builtin in modern shells, and is command in some systems
>> which(1) is builtin in zsh (only?). Solaris 10 which(1) exits 0
>> even the command is not found.
>>
>> Tomi
>
> I thought "command -v" was the posix way of testing for a binary?


Ok, I wrote quite a few lines why hash instead of command -v,
just to finally notice this:

$ dash -c 'hash zapdsb || echo foo'
dash: 1: hash: zapdsb : not found
foo

which is ok... but:

$ ksh -c 'hash zapdsb || echo foo'
$ mksh -c 'hash zapdsb || echo foo'

Wat! hash in these shells do not exit nonzero -- so good with my which(1)
rant >;/

So I change my preference totally -- `command -v` instead of `hash` -- we
have to fix the current uses of `hash` too...


> d


Tomi


More information about the notmuch mailing list