尝试在本地安装grpc-node

时间:2018-11-01 17:38:02

标签: node.js npm npm-install grpc node-pre-gyp

我正在尝试通过npm install在本地安装grpc,而我使用的命令是sudo npm i grpc --unsafe-perm。我收到错误消息,但不确定自己在做什么错。我在linux,ubuntu 18.04.1。我有节点v11和npm v6.4.1。

这是错误日志:

gyp ERR! build error 
gyp ERR! stack Error: `make` failed with exit code: 2
gyp ERR! stack     at ChildProcess.onExit (/usr/local/lib/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 Linux 4.15.0-38-generic
gyp ERR! command "/usr/local/bin/node" "/usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "build" "--fallback-to-build" "--library=static_library" "--module=/media/binyamin/Seagate Expansion Drive/Documents/GitHub/admin-app/node_modules/grpc/src/node/extension_binary/node-v67-linux-x64-glibc/grpc_node.node" "--module_name=grpc_node" "--module_path=/media/binyamin/Seagate Expansion Drive/Documents/GitHub/admin-app/node_modules/grpc/src/node/extension_binary/node-v67-linux-x64-glibc" "--napi_version=3" "--node_abi_napi=napi"
gyp ERR! cwd /media/binyamin/Seagate Expansion Drive/Documents/GitHub/admin-app/node_modules/grpc
gyp ERR! node -v v11.0.0
gyp ERR! node-gyp -v v3.8.0
gyp ERR! not ok 
node-pre-gyp ERR! build error 
node-pre-gyp ERR! stack Error: Failed to execute '/usr/local/bin/node /usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js build --fallback-to-build --library=static_library --module=/media/binyamin/Seagate Expansion Drive/Documents/GitHub/admin-app/node_modules/grpc/src/node/extension_binary/node-v67-linux-x64-glibc/grpc_node.node --module_name=grpc_node --module_path=/media/binyamin/Seagate Expansion Drive/Documents/GitHub/admin-app/node_modules/grpc/src/node/extension_binary/node-v67-linux-x64-glibc --napi_version=3 --node_abi_napi=napi' (1)
node-pre-gyp ERR! stack     at ChildProcess.<anonymous> (/media/binyamin/Seagate Expansion Drive/Documents/GitHub/admin-app/node_modules/grpc/node_modules/node-pre-gyp/lib/util/compile.js:83:29)
node-pre-gyp ERR! stack     at ChildProcess.emit (events.js:182:13)
node-pre-gyp ERR! stack     at maybeClose (internal/child_process.js:962:16)
node-pre-gyp ERR! stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:251:5)
node-pre-gyp ERR! System Linux 4.15.0-38-generic
node-pre-gyp ERR! command "/usr/local/bin/node" "/media/binyamin/Seagate Expansion Drive/Documents/GitHub/admin- 
app/node_modules/grpc/node_modules/.bin/node-pre-gyp" "install" "-- 
fallback-to-build" "--library=static_library"
node-pre-gyp ERR! cwd /media/binyamin/Seagate Expansion   
Drive/Documents/GitHub/admin-app/node_modules/grpc
node-pre-gyp ERR! node -v v11.0.0
node-pre-gyp ERR! node-pre-gyp -v v0.10.3
node-pre-gyp ERR! not ok 

0 个答案:

没有答案