server build failed
Opened this issue · 0 comments
Hi, I build server with npm i and failed:
npm ERR! code 1
npm ERR! path D:\YJWANG\workspace\js\react-ecommerce\server\node_modules\better-sqlite3
npm ERR! command failed
npm ERR! command C:\windows\system32\cmd.exe /d /s /c prebuild-install || npm run build-release
npm ERR! > better-sqlite3@7.4.6 build-release
npm ERR! > node-gyp rebuild --release
npm ERR!
npm ERR!
npm ERR! extract_sqlite3
npm ERR! sqlite3.c
npm ERR! win_delay_load_hook.cc
npm ERR! sqlite3.vcxproj -> D:\YJWANG\workspace\js\react-ecommerce\server\node_modules\better-sqlite3\build\Release\sqlite3.lib
npm ERR! better_sqlite3.cpp
npm ERR! D:\YJWANG\workspace\js\react-ecommerce\server\node_modules\better-sqlite3\build\src\util\macros.lzz(157,21): error C2039: "AccessorSignature": ���� "v8" �ij�Ա [D:\YJWANG\workspace\js\react-ecommerce\server\node_modules\better-sqlite3\build\better_sqlite3.vcxproj]
npm ERR! (����Դ�ļ���../src/better_sqlite3.cpp��)
npm ERR! C:\Users\to_wy\AppData\Local\node-gyp\Cache\20.9.0\include\node\v8.h(71,11):
npm ERR! ���v8��������
npm ERR!
npm ERR! D:\YJWANG\workspace\js\react-ecommerce\server\node_modules\better-sqlite3\build\src\util\macros.lzz(157,21): error C3083: ��AccessorSignature��:��::�����ķ��ű�����һ������ [D:\YJWANG\workspace\js\react-ecommerce\server\node_modules\better-sqlite3\build\better_sqlite3.vcxproj]
npm ERR! (����Դ�ļ���../src/better_sqlite3.cpp��)
npm ERR!
npm ERR! D:\YJWANG\workspace\js\react-ecommerce\server\node_modules\better-sqlite3\build\src\util\macros.lzz(157,40): error C2039: "New": ���� "v8" �ij�Ա [D:\YJWANG\workspace\js\react-ecommerce\server\node_modules\better-sqlite3\build\better_sqlite3.vcxproj]
npm ERR! (����Դ�ļ���../src/better_sqlite3.cpp��)
npm ERR! C:\Users\to_wy\AppData\Local\node-gyp\Cache\20.9.0\include\node\v8.h(71,11):
npm ERR! ���v8��������
npm ERR!
npm ERR! D:\YJWANG\workspace\js\react-ecommerce\server\node_modules\better-sqlite3\build\src\util\macros.lzz(157,40): error C3861: ��New��: �Ҳ�����ʶ�� [D:\YJWANG\workspace\js\react-ecommerce\server\node_modules\better-sqlite3\build\better_sqlite3.vcxproj]
npm ERR! (����Դ�ļ���../src/better_sqlite3.cpp��)
npm ERR!
npm ERR! D:\YJWANG\workspace\js\react-ecommerce\server\node_modules\better-sqlite3\build\src\util\binder.lzz(37,51): error C2039: "CreationContext": ���� "v8::Object" �ij�Ա [D:\YJWANG\workspace\js\react-ecommerce\server\node_modules\better-sqlite3\build\better_sqlite3.vcxproj]
npm ERR! (����Դ�ļ���../src/better_sqlite3.cpp��)
npm ERR! C:\Users\to_wy\AppData\Local\node-gyp\Cache\20.9.0\include\node\v8-value-serializer.h(22,7):
npm ERR! ���v8::Object��������
npm ERR!
npm ERR! test_extension.c
npm ERR! win_delay_load_hook.cc
npm ERR! ���ڴ����� D:\YJWANG\workspace\js\react-ecommerce\server\node_modules\better-sqlite3\build\Release\test_extension.lib �Ͷ��� D:\YJWANG\workspace\js\react-ecommerce\server\node_modules\better-sqlite3\build\Release\test_extension.exp
npm ERR! �������ɴ���
npm ERR! Previous IPDB not found, fall back to full compilation.
npm ERR! All 3 functions were compiled because no usable IPDB/IOBJ from previous compilation was found.
npm ERR! ����ɴ��������
npm ERR! test_extension.vcxproj -> D:\YJWANG\workspace\js\react-ecommerce\server\node_modules\better-sqlite3\build\Release\test_extension.node
npm ERR! prebuild-install warn install No prebuilt binaries found (target=20.9.0 runtime=node arch=x64 libc= platform=win32)
npm ERR! gyp info it worked if it ends with ok
npm ERR! gyp info using node-gyp@9.3.1
npm ERR! gyp info using node@20.9.0 | win32 | x64
npm ERR! gyp info find Python using Python version 3.11.0 found at "C:\Users\to_wy\AppData\Local\Programs\Python\Python311\python.exe"
npm ERR! gyp info find VS using VS2022 (17.8.34330.188) found at:
npm ERR! gyp info find VS "C:\Program Files\Microsoft Visual Studio\2022\Community"
npm ERR! gyp info find VS run with --verbose for detailed information
npm ERR! gyp info spawn C:\Users\to_wy\AppData\Local\Programs\Python\Python311\python.exe
npm ERR! gyp info spawn args [
npm ERR! gyp info spawn args 'C:\Users\to_wy\AppData\Roaming\npm\node_modules\npm\node_modules\node-gyp\gyp\gyp_main.py',
npm ERR! gyp info spawn args 'binding.gyp',
npm ERR! gyp info spawn args '-f',
npm ERR! gyp info spawn args 'msvs',
npm ERR! gyp info spawn args '-I',
npm ERR! gyp info spawn args 'D:\YJWANG\workspace\js\react-ecommerce\server\node_modules\better-sqlite3\build\config.gypi',
npm ERR! gyp info spawn args '-I',
npm ERR! gyp info spawn args 'C:\Users\to_wy\AppData\Roaming\npm\node_modules\npm\node_modules\node-gyp\addon.gypi',
npm ERR! gyp info spawn args '-I',
npm ERR! gyp info spawn args 'C:\Users\to_wy\AppData\Local\node-gyp\Cache\20.9.0\include\node\common.gypi',
npm ERR! gyp info spawn args '-Dlibrary=shared_library',
npm ERR! gyp info spawn args '-Dvisibility=default',
npm ERR! gyp info spawn args '-Dnode_root_dir=C:\Users\to_wy\AppData\Local\node-gyp\Cache\20.9.0',
npm ERR! gyp info spawn args '-Dnode_gyp_dir=C:\Users\to_wy\AppData\Roaming\npm\node_modules\npm\node_modules\node-gyp',
npm ERR! gyp info spawn args '-Dnode_lib_file=C:\\Users\\to_wy\\AppData\\Local\\node-gyp\\Cache\\20.9.0\\<(target_arch)\\node.lib',
npm ERR! gyp info spawn args '-Dmodule_root_dir=D:\YJWANG\workspace\js\react-ecommerce\server\node_modules\better-sqlite3',
npm ERR! gyp info spawn args '-Dnode_engine=v8',
npm ERR! gyp info spawn args '--depth=.',
npm ERR! gyp info spawn args '--no-parallel',
npm ERR! gyp info spawn args '--generator-output',
npm ERR! gyp info spawn args 'D:\YJWANG\workspace\js\react-ecommerce\server\node_modules\better-sqlite3\build',
npm ERR! gyp info spawn args '-Goutput_dir=.'
npm ERR! gyp info spawn args ]
npm ERR! gyp info spawn C:\Program Files\Microsoft Visual Studio\2022\Community\MSBuild\Current\Bin\MSBuild.exe
npm ERR! gyp info spawn args [
npm ERR! gyp info spawn args 'build/binding.sln',
npm ERR! gyp info spawn args '/clp:Verbosity=minimal',
npm ERR! gyp info spawn args '/nologo',
npm ERR! gyp info spawn args '/p:Configuration=Release;Platform=x64'
npm ERR! gyp info spawn args ]
npm ERR! gyp ERR! build error
npm ERR! gyp ERR! stack Error: C:\Program Files\Microsoft Visual Studio\2022\Community\MSBuild\Current\Bin\MSBuild.exe
failed with exit code: 1
npm ERR! gyp ERR! stack at ChildProcess.onExit (C:\Users\to_wy\AppData\Roaming\npm\node_modules\npm\node_modules\node-gyp\lib\build.js:203:23)
npm ERR! gyp ERR! stack at ChildProcess.emit (node:events:514:28)
npm ERR! gyp ERR! stack at ChildProcess._handle.onexit (node:internal/child_process:294:12)
npm ERR! gyp ERR! System Windows_NT 10.0.22621
npm ERR! gyp ERR! command "C:\Program Files\nodejs\node.exe" "C:\Users\to_wy\AppData\Roaming\npm\node_modules\npm\node_modules\node-gyp\bin\node-gyp.js" "rebuild" "--release"
npm ERR! gyp ERR! cwd D:\YJWANG\workspace\js\react-ecommerce\server\node_modules\better-sqlite3
npm ERR! gyp ERR! node -v v20.9.0
npm ERR! gyp ERR! node-gyp -v v9.3.1
npm ERR! gyp ERR! not ok
npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\to_wy\AppData\Local\npm-cache_logs\2023-12-11T00_26_22_160Z-debug-0.log