简体   繁体   English

在Raspberry Pi上安装NPM bmp085模块时出错

[英]Error installing NPM bmp085 module on Raspberry Pi

I am trying to install the npm module bmp085 on a raspberry pi and I keep getting an error. 我试图在树莓派上安装npm模块bmp085,但我一直收到错误消息。 Node-Red is installed and works on the Pi. Node-Red已安装并在Pi上运行。 I do not know enough to understand what the error message is complaining about, I think it is complaining about versions but which version and of what I do not know. 我不太了解该错误消息在抱怨什么,我认为它在抱怨版本,但是哪个版本以及我不知道的内容。 Everything is up to date and the latest versions, as far as apt says. 据apt所说,一切都是最新的和最新版本。

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:269:23)
gyp ERR! stack     at ChildProcess.emit (events.js:110:17)
gyp ERR! stack     at Process.ChildProcess._handle.onexit (child_process.js:1074:12)
gyp ERR! System Linux 4.1.7+
gyp ERR! command "node" "/usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /usr/local/lib/node_modules/node-red-contrib-bmp085/node_modules/bmp085/node_modules/i2c
gyp ERR! node -v v0.12.6
gyp ERR! node-gyp -v v2.0.1
gyp ERR! not ok 
npm ERR! Linux 4.1.7+
npm ERR! argv "/usr/local/bin/node" "/usr/local/bin/npm" "install" "-g" "--unsafe-perm" "node-red-contrib-bmp085"
npm ERR! node v0.12.6
npm ERR! npm  v2.11.2
npm ERR! code ELIFECYCLE

npm ERR! i2c@0.1.8 install: `node-gyp rebuild`
npm ERR! Exit status 1
npm ERR! 
npm ERR! Failed at the i2c@0.1.8 install script 'node-gyp rebuild'.
npm ERR! This is most likely a problem with the i2c package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR!     node-gyp rebuild
npm ERR! You can get their info via:
npm ERR!     npm owner ls i2c
npm ERR! There is likely additional logging output above.

npm ERR! Please include the following file with any support request:
npm ERR!     /var/rpi/node-red/npm-debug.log

I've looked at the log mentioned, I do not understand it either. 我看了提到的日志,我也不明白。

As the error says this is a problem building the i2c module. 如错误所示,这是构建i2c模块的问题。

Since you are running node 0.12 it may be that the bmp085 module needs to be updated to use a newer version of the i2c module as the Github page for the i2c modules suggests that you need version greater than 0.1.8 for newer than node 0.11 由于您正在运行节点0.12,可能是bmp085模块需要更新以使用i2c模块的较新版本,因为i2c模块的Github页面表明您需要比0.11更高的版本大于0.1.8。

Latest version at this time is 0.2.0 目前最新版本是0.2.0

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM