MetaWear-SDK-JavaScript
MetaWear-SDK-JavaScript copied to clipboard
installation fails on node 8.10
relevant looking bits of error below:
node-pre-gyp WARN Using request for node-pre-gyp https download
node-pre-gyp WARN Tried to download(404): https://github.com/tessel/node-usb/releases/download/1.5.0/usb_bindings-v1.5.0-node-v57-linux-x64.tar.gz
node-pre-gyp WARN Pre-built binaries not found for [email protected] and [email protected] (node-v57 ABI, glibc) (falling back to source compile with node-gyp)
........
../libusb/libusb/os/linux_udev.c:40:10: fatal error: libudev.h: No such file or directory
#include <libudev.h>
^~~~~~~~~~~
compilation terminated.
compilation terminated.
libusb.target.mk:128: recipe for target 'Release/obj.target/libusb/libusb/libusb/os/linux_udev.o' failed
make: *** [Release/obj.target/libusb/libusb/libusb/os/linux_udev.o] Error 1
make: Leaving directory '/home/jmej/projects/MetaWear-SDK-JavaScript/node_modules/usb/build'
gyp ERR! build error
gyp ERR! stack Error: `make` failed with exit code: 2
gyp ERR! stack at ChildProcess.onExit (/usr/share/npm/node_modules/node-gyp/lib/build.js:276:23)
gyp ERR! stack at emitTwo (events.js:126:13)
gyp ERR! stack at ChildProcess.emit (events.js:214:7)
gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:198:12)
gyp ERR! System Linux 4.15.0-34-generic
gyp ERR! command "/usr/bin/node" "/usr/share/npm/node_modules/node-gyp/bin/node-gyp.js" "build" "--fallback-to-build" "--module=/home/jmej/projects/MetaWear-SDK-JavaScript/node_modules/usb/src/binding/usb_bindings.node" "--module_name=usb_bindings" "--module_path=/home/jmej/projects/MetaWear-SDK-JavaScript/node_modules/usb/src/binding" "--napi_version=1" "--node_abi_napi=napi" "--napi_build_version=0" "--node_napi_label=node-v57"
gyp ERR! cwd /home/jmej/projects/MetaWear-SDK-JavaScript/node_modules/usb
gyp ERR! node -v v8.10.0
gyp ERR! node-gyp -v v3.2.1
gyp ERR! not ok
node-pre-gyp ERR! build error
node-pre-gyp ERR! stack Error: Failed to execute '/usr/bin/node /usr/share/npm/node_modules/node-gyp/bin/node-gyp.js build --fallback-to-build --module=/home/jmej/projects/MetaWear-SDK-JavaScript/node_modules/usb/src/binding/usb_bindings.node --module_name=usb_bindings --module_path=/home/jmej/projects/MetaWear-SDK-JavaScript/node_modules/usb/src/binding --napi_version=1 --node_abi_napi=napi --napi_build_version=0 --node_napi_label=node-v57' (1)
node-pre-gyp ERR! stack at ChildProcess.<anonymous> (/home/jmej/projects/MetaWear-SDK-JavaScript/node_modules/node-pre-gyp/lib/util/compile.js:83:29)
node-pre-gyp ERR! stack at emitTwo (events.js:126:13)
node-pre-gyp ERR! stack at ChildProcess.emit (events.js:214:7)
node-pre-gyp ERR! stack at maybeClose (internal/child_process.js:925:16)
node-pre-gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:209:5)
node-pre-gyp ERR! System Linux 4.15.0-34-generic
node-pre-gyp ERR! command "/usr/bin/node" "/home/jmej/projects/MetaWear-SDK-JavaScript/node_modules/.bin/node-pre-gyp" "install" "--fallback-to-build"
node-pre-gyp ERR! cwd /home/jmej/projects/MetaWear-SDK-JavaScript/node_modules/usb
node-pre-gyp ERR! node -v v8.10.0
node-pre-gyp ERR! node-pre-gyp -v v0.11.0
node-pre-gyp ERR! not ok
Failed to execute '/usr/bin/node /usr/share/npm/node_modules/node-gyp/bin/node-gyp.js build --fallback-to-build --module=/home/jmej/projects/MetaWear-SDK-JavaScript/node_modules/usb/src/binding/usb_bindings.node --module_name=usb_bindings --module_path=/home/jmej/projects/MetaWear-SDK-JavaScript/node_modules/usb/src/binding --napi_version=1 --node_abi_napi=napi --napi_build_version=0 --node_napi_label=node-v57' (1)
npm WARN install:[email protected] [email protected] install: `node-pre-gyp install --fallback-to-build`
npm WARN install:[email protected] Exit status 1
> [email protected] install /home/jmej/projects/MetaWear-SDK-JavaScript
> make OPT_FLAGS=-Wno-strict-aliasing -C MetaWear-SDK-Cpp/ -j
make: Entering directory '/home/jmej/projects/MetaWear-SDK-JavaScript/MetaWear-SDK-Cpp'
make: *** No targets specified and no makefile found. Stop.
make: Leaving directory '/home/jmej/projects/MetaWear-SDK-JavaScript/MetaWear-SDK-Cpp'
npm WARN optional Skipping failed optional dependency /noble/xpc-connection:
npm WARN notsup Not compatible with your operating system or architecture: [email protected]
npm ERR! Linux 4.15.0-34-generic
npm ERR! argv "/usr/bin/node" "/usr/bin/npm" "install"
npm ERR! node v8.10.0
npm ERR! npm v3.5.2
npm ERR! code ELIFECYCLE
npm ERR! [email protected] install: `make OPT_FLAGS=-Wno-strict-aliasing -C MetaWear-SDK-Cpp/ -j`
npm ERR! Exit status 2
npm ERR!
npm ERR! Failed at the [email protected] install script 'make OPT_FLAGS=-Wno-strict-aliasing -C MetaWear-SDK-Cpp/ -j'.
npm ERR! Make sure you have the latest version of node.js and npm installed.
npm ERR! If you do, this is most likely a problem with the metawear package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! make OPT_FLAGS=-Wno-strict-aliasing -C MetaWear-SDK-Cpp/ -j
npm ERR! You can get information on how to open an issue for this project with:
npm ERR! npm bugs metawear
npm ERR! Or if that isn't available, you can get their info via:
npm ERR! npm owner ls metawear
npm ERR! There is likely additional logging output above.
I got a little bit further by running
sudo apt-get install libusb-1.0-0-dev
sudo apt-get install libudev-dev
But still getting hung up on this:
npm WARN optional Skipping failed optional dependency /noble/xpc-connection:
npm WARN notsup Not compatible with your operating system or architecture: [email protected]
npm ERR! Linux 4.15.0-34-generic
npm ERR! argv "/usr/bin/node" "/usr/bin/npm" "install"
npm ERR! node v8.10.0
npm ERR! npm v3.5.2
npm ERR! code ELIFECYCLE
npm ERR! [email protected] install: `make OPT_FLAGS=-Wno-strict-aliasing -C MetaWear-SDK-Cpp/ -j`
npm ERR! Exit status 2
npm ERR!
npm ERR! Failed at the [email protected] install script 'make OPT_FLAGS=-Wno-strict-aliasing -C MetaWear-SDK-Cpp/ -j'.
Install the package distributed on npmjs.
Thanks! Yep that did the trick!