From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([208.118.235.92]:35964) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SPFCY-0003Qq-G5 for qemu-devel@nongnu.org; Tue, 01 May 2012 11:41:19 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1SPFCV-00048r-Rz for qemu-devel@nongnu.org; Tue, 01 May 2012 11:41:18 -0400 Received: from e06smtp12.uk.ibm.com ([195.75.94.108]:58529) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SPFCV-00047T-Jb for qemu-devel@nongnu.org; Tue, 01 May 2012 11:41:15 -0400 Received: from /spool/local by e06smtp12.uk.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Tue, 1 May 2012 16:41:11 +0100 Received: from d06av11.portsmouth.uk.ibm.com (d06av11.portsmouth.uk.ibm.com [9.149.37.252]) by d06nrmr1806.portsmouth.uk.ibm.com (8.13.8/8.13.8/NCO v10.0) with ESMTP id q41Ff9o82949202 for ; Tue, 1 May 2012 16:41:09 +0100 Received: from d06av11.portsmouth.uk.ibm.com (loopback [127.0.0.1]) by d06av11.portsmouth.uk.ibm.com (8.14.4/8.13.1/NCO v10.0 AVout) with ESMTP id q41Ff9IS029599 for ; Tue, 1 May 2012 09:41:09 -0600 From: Stefan Hajnoczi Date: Tue, 1 May 2012 16:40:59 +0100 Message-Id: <1335886859-1028-6-git-send-email-stefanha@linux.vnet.ibm.com> In-Reply-To: <1335886859-1028-1-git-send-email-stefanha@linux.vnet.ibm.com> References: <1335886859-1028-1-git-send-email-stefanha@linux.vnet.ibm.com> Subject: [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: qemu-devel@nongnu.org Cc: Peter Maydell , Anthony Liguori , Stefan Hajnoczi , Erik Rull , Andreas Faerber , =?UTF-8?q?Llu=C3=ADs=20Vilanova?= 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 --- 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 # 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] >= 3)'; then - echo "Python 2 required but '$python' is version 3 or better." - echo "Use --python=/path/to/python to specify a Python 2." +if ! "$python" -c 'import sys; sys.exit(sys.version_info < (2,4) or sys.version_info >= (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=/path/to/python to specify a supported Python." exit 1 fi -- 1.7.10