我正在尝试在运行于RPi 4的Ubuntu 20.04中的Node Red中安装node-red-contrib-opcua-server节点。 它已经失败了几次。
我已经运行了更新/升级,并确保已安装nodejs。 我尝试使用命令行和Node Red GUI安装此节点。
以下是上次安装尝试的记录信息。 记录的信息对我来说并没有太多说明,所以我希望那里的Linux专家可以对成功安装此组件所需的内容有所了解。
2020-08-24T16:30:34.369Z Install : node-red-contrib-opcua-server 0.4.1
2020-08-24T16:30:34.445Z npm install --no-audit --no-update-notifier --no-fund --save --save-prefix="~" --production node-red-contrib-opcua-server@0.4.1
2020-08-24T16:30:49.312Z [out]
2020-08-24T16:30:49.312Z [out] > deasync@0.1.20 install /home/mikeallgood/.node-red/node_modules/deasync
2020-08-24T16:30:49.312Z [out] > node ./build.js
2020-08-24T16:30:49.312Z [out]
2020-08-24T16:30:52.039Z [err] gyp ERR! 2020-08-24T16:30:52.042Z [err] build error
2020-08-24T16:30:52.042Z [err] gyp
2020-08-24T16:30:52.044Z [err] ERR! stack Error: not found: make
2020-08-24T16:30:52.044Z [err] gyp ERR! stack
2020-08-24T16:30:52.045Z [err] at getNotFoundError (/usr/lib/node_modules/npm/node_modules/which/which.js:13:12)
2020-08-24T16:30:52.045Z [err] gyp ERR! stack
at F (/usr/lib/node_modules/npm/node_modules/which/which.js:68:19)
2020-08-24T16:30:52.045Z [err] gyp ERR! stack
at E (/usr/lib/node_modules/npm/node_modules/which/which.js:80:29)
2020-08-24T16:30:52.045Z [err] gyp ERR! stack
at /usr/lib/node_modules/npm/node_modules/which/which.js:89:16
2020-08-24T16:30:52.045Z [err] gyp ERR! stack
at /usr/lib/node_modules/npm/node_modules/isexe/index.js:42:5
2020-08-24T16:30:52.045Z [err] gyp ERR! stack
at /usr/lib/node_modules/npm/node_modules/isexe/mode.js:8:5
2020-08-24T16:30:52.045Z [err] gyp ERR! stack at FSReqCallback.oncomplete (fs.js:168:21)
2020-08-24T16:30:52.047Z [err] gyp ERR! System Linux 5.4.0-1015-raspi
2020-08-24T16:30:52.047Z [err] gyp ERR! 2020-08-24T16:30:52.047Z [err] command "/usr/bin/node" "/usr/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
2020-08-24T16:30:52.047Z [err] gyp ERR! cwd /home/mikeallgood/.node-red/node_modules/deasync
2020-08-24T16:30:52.047Z [err] gyp ERR! node -v
2020-08-24T16:30:52.048Z [err] v12.18.3
2020-08-24T16:30:52.048Z [err] gyp ERR! node-gyp -v v5.1.0
2020-08-24T16:30:52.048Z [err] gyp ERR! not ok
2020-08-24T16:30:52.065Z [err] Build failed
2020-08-24T16:30:53.421Z [err] npm
2020-08-24T16:30:53.422Z [err] WARN node-red-project@0.0.1 No repository field. 2020-08-24T16:30:53.464Z [err] npm
2020-08-24T16:30:53.464Z [err] WARN node-red-project@0.0.1 No license field.
2020-08-24T16:30:53.465Z [err]
2020-08-24T16:30:53.533Z [err] npm
2020-08-24T16:30:53.533Z [err] ERR! code ELIFECYCLE
2020-08-24T16:30:53.533Z [err] npm ERR! errno 1
2020-08-24T16:30:53.543Z [err] npm
2020-08-24T16:30:53.543Z [err] ERR! deasync@0.1.20 install: `node ./build.js`
2020-08-24T16:30:53.543Z [err] npm ERR! Exit status 1
2020-08-24T16:30:53.543Z [err] npm ERR!
2020-08-24T16:30:53.543Z [err] npm ERR! Failed at the deasync@0.1.20 install script.
2020-08-24T16:30:53.543Z [err] npm
2020-08-24T16:30:53.544Z [err] ERR! This is probably not a problem with npm. There is likely additional logging output above.
2020-08-24T16:30:53.580Z [err]
2020-08-24T16:30:53.581Z [err] npm ERR! A complete log of this run can be found in:
2020-08-24T16:30:53.581Z [err] npm ERR!
2020-08-24T16:30:53.581Z [err] /home/mikeallgood/.npm/_logs/2020-08-24T16_30_53_549Z-debug.log
2020-08-24T16:30:53.638Z rc=1
答案 0 :(得分:0)
看起来您缺少构建要安装的npmjs模块的本机组件所需的基本构建工具(例如make)。
您可能需要运行以下内容:
sudo apt-get install build-essential