From b61a614cdb85255ce0629246ca1d934af48a5d86 Mon Sep 17 00:00:00 2001 From: Gilles Peskine Date: Thu, 22 Apr 2021 00:21:58 +0200 Subject: [PATCH] Use Python 3 instead of Python 2 to generate test files Python 2 is no longer officially supported, but we were still using it to generate test suite .c files from .function files when using GNU make. Switch to looking for Python 3. This change was done for CMake a long time ago. Signed-off-by: Gilles Peskine --- tests/Makefile | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/tests/Makefile b/tests/Makefile index 53f64b93d..7afd0f59f 100644 --- a/tests/Makefile +++ b/tests/Makefile @@ -53,8 +53,7 @@ else DLEXT ?= so EXEXT= SHARED_SUFFIX= -# python2 for POSIX since FreeBSD has only python2 as default. -PYTHON ?= python2 +PYTHON ?= $(shell if type python3 >/dev/null 2>/dev/null; then echo python3; else echo python; fi) endif # A test application is built for each suites/test_suite_*.data file.