-
-
Notifications
You must be signed in to change notification settings - Fork 1.9k
Closed
Labels
Description
- Node Version: Node 16.20, npm 8.19.4
- Platform: Windows 11
- Compiler: VS Build Tools 17.5.33530.505
- Module: parcel, probably
Getting the following error when trying to run npm install on a project that uses node-gyp via parcel:
C:\Users\[user]\AppData\Local\node-gyp\Cache\16.20.0\include\node\node_api.h(12,10): fatal error C1083: Cannot open include file: 'js_native_api.h': No such file or directory [C:\Users\[user]\[project]\node_modules\lmdb\build\lmdb.vcxproj]
Verbose output (from npm or node-gyp):
5566 error code 1
5567 error path C:\Users\e10113712\development\studio\node_modules\lmdb
5568 error command failed
5569 error command C:\WINDOWS\system32\cmd.exe /d /s /c node-gyp-build-optional-packages
5570 error Building the projects in this solution one at a time. To enable parallel build, please add the "-m" switch.
5570 error
5570 error lmdb-js.cpp
5570 error C:\Users\e10113712\AppData\Local\node-gyp\Cache\16.20.0\include\node\node_api.h(12,10): fatal error C1083: Cannot open include file: 'js_native_api.h': No such file or directory [C:\Users\e10113712\development\studio\node_modules\lmdb\build\lmdb.vcxproj]
5571 error gyp info it worked if it ends with ok
5571 error gyp info using [email protected]
5571 error gyp info using [email protected] | win32 | x64
5571 error gyp info find Python using Python version 3.11.3 found at "C:\Users\e10113712\AppData\Local\Programs\Python\Python311\python.exe"
5571 error gyp info find VS using VS2022 (17.5.33530.505) found at:
5571 error gyp info find VS "C:\Program Files (x86)\Microsoft Visual Studio\2022\BuildTools"
5571 error gyp info find VS run with --verbose for detailed information
5571 error gyp info spawn C:\Users\e10113712\AppData\Local\Programs\Python\Python311\python.exe
5571 error gyp info spawn args [
5571 error gyp info spawn args 'C:\\Users\\e10113712\\AppData\\Roaming\\nvm\\v16.20.0\\node_modules\\npm\\node_modules\\node-gyp\\gyp\\gyp_main.py',
5571 error gyp info spawn args 'binding.gyp',
5571 error gyp info spawn args '-f',
5571 error gyp info spawn args 'msvs',
5571 error gyp info spawn args '-I',
5571 error gyp info spawn args 'C:\\Users\\e10113712\\development\\studio\\node_modules\\lmdb\\build\\config.gypi',
5571 error gyp info spawn args '-I',
5571 error gyp info spawn args 'C:\\Users\\e10113712\\AppData\\Roaming\\nvm\\v16.20.0\\node_modules\\npm\\node_modules\\node-gyp\\addon.gypi',
5571 error gyp info spawn args '-I',
5571 error gyp info spawn args 'C:\\Users\\e10113712\\AppData\\Local\\node-gyp\\Cache\\16.20.0\\include\\node\\common.gypi',
5571 error gyp info spawn args '-Dlibrary=shared_library',
5571 error gyp info spawn args '-Dvisibility=default',
5571 error gyp info spawn args '-Dnode_root_dir=C:\\Users\\e10113712\\AppData\\Local\\node-gyp\\Cache\\16.20.0',
5571 error gyp info spawn args '-Dnode_gyp_dir=C:\\Users\\e10113712\\AppData\\Roaming\\nvm\\v16.20.0\\node_modules\\npm\\node_modules\\node-gyp',
5571 error gyp info spawn args '-Dnode_lib_file=C:\\\\Users\\\\e10113712\\\\AppData\\\\Local\\\\node-gyp\\\\Cache\\\\16.20.0\\\\<(target_arch)\\\\node.lib',
5571 error gyp info spawn args '-Dmodule_root_dir=C:\\Users\\e10113712\\development\\studio\\node_modules\\lmdb',
5571 error gyp info spawn args '-Dnode_engine=v8',
5571 error gyp info spawn args '--depth=.',
5571 error gyp info spawn args '--no-parallel',
5571 error gyp info spawn args '--generator-output',
5571 error gyp info spawn args 'C:\\Users\\e10113712\\development\\studio\\node_modules\\lmdb\\build',
5571 error gyp info spawn args '-Goutput_dir=.'
5571 error gyp info spawn args ]
5571 error gyp info spawn C:\Program Files (x86)\Microsoft Visual Studio\2022\BuildTools\MSBuild\Current\Bin\MSBuild.exe
5571 error gyp info spawn args [
5571 error gyp info spawn args 'build/binding.sln',
5571 error gyp info spawn args '/clp:Verbosity=minimal',
5571 error gyp info spawn args '/nologo',
5571 error gyp info spawn args '/p:Configuration=Release;Platform=x64'
5571 error gyp info spawn args ]
5571 error gyp ERR! build error
5571 error gyp ERR! stack Error: `C:\Program Files (x86)\Microsoft Visual Studio\2022\BuildTools\MSBuild\Current\Bin\MSBuild.exe` failed with exit code: 1
5571 error gyp ERR! stack at ChildProcess.onExit (C:\Users\e10113712\AppData\Roaming\nvm\v16.20.0\node_modules\npm\node_modules\node-gyp\lib\build.js:201:23)
5571 error gyp ERR! stack at ChildProcess.emit (node:events:513:28)
5571 error gyp ERR! stack at Process.ChildProcess._handle.onexit (node:internal/child_process:293:12)
5571 error gyp ERR! System Windows_NT 10.0.22621
5571 error gyp ERR! command "C:\\Program Files\\nodejs\\node.exe" "C:\\Users\\e10113712\\AppData\\Roaming\\nvm\\v16.20.0\\node_modules\\npm\\node_modules\\node-gyp\\bin\\node-gyp.js" "rebuild"
5571 error gyp ERR! cwd C:\Users\e10113712\development\studio\node_modules\lmdb
5571 error gyp ERR! node -v v16.20.0
5571 error gyp ERR! node-gyp -v v9.1.0
5571 error gyp ERR! not ok
5572 verbose exit 1