From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:46629) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gK28n-0001lp-Q3 for qemu-devel@nongnu.org; Tue, 06 Nov 2018 09:15:40 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gK26c-0002Lz-81 for qemu-devel@nongnu.org; Tue, 06 Nov 2018 09:13:25 -0500 Date: Tue, 6 Nov 2018 12:13:02 -0200 From: Eduardo Habkost Message-ID: <20181106141302.GP12503@habkost.net> References: <20181031003120.26771-1-ehabkost@redhat.com> <20181031003120.26771-12-ehabkost@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Subject: [Qemu-devel] [PATCH] tests: Fix Python 3 detection on older GNU make versions List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Peter Maydell Cc: Philippe =?iso-8859-1?Q?Mathieu-Daud=E9?= , Cleber Rosa , Kevin Wolf , Fam Zheng , Qemu-block , Philippe =?iso-8859-1?Q?Mathieu-Daud=E9?= , QEMU Developers , Max Reitz , Alex =?iso-8859-1?Q?Benn=E9e?= The $(SHELLSTATUS) variable requires GNU make >= 4.2, but Travis seems to provide an older version. Change the existing rules to use command output instead of exit code, to make it compatible with older GNU make versions. Signed-off-by: Eduardo Habkost --- I think that's the cause of the Travis failures. I have submitted a test job right now, at: https://travis-ci.org/ehabkost/qemu-hacks/jobs/451387962 Let's see if it fixes the issue. --- tests/Makefile.include | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/Makefile.include b/tests/Makefile.include index d2e577eabb..074eece558 100644 --- a/tests/Makefile.include +++ b/tests/Makefile.include @@ -913,8 +913,8 @@ TESTS_RESULTS_DIR=$(BUILD_DIR)/tests/results # information please refer to "avocado --help". AVOCADO_SHOW=none -$(shell $(PYTHON) -c 'import sys; assert sys.version_info >= (3,0)' >/dev/null 2>&1) -ifeq ($(.SHELLSTATUS),0) +PYTHON3 = $(shell $(PYTHON) -c 'import sys; print(1 if sys.version_info >= (3, 0) else 0)') +ifeq ($(PYTHON3), 1) $(TESTS_VENV_DIR): $(TESTS_VENV_REQ) $(call quiet-command, \ $(PYTHON) -m venv --system-site-packages $@, \ -- 2.18.0.rc1.1.g3f1ff2140