1 2 3 4 5 6
PYVER ?= $(shell set -x; for p in python3 python2; do \ out=$$(command -v $$p 2>&1) && echo $$p && exit; done; \ exit 1) all: echo "PYVER=$(PYVER)"