Hi, could you help me to install the serial port on node-red?
I'm trying to install it using Node-Red 1.29 from the palette and I have an error.
Error:
2022-07-24T22:01:28.311Z npm install --no-audit --no-update-notifier --no-fund --save --save-prefix=~ --production node-red-node-serialport@1.0.1
2022-07-24T22:02:22.730Z [out]
2022-07-24T22:02:22.730Z [out] > @serialport/bindings-cpp@10.7.0 install /root/.node-red/node_modules/@serialport/bindings-cpp
2022-07-24T22:02:22.730Z [out] > node-gyp-build
2022-07-24T22:02:22.730Z [out]
2022-07-24T22:03:08.526Z [err] gyp
2022-07-24T22:03:08.540Z [err] ERR! UNCAUGHT EXCEPTION
2022-07-24T22:03:08.542Z [err] gyp
2022-07-24T22:03:08.544Z [err]
2022-07-24T22:03:08.546Z [err] ERR!
2022-07-24T22:03:08.550Z [err] stack TypeError: Object.fromEntries is not a function
2022-07-24T22:03:08.552Z [err] gyp
2022-07-24T22:03:08.556Z [err] ERR! stack at Object.<anonymous> (/usr/lib/node_modules/node-gyp/node_modules/@npmcli/fs/lib/fs.js:6:23)
2022-07-24T22:03:08.556Z [err] gyp
2022-07-24T22:03:08.558Z [err]
2022-07-24T22:03:08.560Z [err] ERR!
2022-07-24T22:03:08.570Z [err] stack at Module._compile (module.js:652:30)
2022-07-24T22:03:08.570Z [err] gyp ERR! stack at Object.Module._extensions..js (module.js:663:10)
2022-07-24T22:03:08.570Z [err] gyp ERR! stack at Module.load (module.js:565:32)
2022-07-24T22:03:08.570Z [err] gyp
2022-07-24T22:03:08.572Z [err]
2022-07-24T22:03:08.574Z [err] ERR!
2022-07-24T22:03:08.576Z [err]
2022-07-24T22:03:08.591Z [err] stack at tryModuleLoad (module.js:505:12)
2022-07-24T22:03:08.591Z [err] gyp ERR! stack at Function.Module._load (module.js:497:3)
2022-07-24T22:03:08.591Z [err] gyp ERR! stack at Module.require (module.js:596:17)
2022-07-24T22:03:08.591Z [err] gyp ERR! stack at require (internal/module.js:11:18)
2022-07-24T22:03:08.593Z [err] gyp
2022-07-24T22:03:08.595Z [err]
2022-07-24T22:03:08.598Z [err] ERR!
2022-07-24T22:03:08.601Z [err] stack
2022-07-24T22:03:08.610Z [err] at Object.<anonymous> (/usr/lib/node_modules/node-gyp/node_modules/@npmcli/fs/lib/index.js:2:6)
2022-07-24T22:03:08.610Z [err] gyp ERR! stack at Module._compile (module.js:652:30)
2022-07-24T22:03:08.610Z [err] gyp
2022-07-24T22:03:08.612Z [err] ERR!
2022-07-24T22:03:08.614Z [err]
2022-07-24T22:03:08.616Z [err] System
2022-07-24T22:03:08.630Z [err] Linux 4.14.81
2022-07-24T22:03:08.630Z [err] gyp ERR! command "/usr/bin/node" "/usr/lib/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
2022-07-24T22:03:08.630Z [err] gyp ERR! cwd /root/.node-red/node_modules/@serialport/bindings-cpp
2022-07-24T22:03:08.630Z [err] gyp ERR! node -v v8.10.0
2022-07-24T22:03:08.630Z [err] gyp
2022-07-24T22:03:08.632Z [err]
2022-07-24T22:03:08.634Z [err] ERR!
2022-07-24T22:03:08.636Z [err]
2022-07-24T22:03:08.646Z [err] node-gyp -v v9.1.0
2022-07-24T22:03:08.646Z [err] gyp ERR! Node-gyp failed to build your package.
2022-07-24T22:03:08.646Z [err] gyp ERR! Try to update npm and/or node-gyp and if it does not help file an issue with the package author.
2022-07-24T22:03:10.401Z [err] npm
2022-07-24T22:03:10.403Z [err]
2022-07-24T22:03:10.406Z [err] ERR!
2022-07-24T22:03:10.410Z [err] code ELIFECYCLE
2022-07-24T22:03:10.415Z [err] npm
2022-07-24T22:03:10.417Z [err]
2022-07-24T22:03:10.420Z [err] ERR!
2022-07-24T22:03:10.422Z [err]
2022-07-24T22:03:10.430Z [err] errno 7
2022-07-24T22:03:10.446Z [err] npm
2022-07-24T22:03:10.449Z [err]
2022-07-24T22:03:10.451Z [err] ERR!
2022-07-24T22:03:10.460Z [err] @serialport/bindings-cpp@10.7.0 install: node-gyp-build
2022-07-24T22:03:10.460Z [err] npm ERR! Exit status 7
2022-07-24T22:03:10.470Z [err] npm ERR!
2022-07-24T22:03:10.470Z [err] npm ERR! Failed at the @serialport/bindings-cpp@10.7.0 install script.
2022-07-24T22:03:10.470Z [err] npm ERR!
2022-07-24T22:03:10.472Z [err] This is probably not a problem with npm. There is likely additional logging output above.
2022-07-24T22:03:10.593Z [err]
2022-07-24T22:03:10.597Z [err] npm
2022-07-24T22:03:10.602Z [err] ERR! A complete log of this run can be found in:
2022-07-24T22:03:10.602Z [err] npm ERR! /.npm/_logs/2022-07-24T22_03_10_537Z-debug.log
2022-07-24T22:03:10.644Z rc=7