cheery / node-udev

Bindings to libudev
35 stars 31 forks source link

Error building in Raspberry Pi (ARMv6) #1

Closed fauria closed 11 years ago

fauria commented 11 years ago

OS: Debian GNU/Linux 7 (Raspbian) libudev: libudev0:armhf 175-7.2 nodejs: 0.6.19~dfsg1-6 npm: 1.1.4~dfsg-2

npm install udev

make: Entering directory `/root/gopropi/node_modules/udev/build' CXX(target) Release/obj.target/udev/udev.o ../udev.cc:48:33: error: ‘uv_poll_t’ has not been declared ../udev.cc:94:5: error: ‘uv_poll_t’ does not name a type ../udev.cc: In static member function ‘static void Monitor::on_handleevent(int, int, int)’: ../udev.cc:50:51: error: request for member ‘data’ in ‘_ handle’, which is of non-class type ‘int’ ../udev.cc: In static member function ‘static v8::Handlev8::Value Monitor::New(const v8::Arguments&)’: ../udev.cc:71:9: error: ‘uv_poll_t’ was not declared in this scope ../udev.cc:71:20: error: ‘handle’ was not declared in this scope ../udev.cc:76:14: error: ‘class Monitor’ has no member named ‘poll_handle’ ../udev.cc:76:41: error: expected type-specifier before ‘uv_poll_t’ ../udev.cc:76:41: error: expected ‘;’ before ‘uv_poll_t’ ../udev.cc:82:46: error: ‘class Monitor’ has no member named ‘poll_handle’ ../udev.cc:82:66: error: ‘uv_poll_init’ was not declared in this scope ../udev.cc:83:28: error: ‘class Monitor’ has no member named ‘poll_handle’ ../udev.cc:83:41: error: ‘UV_READABLE’ was not declared in this scope ../udev.cc:83:69: error: ‘uv_poll_start’ was not declared in this scope ../udev.cc: In static member function ‘static v8::Handlev8::Value Monitor::Close(const v8::Arguments&)’: ../udev.cc:89:27: error: ‘class Monitor’ has no member named ‘poll_handle’ ../udev.cc:89:38: error: ‘uv_poll_stop’ was not declared in this scope ../udev.cc:90:37: error: ‘class Monitor’ has no member named ‘poll_handle’ make: *\ [Release/obj.target/udev/udev.o] Error 1

cheery commented 11 years ago

Things might have changed a bit since I made this library. I'm going to update and boot up my PI to see what's wrong.

cheery commented 11 years ago

I studied and read around a bit. It seems raspberry pi still comes with v0.6.x nodejs, which is just outdated enough to not provide what my library needs. Right now I'm compiling v0.10.16 to see whether the library works properly there.

I'm going to make sure you're able to run my library.

cheery commented 11 years ago

How to install latest (v0.10.16) nodejs on raspberry pi ARM:

wget http://nodejs.org/dist/v0.10.16/node-v0.10.16-linux-arm-pi.tar.gz
tar -xf node-v0.10.16-linux-arm-pi.tar.gz
cd node-v0.10.16-linux-arm-pi/
cp -r bin lib share /usr/local/

After that you are able to install udev without trouble. I'll yet make sure nobody attempts to install it on outdated system.