我正在尝试在Windows 10家庭版中安装和运行Hyperledger Fabric。
我遵循了Documentation中的说明。但是我必须更改的第一件事是家庭版,我必须使用Docker Quickstart Terminal。
因此,我去了Tutorial,运行Writing Your First Application。我遵循了说明,但是在npm install
中出现以下错误:
$ npm install
> grpc@1.14.2 install C:\Users\ricardo\fabric\fabric-samples\fabcar\node_modules\fabric-client\node_modules\grpc
> node-pre-gyp install --fallback-to-build --library=static_library
node-pre-gyp WARN Using request for node-pre-gyp https download
[grpc] Success: "C:\Users\ricardo\fabric\fabric-samples\fabcar\node_modules\fabric-client\node_modules\grpc\src\node\extension_binary\node-v57-win32-x64-unknown\grpc_node.node" is installed via remote
> pkcs11js@1.0.16 install C:\Users\ricardo\fabric\fabric-samples\fabcar\node_modules\pkcs11js
> node-gyp rebuild
C:\Users\ricardo\fabric\fabric-samples\fabcar\node_modules\pkcs11js>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 )
Building the projects in this solution one at a time. To enable parallel build, please add the "/m" switch.
MSBUILD : error MSB3428: Could not load the Visual C++ component "VCBuild.exe". To fix this, 1) install the .NET Framework 2.0 SDK, 2)
install Microsoft Visual Studio 2005 or 3) add the location of the component to the system path if it is installed elsewhere. [C:\Us
ers\ricardo\fabric\fabric-samples\fabcar\node_modules\pkcs11js\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 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_process.js:198: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:\Users\ricardo\fabric\fabric-samples\fabcar\node_modules\pkcs11js
gyp ERR! node -v v8.12.0
gyp ERR! node-gyp -v v3.8.0
gyp ERR! not ok
npm WARN fabcar@1.0.0 No repository field.
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! pkcs11js@1.0.16 install: `node-gyp rebuild`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the pkcs11js@1.0.16 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\ricardo\AppData\Roaming\npm-cache\_logs\2018-09-15T12_50_04_939Z-debug.log
我按照此site中的说明启用了.NET Framework 2.0。当我再次尝试运行npm install
时,得到了相同的输出。
因此,在尝试在Windows 10上安装Microsoft Visual Studio 2005之前,我想问一下是否真的需要Hyperledger在Home Edition上运行。