Received: from [140.186.70.92] (port=53915 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Q8Gqp-0004DE-Nf for qemu-devel@nongnu.org; Fri, 08 Apr 2011 14:56:12 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Q8Gqo-0000Ub-Ok for qemu-devel@nongnu.org; Fri, 08 Apr 2011 14:56:11 -0400 Received: from mail-ww0-f53.google.com ([74.125.82.53]:37651) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Q8Gqo-0000UQ-KU for qemu-devel@nongnu.org; Fri, 08 Apr 2011 14:56:10 -0400 Received: by wwj40 with SMTP id 40so4328826wwj.10 for ; Fri, 08 Apr 2011 11:56:09 -0700 (PDT) Date: Fri, 8 Apr 2011 19:56:02 +0100 From: Stefan Hajnoczi Subject: Re: [Qemu-devel] [PATCH] configure: avoid basename usage message Message-ID: <20110408185602.GA15734@stefanha-thinkpad.localdomain> References: <20110408163349.GA1212@schlenkerla.am.freescale.net> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20110408163349.GA1212@schlenkerla.am.freescale.net> List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Scott Wood Cc: qemu-devel@nongnu.org On Fri, Apr 08, 2011 at 11:33:49AM -0500, Scott Wood wrote: > diff --git a/configure b/configure > index ae97e11..c5b85fe 100755 > --- a/configure > +++ b/configure > @@ -1233,7 +1233,8 @@ else > fi > sdl=no > fi > -if test -n "$cross_prefix" && test "`basename $sdlconfig`" = sdl-config; then > +if test -n "$cross_prefix" -a -n "$sdlconfig" && \ > + test "`basename $sdlconfig`" = sdl-config; then Instead of doing test -n "$sdlconfig" first with short-circuit evaluation, I think would should do: test $(basename "$sdlconfig") = sdl-config Then you don't need to test sdlconfig because basename will produce an empty string without error. Stefan