From: Magnus Jacobsson Date: Sun, 12 Apr 2020 06:31:51 +0000 (+0200) Subject: Use specific Python version to run shapes.py X-Git-Tag: 2.44.1~79^2 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=09250ca96c7ca7574f2721ad5d233a9690cb69e7;p=graphviz Use specific Python version to run shapes.py The script runs fine with both Python 2 and Python 3, but on e.g. Fedora 31, Centos 8 & Ubuntu 20.04 there is no "python" program. Only "python2" and "python3". For some rationale regarding Centos 8, see https://www.liquidweb.com/kb/how-to-install-python-on-centos-8/ --- diff --git a/tests/regression_tests/shapes/Makefile.am b/tests/regression_tests/shapes/Makefile.am index d9533eb9d..ac2ca2e0d 100644 --- a/tests/regression_tests/shapes/Makefile.am +++ b/tests/regression_tests/shapes/Makefile.am @@ -1,6 +1,10 @@ SUBDIRS = reference check test rtest: - python shapes.py + if command -v python3; then \ + python3 shapes.py; \ + else \ + python2 shapes.py; \ + fi EXTRA_DIST = shapes.py