MSB1009:项目文件不存在

时间:2019-01-24 07:57:48

标签: web3js truffle ipfs

我正在尝试安装Web3 js。它给了我MSBUILD的错误。我无法继续。

我尝试安装新版本的node.js。但是我仍然无法成功安装Web3 js。

npm install web3

C:\Windows\System32>npm install web3
npm WARN deprecated fs-promise@2.0.3: Use mz or fs-extra^3.0 with Promise Support
npm WARN deprecated tar.gz@1.0.7: ⚠️  WARNING ⚠️ tar.gz module has been deprecated and your application is vulnerable. Please use tar module instead: https://npmjs.com/tar

> scrypt@6.0.3 preinstall C:\Windows\System32\node_modules\scrypt
> node node-scrypt-preinstall.js


> scrypt@6.0.3 install C:\Windows\System32\node_modules\scrypt
> node-gyp rebuild


C:\Windows\System32\node_modules\scrypt>if not defined npm_config_node_gyp (node "C:\Program Files\nodejs\node_modules\npm\node_modules\npm-lifecycle\node-gyp-bin\\..\..\node_modules\node-gyp\bin\node-gyp.js" rebuild )  else (node "C:\Program Files\nodejs\node_modules\npm\node_modules\node-gyp\bin\node-gyp.js" rebuild )
Warning: Missing input files:
C:\Windows\System32\node_modules\scrypt\build\..\scrypt\win\include\config.h
MSBUILD : error MSB1009: Project file does not exist.
Switch: build/binding.sln
gyp ERR! build error
gyp ERR! stack Error: `C:\Program Files (x86)\MSBuild\14.0\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:262:23)
gyp ERR! stack     at ChildProcess.emit (events.js:182:13)
gyp ERR! stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:240:12)
gyp ERR! System Windows_NT 10.0.17134
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 C:\Windows\System32\node_modules\scrypt
gyp ERR! node -v v10.15.0
gyp ERR! node-gyp -v v3.8.0
gyp ERR! not ok
npm WARN enoent ENOENT: no such file or directory, open 'C:\Windows\System32\package.json'
npm WARN prop-types-extra@1.1.0 requires a peer of react@>=0.14.0 but none is installed. You must install peer dependencies yourself.
npm WARN react-bootstrap@0.32.4 requires a peer of react@^0.14.9 || >=15.3.0 but none is installed. You must install peer dependencies yourself.
npm WARN react-bootstrap@0.32.4 requires a peer of react-dom@^0.14.9 || >=15.3.0 but none is installed. You must install peer dependencies yourself.
npm WARN react-overlays@0.8.3 requires a peer of react@^0.14.9 || >=15.3.0 but none is installed. You must install peer dependencies yourself.
npm WARN react-overlays@0.8.3 requires a peer of react-dom@^0.14.9 || >=15.3.0 but none is installed. You must install peer dependencies yourself.
npm WARN react-prop-types@0.4.0 requires a peer of react@>=0.14.0 but none is installed. You must install peer dependencies yourself.
npm WARN react-transition-group@2.5.3 requires a peer of react@>=15.0.0 but none is installed. You must install peer dependencies yourself.
npm WARN react-transition-group@2.5.3 requires a peer of react-dom@>=15.0.0 but none is installed. You must install peer dependencies yourself.
npm WARN uncontrollable@5.1.0 requires a peer of react@>=15.0.0 but none is installed. You must install peer dependencies yourself.
npm WARN System32 No description
npm WARN System32 No repository field.
npm WARN System32 No README data
npm WARN System32 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

1 个答案:

答案 0 :(得分:0)

我有同样的错误信息。我在cmd中执行了“ node-gyp configure”,发现找不到Python。所以我安装了Python 2.7 安装python后,错误消失了。