To choose the node version we use. Together with:
https://github.com/python/buildmaster-config/pull/614
closes GH-136852.
(cherry picked from commit
aec7f5f8b2e8b5e02869cdb4e1f8a9ef87c9f953)
Co-authored-by: Hood Chatham <roberthoodchatham@gmail.com>
sysconfig_data += "-pydebug"
host_runner = context.host_runner
+ if node_version := os.environ.get("PYTHON_NODE_VERSION", None):
+ res = subprocess.run(
+ [
+ "bash",
+ "-c",
+ f"source ~/.nvm/nvm.sh && nvm which {node_version}",
+ ],
+ text=True,
+ capture_output=True,
+ )
+ host_runner = res.stdout.strip()
pkg_config_path_dir = (PREFIX_DIR / "lib/pkgconfig/").resolve()
env_additions = {
"CONFIG_SITE": config_site,