diff --git a/BUILDING.md b/BUILDING.md index 983fa9188e5317..1834c569527d44 100644 --- a/BUILDING.md +++ b/BUILDING.md @@ -229,7 +229,7 @@ The Node.js project supports Python >= 3 for building and testing. * `gcc` and `g++` >= 10.1 or newer * GNU Make 3.81 or newer -* Python >=3.6 <=3.11 (see note above) +* Python >=3.6 <=3.12 (see note above) * For test coverage, your Python installation must include pip. Installation via Linux package manager can be achieved with: @@ -245,7 +245,7 @@ FreeBSD and OpenBSD users may also need to install `libexecinfo`. #### macOS prerequisites * Xcode Command Line Tools >= 13 for macOS -* Python >=3.6 <=3.11 (see note above) +* Python >=3.6 <=3.12 (see note above) * For test coverage, your Python installation must include pip. macOS users can install the `Xcode Command Line Tools` by running @@ -575,7 +575,7 @@ to run it again before invoking `make -j4`. ##### Option 1: Manual install -* [Python 3.11](https://apps.microsoft.com/store/detail/python-311/9NRWMJP3717K) +* [Python 3.12](https://apps.microsoft.com/detail/python-3-12/9NCVDN91XZQP) * The "Desktop development with C++" workload from [Visual Studio 2022](https://visualstudio.microsoft.com/downloads/) or the "C++ build tools" workload from the diff --git a/configure b/configure index fefb313c9cd13c..711a3014b9a67f 100755 --- a/configure +++ b/configure @@ -4,6 +4,7 @@ # Note that the mix of single and double quotes is intentional, # as is the fact that the ] goes on a new line. _=[ 'exec' '/bin/sh' '-c' ''' +command -v python3.12 >/dev/null && exec python3.12 "$0" "$@" command -v python3.11 >/dev/null && exec python3.11 "$0" "$@" command -v python3.10 >/dev/null && exec python3.10 "$0" "$@" command -v python3.9 >/dev/null && exec python3.9 "$0" "$@" @@ -23,7 +24,7 @@ except ImportError: from distutils.spawn import find_executable as which print('Node.js configure: Found Python {}.{}.{}...'.format(*sys.version_info)) -acceptable_pythons = ((3, 11), (3, 10), (3, 9), (3, 8), (3, 7), (3, 6)) +acceptable_pythons = ((3, 12), (3, 11), (3, 10), (3, 9), (3, 8), (3, 7), (3, 6)) if sys.version_info[:2] in acceptable_pythons: import configure else: