vscode: Failed to build main branch on Windows
Does this issue occur when all extensions are disabled?: N/A
- VS Code Version: N/A
- OS Version: Windows 10, 19043.1165
Pulled main branch this morning, and got this error when running yarn
:
PS D:\vscode> yarn
yarn install v1.17.3
$ node build/npm/preinstall.js
[1/4] Resolving packages...
[2/4] Fetching packages...
info fsevents@2.3.1: The platform "win32" is incompatible with this module.
info "fsevents@2.3.1" is an optional dependency and failed compatibility check. Excluding it from installation.
info fsevents@2.1.1: The platform "win32" is incompatible with this module.
info "fsevents@2.1.1" is an optional dependency and failed compatibility check. Excluding it from installation.
info fsevents@1.2.13: The platform "win32" is incompatible with this module.
info "fsevents@1.2.13" is an optional dependency and failed compatibility check. Excluding it from installation.
info fsevents@2.1.3: The platform "win32" is incompatible with this module.
info "fsevents@2.1.3" is an optional dependency and failed compatibility check. Excluding it from installation.
[3/4] Linking dependencies...
warning " > css-loader@3.2.0" has incorrect peer dependency "webpack@^4.0.0".
warning " > eslint-plugin-header@3.1.1" has incorrect peer dependency "eslint@>=7.7.0".
warning " > file-loader@4.2.0" has incorrect peer dependency "webpack@^4.0.0".
warning " > gulp-postcss@9.0.0" has unmet peer dependency "postcss@^8.0.0".
warning " > gulp-tsb@4.0.6" has incorrect peer dependency "typescript@^3.0.0".
warning " > sinon-test@3.1.0" has incorrect peer dependency "sinon@2.x - 10.x".
warning " > style-loader@1.0.0" has incorrect peer dependency "webpack@^4.0.0".
[4/4] Building fresh packages...
[1/19] ⢀ @vscode/sqlite3
[2/19] ⢀ keytar
[3/19] ⠠ native-is-elevated
[4/19] ⠠ native-keymap
error D:\vscode\node_modules\native-keymap: Command failed.
Exit code: 1
Command: node-gyp rebuild
Arguments:
Directory: D:\vscode\node_modules\native-keymap
Output:
D:\vscode\node_modules\native-keymap>if not defined npm_config_node_gyp (node "C:\Program Files\nodejs\node_modules\npm\bin\node-gyp-bin\\..\..\node_modules\node-gyp\bin\node-gyp.js" rebuild ) else (node "" rebuild )
gyp info it worked if it ends with ok
gyp info using node-gyp@7.1.2
gyp info using node@16.6.2 | win32 | x64
gyp info find Python using Python version 3.9.6 found at "C:\Python39\python.exe"
gyp info find VS using VS2019 (16.10.31515.178) found at:
gyp info find VS "C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise"
gyp info find VS run with --verbose for detailed information
(node:1812) [DEP0150] DeprecationWarning: Setting process.config is deprecated. In the future the property will be read-only.
(Use `node --trace-deprecation ...` to show where the warning was created)
gyp info spawn C:\Python39\python.exe
gyp info spawn args [
gyp info spawn args 'C:\\Program Files\\nodejs\\node_modules\\npm\\node_modules\\node-gyp\\gyp\\gyp_main.py', gyp info spawn args 'binding.gyp', gyp info spawn args '-f', gyp info spawn args 'msvs', gyp info spawn args '-I', gyp info spawn args 'D:\\vscode\\node_modules\\native-keymap\\build\\config.gypi',
gyp info spawn args '-I',
gyp info spawn args 'C:\\Program Files\\nodejs\\node_modules\\npm\\node_modules\\node-gyp\\addon.gypi',
gyp info spawn args '-I',
gyp info spawn args 'C:\\Users\\xisui\\AppData\\Local\\node-gyp\\Cache\\13.1.8\\include\\node\\common.gypi',
gyp info spawn args '-Dlibrary=shared_library',
gyp info spawn args '-Dvisibility=default',
gyp info spawn args '-Dnode_root_dir=C:\\Users\\xisui\\AppData\\Local\\node-gyp\\Cache\\13.1.8',
gyp info spawn args '-Dnode_gyp_dir=C:\\Program Files\\nodejs\\node_modules\\npm\\node_modules\\node-gyp',
gyp info spawn args '-Dnode_lib_file=C:\\\\Users\\\\xisui\\\\AppData\\\\Local\\\\node-gyp\\\\Cache\\\\13.1.8\\\\<(target_arch)\\\\node.lib',
gyp info spawn args '-Dmodule_root_dir=D:\\vscode\\node_modules\\native-keymap',
gyp info spawn args '-Dnode_engine=v8',
gyp info spawn args '--depth=.',
gyp info spawn args '--no-parallel',
gyp info spawn args '--generator-output',
gyp info spawn args 'D:\\vscode\\node_modules\\native-keymap\\build',
gyp info spawn args '-Goutput_dir=.'
gyp info spawn args ]
gyp info spawn C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\MSBuild\Current\Bin\MSBuild.exe
gyp info spawn args [
gyp info spawn args 'build/binding.sln',
gyp info spawn args '/clp:Verbosity=minimal',
gyp info spawn args '/nologo',
gyp info spawn args '/p:Configuration=Release;Platform=x64'
gyp info spawn args ]
Building the projects in this solution one at a time. To enable parallel build, please add the "-m" switch.
string_conversion.cc
keymapping.cc
C:\Users\xisui\AppData\Local\node-gyp\Cache\13.1.8\include\node\node.h(67,10): fatal error C1083: Cannot open include file: 'v8.h': No such file or directory [D:\vscode\node_modules\native-keymap\build\keymapping.vcxproj]
gyp ERR! build error
gyp ERR! stack Error: `C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\MSBuild\Current\Bin\MSBuild.exe` failed with exit code: 1
gyp ERR! stack at ChildProcess.onExit (C:\Program Files\nodejs\node_modules\npm\node_modules\node-gyp\lib\build.js:194:23)
gyp ERR! stack at ChildProcess.emit (node:events:394:28)
gyp ERR! stack at Process.ChildProcess._handle.onexit (node:internal/child_process:290:12)
gyp ERR! System Windows_NT 10.0.19043
gyp ERR! command "C:\\Program Files\\nodejs\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\node_modules\\node-gyp\\bin\\node-gyp.js" "rebuild"
gyp ERR! cwd D:\vscode\node_modules\native-keymap
warning Error running install script for optional dependency: "D:\\vscode\\node_modules\\windows-mutex: Command failed.
Exit code: 1
Command: node-gyp rebuild
Arguments:
Directory: D:\\vscode\\node_modules\\windows-mutex
Output:
D:\\vscode\\node_modules\\windows-mutex>if not defined npm_config_node_gyp (node \"C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\node-gyp-bin\\\\..\\..\\node_modules\\node-gyp\\bin\\node-gyp.js\" rebuild ) else (node \"\" rebuild )
gyp info it worked if it ends with ok
gyp info using node-gyp@7.1.2
gyp info using node@16.6.2 | win32 | x64
gyp info find Python using Python version 3.9.6 found at \"C:\\Python39\\python.exe\"
gyp info find VS using VS2019 (16.10.31515.178) found at:
gyp info find VS \"C:\\Program Files (x86)\\Microsoft Visual Studio\\2019\\Enterprise\"
gyp info find VS run with --verbose for detailed information
(node:10920) [DEP0150] DeprecationWarning: Setting process.config is deprecated. In the future the property will be read-only.
(Use `node --trace-deprecation ...` to show where the warning was created)
gyp info spawn C:\\Python39\\python.exe
gyp info spawn args [
gyp info spawn args 'C:\\\\Program Files\\\\nodejs\\\\node_modules\\\\npm\\\\node_modules\\\\node-gyp\\\\gyp\\\\gyp_main.py',
gyp info spawn args 'binding.gyp',
gyp info spawn args '-f',
gyp info spawn args 'msvs',
gyp info spawn args '-I',
gyp info spawn args 'D:\\\\vscode\\\\node_modules\\\\windows-mutex\\\\build\\\\config.gypi',
gyp info spawn args '-I',
gyp info spawn args 'C:\\\\Program Files\\\\nodejs\\\\node_modules\\\\npm\\\\node_modules\\\\node-gyp\\\\addon.gypi',
gyp info spawn args '-I',
gyp info spawn args 'C:\\\\Users\\\\xisui\\\\AppData\\\\Local\\\\node-gyp\\\\Cache\\\\13.1.8\\\\include\\\\node\\\\common.gypi',
gyp info spawn args '-Dlibrary=shared_library',
gyp info spawn args '-Dvisibility=default',
gyp info spawn args '-Dnode_root_dir=C:\\\\Users\\\\xisui\\\\AppData\\\\Local\\\\node-gyp\\\\Cache\\\\13.1.8',
gyp info spawn args '-Dnode_gyp_dir=C:\\\\Program Files\\\\nodejs\\\\node_modules\\\\npm\\\\node_modules\\\\node-gyp',
gyp info spawn args '-Dnode_lib_file=C:\\\\\\\\Users\\\\\\\\xisui\\\\\\\\AppData\\\\\\\\Local\\\\\\\\node-gyp\\\\\\\\Cache\\\\\\\\13.1.8\\\\\\\\<(target_arch)\\\\\\\\node.lib',
gyp info spawn args '-Dmodule_root_dir=D:\\\\vscode\\\\node_modules\\\\windows-mutex',
gyp info spawn args '-Dnode_engine=v8',
gyp info spawn args '--depth=.',
gyp info spawn args '--no-parallel',
gyp info spawn args '--generator-output',
gyp info spawn args 'D:\\\\vscode\\\\node_modules\\\\windows-mutex\\\\build',
gyp info spawn args '-Goutput_dir=.'
gyp info spawn args ]
gyp info spawn C:\\Program Files (x86)\\Microsoft Visual Studio\\2019\\Enterprise\\MSBuild\\Current\\Bin\\MSBuild.exe
gyp info spawn args [
gyp info spawn args 'build/binding.sln',
gyp info spawn args '/clp:Verbosity=minimal',
gyp info spawn args '/nologo',
gyp info spawn args '/p:Configuration=Release;Platform=x64'
gyp info spawn args ]
Building the projects in this solution one at a time. To enable parallel build, please add the \"-m\" switch.
main.cc
C:\\Users\\xisui\\AppData\\Local\\node-gyp\\Cache\\13.1.8\\include\\node\\node.h(67,10): fatal error C1083: Cannot open include file: 'v8.h': No such file or directory [D:\\vscode\\node_modules\\windows-mutex\\build\\CreateMutex.vcxproj]
gyp ERR! build error
gyp ERR! stack Error: `C:\\Program Files (x86)\\Microsoft Visual Studio\\2019\\Enterprise\\MSBuild\\Current\\Bin\\MSBuild.exe` failed with exit code: 1
gyp ERR! stack at ChildProcess.onExit (C:\\Program Files\\nodejs\\node_modules\\npm\\node_modules\\node-gyp\\lib\\build.js:194:23)
gyp ERR! stack at ChildProcess.emit (node:events:394:28)
gyp ERR! stack at Process.ChildProcess._handle.onexit (node:internal/child_process:290:12)
gyp ERR! System Windows_NT 10.0.19043
gyp ERR! command \"C:\\\\Program Files\\\\nodejs\\\\node.exe\" \"C:\\\\Program Files\\\\nodejs\\\\node_modules\\\\npm\\\\node_modules\\\\node-gyp\\\\bin\\\\node-gyp.js\" \"rebuild\"
gyp ERR! cwd D:\\vscode\\node_modules\\windows-mutex
gyp ERR! node -v v16.6.2
gyp ERR! node-gyp -v v7.1.2
gyp ERR! not ok"
info This module is OPTIONAL, you can safely ignore this error
warning Error running install script for optional dependency: "D:\\vscode\\node_modules\\windows-process-tree: Command failed.
Exit code: 1
Command: node-gyp rebuild
Arguments:
Directory: D:\\vscode\\node_modules\\windows-process-tree
Output:
D:\\vscode\\node_modules\\windows-process-tree>if not defined npm_config_node_gyp (node \"C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\node-gyp-bin\\\\..\\..\\node_modules\\node-gyp\\bin\\node-gyp.js\" rebuild ) else (node \"\" rebuild )
gyp info it worked if it ends with ok
gyp info using node-gyp@7.1.2
gyp info using node@16.6.2 | win32 | x64
gyp info find Python using Python version 3.9.6 found at \"C:\\Python39\\python.exe\"
gyp info find VS using VS2019 (16.10.31515.178) found at:
gyp info find VS \"C:\\Program Files (x86)\\Microsoft Visual Studio\\2019\\Enterprise\"
gyp info find VS run with --verbose for detailed information
(node:7576) [DEP0150] DeprecationWarning: Setting process.config is deprecated. In the future the property will be read-only.
(Use `node --trace-deprecation ...` to show where the warning was created)
gyp info spawn C:\\Python39\\python.exe
gyp info spawn args [
gyp info spawn args 'C:\\\\Program Files\\\\nodejs\\\\node_modules\\\\npm\\\\node_modules\\\\node-gyp\\\\gyp\\\\gyp_main.py',
gyp info spawn args 'binding.gyp',
gyp info spawn args '-f',
gyp info spawn args 'msvs',
gyp info spawn args '-I',
gyp info spawn args 'D:\\\\vscode\\\\node_modules\\\\windows-process-tree\\\\build\\\\config.gypi',
gyp info spawn args '-I',
gyp info spawn args 'C:\\\\Program Files\\\\nodejs\\\\node_modules\\\\npm\\\\node_modules\\\\node-gyp\\\\addon.gypi',
gyp info spawn args '-I',
gyp info spawn args 'C:\\\\Users\\\\xisui\\\\AppData\\\\Local\\\\node-gyp\\\\Cache\\\\13.1.8\\\\include\\\\node\\\\common.gypi',
gyp info spawn args '-Dlibrary=shared_library',
gyp info spawn args '-Dvisibility=default',
gyp info spawn args '-Dnode_root_dir=C:\\\\Users\\\\xisui\\\\AppData\\\\Local\\\\node-gyp\\\\Cache\\\\13.1.8',
gyp info spawn args '-Dnode_gyp_dir=C:\\\\Program Files\\\\nodejs\\\\node_modules\\\\npm\\\\node_modules\\\\node-gyp',
gyp info spawn args '-Dnode_lib_file=C:\\\\\\\\Users\\\\\\\\xisui\\\\\\\\AppData\\\\\\\\Local\\\\\\\\node-gyp\\\\\\\\Cache\\\\\\\\13.1.8\\\\\\\\<(target_arch)\\\\\\\\node.lib',
gyp info spawn args '-Dmodule_root_dir=D:\\\\vscode\\\\node_modules\\\\windows-process-tree',
gyp info spawn args '-Dnode_engine=v8',
gyp info spawn args '--depth=.',
gyp info spawn args '--no-parallel',
gyp info spawn args '--generator-output',
gyp info spawn args 'D:\\\\vscode\\\\node_modules\\\\windows-process-tree\\\\build',
gyp info spawn args '-Goutput_dir=.'
gyp info spawn args ]
gyp info spawn C:\\Program Files (x86)\\Microsoft Visual Studio\\2019\\Enterprise\\MSBuild\\Current\\Bin\\MSBuild.exe
gyp info spawn args [
gyp info spawn args 'build/binding.sln',
gyp info spawn args '/clp:Verbosity=minimal',
gyp info spawn args '/nologo',
gyp info spawn args '/p:Configuration=Release;Platform=x64'
gyp info spawn args ]
Building the projects in this solution one at a time. To enable parallel build, please add the \"-m\" switch.
addon.cc
C:\\Users\\xisui\\AppData\\Local\\node-gyp\\Cache\\13.1.8\\include\\node\\node.h(67,10): fatal error C1083: Cannot open include file: 'v8.h': No such file or directory [D:\\vscode\\node_modules\\windows-process-tree\\build\\windows_process_tree.vcxproj]
gyp ERR! build error
gyp ERR! stack Error: `C:\\Program Files (x86)\\Microsoft Visual Studio\\2019\\Enterprise\\MSBuild\\Current\\Bin\\MSBuild.exe` failed with exit code: 1
gyp ERR! stack at ChildProcess.onExit (C:\\Program Files\\nodejs\\node_modules\\npm\\node_modules\\node-gyp\\lib\\build.js:194:23)
gyp ERR! stack at ChildProcess.emit (node:events:394:28)
gyp ERR! stack at Process.ChildProcess._handle.onexit (node:internal/child_process:290:12)
gyp ERR! System Windows_NT 10.0.19043
gyp ERR! command \"C:\\\\Program Files\\\\nodejs\\\\node.exe\" \"C:\\\\Program Files\\\\nodejs\\\\node_modules\\\\npm\\\\node_modules\\\\node-gyp\\\\bin\\\\node-gyp.js\" \"rebuild\"
gyp ERR! cwd D:\\vscode\\node_modules\\windows-process-tree
gyp ERR! node -v v16.6.2
gyp ERR! node-gyp -v v7.1.2
gyp ERR! not ok"
info This module is OPTIONAL, you can safely ignore this error
Any idea?
About this issue
- Original URL
- State: closed
- Created 3 years ago
- Comments: 25 (23 by maintainers)
Sorry for the delayed response, for https://github.com/microsoft/vscode/issues/130947#issue-972157949 trying deleting the cache folder
C:\\Users\\xisui\\AppData\\Local\\node-gyp\\Cache\\13.1.8
, very likely incomplete downloads of the headers.For the cygwin error, it is best if you followed up with
node-gyp
. See if you hit the same error building any native module https://github.com/mapbox/node-sqlite3