Can't get serialport library running

6 views
Skip to first unread message

m...@mattbrailsford.com

unread,
Mar 13, 2014, 5:38:47 PM3/13/14
to node-...@googlegroups.com
Hi guys,

I'm trying to get the node serialport library up an running inside node-webkit. I've spent the last hour getting it downloaded and compiled and think I've just about managed it (the build succeeds). I've downloaded the source and compiled it using nw-gyp, so I believe it should be good to go right?

I'm not quite sure how I install it within my solition from here though. I've dropped the source folder in the node_modules folder and called require("serialport"), but whenever I run the app, I just get an error "Cannot find module 'bindings'"

Can anyone point me in the right direction on how to get the module installed now that I've compiled it? and how to fix this error?

Many thanks

Matt

m...@mattbrailsford.com

unread,
Mar 13, 2014, 5:55:32 PM3/13/14
to node-...@googlegroups.com
Typical, as soon as I post, I find out the answer.

So seems because I downloaded and built by hand, none of the serialport dependencies downloaded. I ran "npm install" inside the source code folder, then rebuilt the module and everything worked (needed to make sure the source code was in the node_modules folder in a sub folder named "serialport").

Hope this maybe helps someone else

Matt
Reply all
Reply to author
Forward
0 new messages