From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:39662) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WlCya-0006MW-DW for qemu-devel@nongnu.org; Fri, 16 May 2014 03:54:50 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1WlCyU-0008Iv-4p for qemu-devel@nongnu.org; Fri, 16 May 2014 03:54:44 -0400 Received: from mx1.redhat.com ([209.132.183.28]:11109) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WlCyT-0008Il-TT for qemu-devel@nongnu.org; Fri, 16 May 2014 03:54:38 -0400 Date: Fri, 16 May 2014 15:54:45 +0800 From: Fam Zheng Message-ID: <20140516075445.GE1941@T430.nay.redhat.com> References: <1400192774-606-1-git-send-email-mreitz@redhat.com> <1400192774-606-6-git-send-email-mreitz@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1400192774-606-6-git-send-email-mreitz@redhat.com> Subject: Re: [Qemu-devel] [PATCH 5/7] iotests: Use $PYTHON for Python scripts List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Max Reitz Cc: Kevin Wolf , Peter Maydell , qemu-devel@nongnu.org, Stefan Hajnoczi , Markus Armbruster On Fri, 05/16 00:26, Max Reitz wrote: > diff --git a/tests/qemu-iotests/check b/tests/qemu-iotests/check > index bd66630..9968db9 100755 > --- a/tests/qemu-iotests/check > +++ b/tests/qemu-iotests/check > @@ -287,10 +287,17 @@ do > > start=`_wallclock` > $timestamp && echo -n " ["`date "+%T"`"]" > + > + if [ "$(head -n 1 "$source_iotests/$seq")" == "#!/usr/bin/env python" ]; then > + run_command="$PYTHON $seq" > + else > + [ ! -x "$source_iotests/$seq" ] && chmod u+x "$source_iotests/$seq" # ensure we can run it No, I don't think we need chmod here, to change source tree. If the mode has no x bit, we need a git commit to fix it. Fam > + run_command="./$seq" > + fi > export OUTPUT_DIR="$PWD" > (cd "$source_iotests"; > MALLOC_PERTURB_=${MALLOC_PERTURB_:-$(($RANDOM % 255 + 1))} \ > - ./$seq >$tmp.out 2>&1) > + $run_command >$tmp.out 2>&1) > sts=$? > $timestamp && _timestamp > stop=`_wallclock` > -- > 1.9.2 > >