Received: from eggs.gnu.org ([208.118.235.92]:59425) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SPFVu-0006YP-C9 for qemu-devel@nongnu.org; Tue, 01 May 2012 12:01:20 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1SPFVr-00048W-Eo for qemu-devel@nongnu.org; Tue, 01 May 2012 12:01:17 -0400 Received: from roura.ac.upc.es ([147.83.33.10]:32842) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SPFVr-000481-4W for qemu-devel@nongnu.org; Tue, 01 May 2012 12:01:15 -0400 From: =?utf-8?Q?Llu=C3=ADs_Vilanova?= References: <1335886859-1028-1-git-send-email-stefanha@linux.vnet.ibm.com> <1335886859-1028-6-git-send-email-stefanha@linux.vnet.ibm.com> Date: Tue, 01 May 2012 18:00:14 +0200 In-Reply-To: <1335886859-1028-6-git-send-email-stefanha@linux.vnet.ibm.com> (Stefan Hajnoczi's message of "Tue, 1 May 2012 16:40:59 +0100") Message-ID: <87lilbevsh.fsf@fimbulvetr.bsc.es> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Subject: Re: [Qemu-devel] [PATCH v3 5/5] configure: check for supported Python 2.x versions List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Stefan Hajnoczi Cc: Peter Maydell , Anthony Liguori , qemu-devel@nongnu.org, Andreas Faerber , Erik Rull Stefan Hajnoczi writes: > The tracetool code requires Python 2.4, which was released in 2004. > Check for a supported Python version so we can give a clear error > message. > Signed-off-by: Stefan Hajnoczi Reviewed-by: Llu=C3=ADs Vilanova > --- > configure | 7 ++++--- > 1 file changed, 4 insertions(+), 3 deletions(-) > diff --git a/configure b/configure > index 25697bb..ccffd87 100755 > --- a/configure > +++ b/configure > @@ -1247,9 +1247,10 @@ fi =20 > # Note that if the Python conditional here evaluates True we will exit > # with status 1 which is a shell 'false' value. > -if ! "$python" -c 'import sys; sys.exit(sys.version_info[0] >=3D 3)'; th= en > - echo "Python 2 required but '$python' is version 3 or better." > - echo "Use --python=3D/path/to/python to specify a Python 2." > +if ! "$python" -c 'import sys; sys.exit(sys.version_info < (2,4) or sys.= version_info >=3D (3,))'; then > + echo "Cannot use '$python', Python 2.4 or later is required." > + echo "Note that Python 3 or later is not yet supported." > + echo "Use --python=3D/path/to/python to specify a supported Python." > exit 1 > fi =20 > --=20 > 1.7.10 --=20 "And it's much the same thing with knowledge, for whenever you learn something new, the whole world becomes that much richer." -- The Princess of Pure Reason, as told by Norton Juster in The Phantom Tollbooth