安装npm包scrypt失败

时间:2018-01-05 08:06:29

标签: node.js npm-install

我的机器上安装了nodejs,npm和node-gyp。我还安装了windows-build-tools作为scrypt包的先决条件。但是当我执行npm install scrypt时,我收到以下错误。如何解决这个问题?

enter image description here

完整的错误消息是: -

$ npm install scrypt --save

> scrypt@6.0.3 preinstall C:\Users\Benyah\node_modules\scrypt
> node node-scrypt-preinstall.js


> scrypt@6.0.3 install C:\Users\Benyah\node_modules\scrypt
> node-gyp rebuild


C:\Users\Benyah\node_modules\scrypt>if not defined npm_config_node_gyp (node "C\Users\Benyah\AppData\Roaming\npm\node_modules\npm\node_modules\npm-lifecycle\nde-gyp-bin\\..\..\node_modules\node-gyp\bin\node-gyp.js" rebuild )  else (node C:\Users\Benyah\AppData\Roaming\npm\node_modules\npm\node_modules\node-gyp\bin\ode-gyp.js" rebuild )
Warning: Missing input files:
C:\Users\Benyah\node_modules\scrypt\build\..\scrypt\win\include\config.h
Building the projects in this solution one at a time. To enable parallel build,please add the "/m" switch.
  Copying scrypt/win/include/config.h to scrypt/scrypt-1.2.0/config.h
  The system cannot find the file specified.
C:\Program Files (x86)\MSBuild\Microsoft.Cpp\v4.0\V140\Microsoft.CppCommon.targts(356,5): error MSB6006: "CL.exe" exited with code -1073741701. [C:\Users\Benyh\node_modules\scrypt\build\copied_files.vcxproj]
C:\Program Files (x86)\MSBuild\Microsoft.Cpp\v4.0\V140\Microsoft.CppCommon.targts(356,5): error MSB6006: "CL.exe" exited with code -1073741701. [C:\Users\Benyh\node_modules\scrypt\build\scrypt_wrapper.vcxproj]
gyp ERR! build error
gyp ERR! stack Error: `C:\Program Files (x86)\MSBuild\14.0\bin\msbuild.exe` faied with exit code: 1
gyp ERR! stack     at ChildProcess.onExit (C:\Users\Benyah\AppData\Roaming\npm\ode_modules\npm\node_modules\node-gyp\lib\build.js:258:23)
gyp ERR! stack     at emitTwo (events.js:126:13)
gyp ERR! stack     at ChildProcess.emit (events.js:214:7)
gyp ERR! stack     at Process.ChildProcess._handle.onexit (internal/child_proces.js:198:12)
gyp ERR! System Windows_NT 6.1.7601
gyp ERR! command "C:\\Program Files\\nodejs\\node.exe" "C:\\Users\\Benyah\\AppDta\\Roaming\\npm\\node_modules\\npm\\node_modules\\node-gyp\\bin\\node-gyp.js" rebuild"
gyp ERR! cwd C:\Users\Benyah\node_modules\scrypt
gyp ERR! node -v v8.9.4
gyp ERR! node-gyp -v v3.6.2
gyp ERR! not ok
npm WARN enoent ENOENT: no such file or directory, open 'C:\Users\Benyah\packag.json'
npm WARN Benyah No description
npm WARN Benyah No repository field.
npm WARN Benyah No README data
npm WARN Benyah No license field.

npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! scrypt@6.0.3 install: `node-gyp rebuild`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the scrypt@6.0.3 install script.
npm ERR! This is probably not a problem with npm. There is likely additional loging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     C:\Users\Benyah\AppData\Roaming\npm-cache\_logs\2018-01-05T10_00_1_241Z-debug.log

0 个答案:

没有答案
相关问题