From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from localhost (localhost [127.0.0.1]) by olra.theworths.org (Postfix) with ESMTP id 3A92F431FBC for ; Wed, 21 May 2014 15:21:27 -0700 (PDT) X-Virus-Scanned: Debian amavisd-new at olra.theworths.org X-Spam-Flag: NO X-Spam-Score: 0 X-Spam-Level: X-Spam-Status: No, score=0 tagged_above=-999 required=5 tests=[none] autolearn=disabled Received: from olra.theworths.org ([127.0.0.1]) by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id I4n7OQ+CsWwf for ; Wed, 21 May 2014 15:21:18 -0700 (PDT) Received: from guru.guru-group.fi (guru.guru-group.fi [46.183.73.34]) by olra.theworths.org (Postfix) with ESMTP id 7C2DA431FAE for ; Wed, 21 May 2014 15:21:18 -0700 (PDT) Received: from guru.guru-group.fi (localhost [IPv6:::1]) by guru.guru-group.fi (Postfix) with ESMTP id DB289100090; Thu, 22 May 2014 01:21:09 +0300 (EEST) From: Tomi Ollila To: David Bremner , Fraser Tweedale , notmuch@notmuchmail.org Subject: Re: [PATCH] configure: use cc/c++ when GCC not installed In-Reply-To: <878upu6ghm.fsf@maritornes.cs.unb.ca> References: <1400662721-68562-1-git-send-email-frase@frase.id.au> <878upu6ghm.fsf@maritornes.cs.unb.ca> User-Agent: Notmuch/0.18+12~g9d41f94 (http://notmuchmail.org) Emacs/24.3.1 (x86_64-unknown-linux-gnu) X-Face: HhBM'cA~ MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-BeenThere: notmuch@notmuchmail.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: "Use and development of the notmuch mail system." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 21 May 2014 22:21:27 -0000 On Wed, May 21 2014, David Bremner wrote: > Tomi Ollila 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=C2=A0|| echo foo' dash: 1: hash: zapdsb=C2=A0: not found foo which is ok... but: $ ksh -c 'hash zapdsb=C2=A0|| echo foo' $ mksh -c 'hash zapdsb=C2=A0|| 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