【问题标题】:npm failing (gyp error and install script error) during npm install homebridge on debian在 debian 上 npm install homebridge 期间 npm 失败(gyp 错误和安装脚本错误)
【发布时间】:2016-03-11 22:13:18
【问题描述】:

我正在尝试使用“npm install -g homebridge”在我的 Dragonboard 410c 上的 debian 上安装 homebridge 软件包。但是,我一直遇到下面粘贴的以下错误。我已经安装了 nodejs-legacy。

是否有解决此问题的方法,或者是否有其他方法可以在不使用 npm 的情况下下载和安装包及其依赖项?

npm WARN excluding symbolic link utils/ncov -> lib/ncov.js
\

curve25519@1.1.0 install /usr/local/lib/node_modules/homebridge/node_modules/hap-nodejs/node_modules/curve25519
node-gyp rebuild
(node) child_process: options.customFds option is deprecated. Use options.stdio instead.
make: Entering directory '/usr/local/lib/node_modules/homebridge/node_modules/hap-nodejs/node_modules/curve25519/build'
CXX(target) Release/obj.target/curve/node_curve.o
SOLINK_MODULE(target) Release/obj.target/curve.node
COPY Release/curve.node
make: Leaving directory '/usr/local/lib/node_modules/homebridge/node_modules/hap-nodejs/node_modules/curve25519/build'
npm WARN excluding symbolic link utils/ncov -> lib/ncov.js

bignum@0.11.0 install /usr/local/lib/node_modules/homebridge/node_modules/hap-nodejs/node_modules/srp/node_modules/bignum
node-gyp configure build
(node) child_process: options.customFds option is deprecated. Use options.stdio instead.
gyp: Undefined variable openssl_config_path in binding.gyp
gyp ERR! configure error
gyp ERR! stack Error: gyp failed with exit code: 1
gyp ERR! stack at ChildProcess.onCpExit (/usr/share/node-gyp/lib/configure.js:344:16)
gyp ERR! stack at emitTwo (events.js:87:13)
gyp ERR! stack at ChildProcess.emit (events.js:172:7)
gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:200:12)
gyp ERR! System Linux 4.4.0-linaro-lt-qcom
gyp ERR! command "/usr/bin/nodejs" "/usr/bin/node-gyp" "configure" "build"
gyp ERR! cwd /usr/local/lib/node_modules/homebridge/node_modules/hap-nodejs/node_modules/srp/node_modules/bignum
gyp ERR! node -v v4.2.2
gyp ERR! node-gyp -v v0.12.2
gyp ERR! not ok
npm WARN This failure might be due to the use of legacy binary "node"
npm WARN For further explanations, please read
/usr/share/doc/nodejs/README.Debian

mdns@2.2.11 install /usr/local/lib/node_modules/homebridge/node_modules/hap-nodejs/node_modules/mdns
node-gyp rebuild
path.js:424
var path = (i >= 0) ? arguments[i] : process.cwd();
^

Error: ENOENT: no such file or directory, uv_cwd
at Error (native)
at Object.posix.resolve (path.js:424:50)
at Function.Module._resolveLookupPaths (module.js:249:17)
at Function.Module._resolveFilename (module.js:327:31)
at Function.Module._load (module.js:287:25)
at Module.require (module.js:366:17)
at require (module.js:385:17)
at Object. (/usr/share/node-gyp/bin/node-gyp.js:13:11)
at Module._compile (module.js:435:26)
at Object.Module._extensions..js (module.js:442:10)
npm ERR! bignum@0.11.0 install: node-gyp configure build
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the bignum@0.11.0 install script.
npm ERR! This is most likely a problem with the bignum package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! node-gyp configure build
npm ERR! You can get their info via:
npm ERR! npm owner ls bignum
npm ERR! There is likely additional logging output above.
npm ERR! System Linux 4.4.0-linaro-lt-qcom
npm ERR! command "/usr/bin/nodejs" "/usr/bin/npm" "install" "-g" "homebridge"
npm ERR! cwd /home/linaro
npm ERR! node -v v4.2.2
npm ERR! npm -v 1.4.21
npm ERR! code ELIFECYCLE
npm WARN This failure might be due to the use of legacy binary "node"
npm WARN For further explanations, please read
/usr/share/doc/nodejs/README.Debian

ed25519@0.0.3 install /usr/local/lib/node_modules/homebridge/node_modules/hap-nodejs/node_modules/ed25519
node-gyp rebuild

【问题讨论】:

    标签: node.js npm debian node-gyp npm-install


    【解决方案1】:

    我建议从不同的目录尝试您的命令。我试图在

    中安装特定模块

    /Users/my_username/.nvm/versions/node/v8.11.3/lib/node_modules/

    它以非常相似的错误失败。我搬到了

    /Users/my_username/.nvm/versions/

    (意外)运行npm install,它现在正在工作。

    在这个过程中我还发现了npm doctor,这可能会帮助你找到问题的根源。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2022-07-22
      • 1970-01-01
      • 2022-01-15
      • 2018-08-27
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2015-12-07
      相关资源
      最近更新 更多