From b4239a3813cfba92f6c91b9f3ce1df3c592f2cc9 Mon Sep 17 00:00:00 2001 From: Robin Dunn Date: Fri, 31 May 2019 08:46:20 -0700 Subject: [PATCH] Add backports.shutil_which --- build.py | 6 ++++++ requirements/devel.txt | 1 + 2 files changed, 7 insertions(+) diff --git a/build.py b/build.py index 03948d39..452bfdd7 100755 --- a/build.py +++ b/build.py @@ -32,6 +32,12 @@ try: except ImportError: import pathlib2 as pathlib +try: + from shutil import which +except ImportError: + from backports.shutil_which import which + + from distutils.dep_util import newer, newer_group from buildtools.config import Config, msg, opj, posixjoin, loadETG, etg2sip, findCmd, \ phoenixDir, wxDir, copyIfNewer, copyFile, \ diff --git a/requirements/devel.txt b/requirements/devel.txt index 0fec2567..148aa6e0 100644 --- a/requirements/devel.txt +++ b/requirements/devel.txt @@ -10,3 +10,4 @@ pytest pytest-xdist pytest-timeout pathlib2 ; python_version < "3" +backports.shutil_which ; python_version < "3"