From 8de14b5c6a6126a3500cf3b2d0afb636cc046f0d Mon Sep 17 00:00:00 2001 From: Baptiste Augrain Date: Thu, 5 Oct 2023 16:44:52 +0200 Subject: [PATCH] wip: use patched node-gyp [skip ci] --- .github/workflows/stable-windows.yml | 2 +- prepare_vscode.sh | 13 ++++++++----- 2 files changed, 9 insertions(+), 6 deletions(-) diff --git a/.github/workflows/stable-windows.yml b/.github/workflows/stable-windows.yml index d7b7e4f..715cc69 100644 --- a/.github/workflows/stable-windows.yml +++ b/.github/workflows/stable-windows.yml @@ -33,7 +33,7 @@ env: jobs: build: - runs-on: windows-latest + runs-on: windows-2019 defaults: run: shell: bash diff --git a/prepare_vscode.sh b/prepare_vscode.sh index 0ea43a1..4632b2b 100755 --- a/prepare_vscode.sh +++ b/prepare_vscode.sh @@ -67,17 +67,16 @@ if [[ "${OS_NAME}" == "osx" ]]; then yarn postinstall else - if [[ "${npm_config_arch}" == "arm" ]]; then - export npm_config_arm_version=7 - elif [[ "${npm_config_arch}" == "ia32" ]]; then + if [[ "${OS_NAME}" == "windows" ]]; then # TODO: Should be replaced with upstream URL once https://github.com/nodejs/node-gyp/pull/2825 # gets merged. rm -rf .build/node-gyp mkdir -p .build/node-gyp cd .build/node-gyp - git clone https://github.com/rzhao271/node-gyp.git . - git checkout 102b347da0c92c29f9c67df22e864e70249cf086 + git clone https://github.com/nodejs/node-gyp.git . + git checkout v9.4.0 + git am --3way --whitespace=fix ../../build/npm/gyp/patches/gyp_spectre_mitigation_support.patch npm install npm_config_node_gyp=$( pwd ) @@ -86,6 +85,10 @@ else cd ../.. fi + if [[ "${npm_config_arch}" == "arm" ]]; then + export npm_config_arm_version=7 + fi + CHILD_CONCURRENCY=1 yarn --frozen-lockfile --network-timeout 180000 fi