Open affanmehmood opened 1 year ago
Please click on "Post Edit" and format your code properly
@nshmyrev sorry about that. I've formatted it now.
It is some recent bug in ff-napi it seems, it doesn't like spaces in your path
As a quick fix you can install node into root folder instead of 'program files'
Or you have "Program Files" somewhere in environment variable that affects node
I'm getting the same error after installing node inside the root
C:\User\vosk-api>npm install
ffi-napi@4.0.3 install C:\User\vosk-api\node_modules\ffi-napi node-gyp-build C:\User\vosk-api\node_modules\ffi-napi>if not defined npm_config_node_gyp (node "C:\nodejs\node_modules\npm\node_modules\npm-lifecycle\node-gyp-bin\....\node_modules\node-gyp\bin\node-gyp.js" rebuild ) else (node "C:\nodejs\node_modules\npm\node_modules\node-gyp\bin\node-gyp.js" rebuild ) Building the projects in this solution one at a time. To enable parallel build, please add the "-m" switch. Preprocessing assembly file ......\deps\libffi\src\x86\win64_intel.preasm Program c1 : fatal error C1083: Cannot open source file: 'C:\Program': No such file or directory [C:\User\vosk-api\no de_modules\ffi-napi\build\deps\libffi\ffi.vcxproj] Files c1 : fatal error C1083: Cannot open source file: 'Files': No such file or directory [C:\User\vosk-api\node_mo dules\ffi-napi\build\deps\libffi\ffi.vcxproj] Microsoft c1 : fatal error C1083: Cannot open source file: '(x86)\Microsoft': No such file or directory [C:\User\vosk-a pi\node_modules\ffi-napi\build\deps\libffi\ffi.vcxproj] Visual c1 : fatal error C1083: Cannot open source file: 'Visual': No such file or directory [C:\User\vosk-api\node_m odules\ffi-napi\build\deps\libffi\ffi.vcxproj] BuildTools c1 : fatal error C1083: Cannot open source file: 'Studio\2019\BuildTools': No such file or directory [C:\User \vosk-api\node_modules\ffi-napi\build\deps\libffi\ffi.vcxproj] win64_intel.preasm C:\User\vosk-api\node_modules\ffi-napi\build\deps\libffi\ffi.targets(34,5): error MSB3721: The command "call call "......\deps\libffi\preprocess_asm.cmd" "......\deps\libffi\include" "......\deps\libffi\config\win\x64" ".. ....\deps\libffi\src\x86\win64_intel.preasm" "Release\obj\ffi\win64_intel.asm"" exited with code 2. [C:\Work\affect-c x\vosk-api\node_modules\ffi-napi\build\deps\libffi\ffi.vcxproj] Program Files Microsoft Visual BuildTools nothing.c c1 : fatal error C1083: Cannot open source file: '(x86)\Microsoft': No such file or directory [C:\User\vosk-a pi\node_modules\ffi-napi\node-addon-api\nothing.vcxproj] c1 : fatal error C1083: Cannot open source file: 'Files': No such file or directory [C:\User\vosk-api\node_mo dules\ffi-napi\node-addon-api\nothing.vcxproj] c1 : fatal error C1083: Cannot open source file: 'Visual': No such file or directory [C:\User\vosk-api\node_m odules\ffi-napi\node-addon-api\nothing.vcxproj] c1 : fatal error C1083: Cannot open source file: 'Studio\2019\BuildTools': No such file or directory [C:\User \vosk-api\node_modules\ffi-napi\node-addon-api\nothing.vcxproj] c1 : fatal error C1083: Cannot open source file: 'C:\Program': No such file or directory [C:\User\vosk-api\no de_modules\ffi-napi\node-addon-api\nothing.vcxproj] gyp ERR! build error gyp ERR! stack Error:
C:\Program Files (x86)\Microsoft Visual Studio\2019\BuildTools\MSBuild\Current\Bin\MSBuild.exe
failed with exit code: 1 gyp ERR! stack at ChildProcess.onExit (C:\nodejs\node_modules\npm\node_modules\node-gyp\lib\build.js:194:23) gyp ERR! stack at ChildProcess.emit (events.js:315:20) gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:277:12) gyp ERR! System Windows_NT 10.0.22000 gyp ERR! command "C:\nodejs\node.exe" "C:\nodejs\node_modules\npm\node_modules\node-gyp\bin\node-gyp.js" "rebuild" gyp ERR! cwd C:\User\vosk-api\node_modules\ffi-napi gyp ERR! node -v v14.16.0 gyp ERR! node-gyp -v v5.1.0 gyp ERR! not ok npm ERR! code ELIFECYCLE npm ERR! errno 1 npm ERR! ffi-napi@4.0.3 install:node-gyp-build
npm ERR! Exit status 1 npm ERR! npm ERR! Failed at the ffi-napi@4.0.3 install script. npm ERR! This is probably not a problem with npm. There is likely additional logging output above. npm ERR! A complete log of this run can be found in: npm ERR! C:\Users\affan\AppData\Roaming\npm-cache_logs\2022-12-16T12_51_45_462Z-debug.log
I'm having the same issue, the problem is also ffi-napi. Trying to run a program that works on Mac on a Windows machine. Has anyone solved this?
Its still broken, not working in windows 11, Node Version 20
Same Debian 12
Is it possible to run this project on a windows machine?
My Node version is 14.19.0 My python version is 3.7.9
Is it possible to run it in windows in a node environment? Can someone guide me on how to do that?
when I npm install I get the following error:
C:\User\vosk-api\nodejs>npm i