Skip to content

Commit b0df28d

Browse files
richardlautargos
authored andcommitted
build: add workaround for V8 builds
V8's build toolchain is not compatible with Python 3 and the CI job that tests V8 needs to be run with Python 2. Add a fallback to `find_executable` from `distutils.spawn` to allow the configure script to run in the V8 test job. PR-URL: #38632 Reviewed-By: Michaël Zasso <targos@protonmail.com> Reviewed-By: Darshan Sen <raisinten@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Rich Trott <rtrott@gmail.com>
1 parent 4c49027 commit b0df28d

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

configure.py

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,12 @@
1414
import bz2
1515
import io
1616

17-
from shutil import which
17+
# Fallback to find_executable from distutils.spawn is a stopgap for
18+
# supporting V8 builds, which do not yet support Python 3.
19+
try:
20+
from shutil import which
21+
except ImportError:
22+
from distutils.spawn import find_executable as which
1823
from distutils.version import StrictVersion
1924

2025
# If not run from node/, cd to node/.

0 commit comments

Comments
 (0)