OptimalBits / node_acl

Access control lists for node applications
2.62k stars 371 forks source link

Install fails... node-gyp possible culprit? #150

Closed davidcushing closed 9 years ago

davidcushing commented 9 years ago

I've been trying to install node_acl into an existing express project. Can't get this to install at all... Have tried installing acl globally too, that doesn't work either. Tried rolling back to an older version of npm - that didn't work. Any ideas at all?


npm install acl  --save
npm WARN install Couldn't install optional dependency: Unsupported
npm WARN install Couldn't install optional dependency: Unsupported

> bufferutil@1.1.0 install /home/david/applications/sibos/afsg/node_modules/bufferutil
> node-gyp rebuild

make: Entering directory '/home/david/applications/sibos/afsg/node_modules/bufferutil/build'
  CXX(target) Release/obj.target/bufferutil/src/bufferutil.o
  SOLINK_MODULE(target) Release/obj.target/bufferutil.node
  COPY Release/bufferutil.node
make: Leaving directory '/home/david/applications/sibos/afsg/node_modules/bufferutil/build'

> kerberos@0.0.14 install /home/david/applications/sibos/afsg/node_modules/kerberos
> (node-gyp rebuild) || (exit 0)

make: Entering directory '/home/david/applications/sibos/afsg/node_modules/kerberos/build'
  CXX(target) Release/obj.target/kerberos/lib/kerberos.o
In file included from ../lib/kerberos.cc:1:0:
../lib/kerberos.h:5:27: fatal error: gssapi/gssapi.h: No such file or directory
 #include <gssapi/gssapi.h>
                           ^
compilation terminated.
kerberos.target.mk:94: recipe for target 'Release/obj.target/kerberos/lib/kerberos.o' failed
make: *** [Release/obj.target/kerberos/lib/kerberos.o] Error 1
make: Leaving directory '/home/david/applications/sibos/afsg/node_modules/kerberos/build'
gyp ERR! build error 
gyp ERR! stack Error: `make` failed with exit code: 2
gyp ERR! stack     at ChildProcess.onExit (/usr/local/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:270:23)
gyp ERR! stack     at ChildProcess.emit (events.js:110:17)
gyp ERR! stack     at Process.ChildProcess._handle.onexit (child_process.js:1074:12)
gyp ERR! System Linux 3.16.0-4-amd64
gyp ERR! command "node" "/usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /home/david/applications/sibos/afsg/node_modules/kerberos
gyp ERR! node -v v0.12.7
gyp ERR! node-gyp -v v3.0.1
gyp ERR! not ok 

> utf-8-validate@1.1.0 install /home/david/applications/sibos/afsg/node_modules/utf-8-validate
> node-gyp rebuild

make: Entering directory '/home/david/applications/sibos/afsg/node_modules/utf-8-validate/build'
  CXX(target) Release/obj.target/validation/src/validation.o
  SOLINK_MODULE(target) Release/obj.target/validation.node
  COPY Release/validation.node
make: Leaving directory '/home/david/applications/sibos/afsg/node_modules/utf-8-validate/build'
async@1.4.2 node_modules/acl/node_modules/async -> node_modules/async
bluebird@2.10.0 node_modules/acl/node_modules/bluebird -> node_modules/bluebird
bson@0.4.12 node_modules/acl/node_modules/mongodb/node_modules/mongodb-core/node_modules/bson -> node_modules/bson
core-util-is@1.0.1 node_modules/acl/node_modules/mongodb/node_modules/readable-stream/node_modules/core-util-is -> node_modules/core-util-is
es6-promise@2.1.1 node_modules/acl/node_modules/mongodb/node_modules/es6-promise -> node_modules/es6-promise
inherits@2.0.1 node_modules/acl/node_modules/mongodb/node_modules/readable-stream/node_modules/inherits -> node_modules/inherits
isarray@0.0.1 node_modules/acl/node_modules/mongodb/node_modules/readable-stream/node_modules/isarray -> node_modules/isarray
nan@2.0.9 node_modules/acl/node_modules/mongodb/node_modules/mongodb-core/node_modules/kerberos/node_modules/nan -> node_modules/nan
kerberos@0.0.14 node_modules/acl/node_modules/mongodb/node_modules/mongodb-core/node_modules/kerberos -> node_modules/kerberos
mongodb-core@1.2.12 node_modules/acl/node_modules/mongodb/node_modules/mongodb-core -> node_modules/mongodb-core
redis@1.0.0 node_modules/acl/node_modules/redis -> node_modules/redis
string_decoder@0.10.31 node_modules/acl/node_modules/mongodb/node_modules/readable-stream/node_modules/string_decoder -> node_modules/string_decoder
readable-stream@1.0.31 node_modules/acl/node_modules/mongodb/node_modules/readable-stream -> node_modules/readable-stream
mongodb@2.0.43 node_modules/acl/node_modules/mongodb -> node_modules/mongodb
davidcushing commented 9 years ago

Also:


sudo npm i acl -g

> kerberos@0.0.14 install /usr/local/lib/node_modules/acl/node_modules/kerberos
> (node-gyp rebuild) || (exit 0)

gyp WARN EACCES user "root" does not have permission to access the dev dir "/root/.node-gyp/0.12.7"
gyp WARN EACCES attempting to reinstall using temporary dev dir "/usr/local/lib/node_modules/acl/node_modules/kerberos/.node-gyp"
make: Entering directory '/usr/local/lib/node_modules/acl/node_modules/kerberos/build'
  CXX(target) Release/obj.target/kerberos/lib/kerberos.o
In file included from ../lib/kerberos.cc:1:0:
../lib/kerberos.h:5:27: fatal error: gssapi/gssapi.h: No such file or directory
 #include <gssapi/gssapi.h>
                           ^
compilation terminated.
kerberos.target.mk:94: recipe for target 'Release/obj.target/kerberos/lib/kerberos.o' failed
make: *** [Release/obj.target/kerberos/lib/kerberos.o] Error 1
make: Leaving directory '/usr/local/lib/node_modules/acl/node_modules/kerberos/build'
gyp ERR! build error 
gyp ERR! stack Error: `make` failed with exit code: 2
gyp ERR! stack     at ChildProcess.onExit (/usr/local/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:270:23)
gyp ERR! stack     at ChildProcess.emit (events.js:110:17)
gyp ERR! stack     at Process.ChildProcess._handle.onexit (child_process.js:1074:12)
gyp ERR! System Linux 3.16.0-4-amd64
gyp ERR! command "node" "/usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /usr/local/lib/node_modules/acl/node_modules/kerberos
gyp ERR! node -v v0.12.7
gyp ERR! node-gyp -v v3.0.1
gyp ERR! not ok 

> kerberos@0.0.14 install /usr/local/lib/node_modules/acl/node_modules/kerberos
> (node-gyp rebuild) || (exit 0)

gyp WARN EACCES user "root" does not have permission to access the dev dir "/root/.node-gyp/0.12.7"
gyp WARN EACCES attempting to reinstall using temporary dev dir "/usr/local/lib/node_modules/acl/node_modules/kerberos/.node-gyp"
make: Entering directory '/usr/local/lib/node_modules/acl/node_modules/kerberos/build'
  CXX(target) Release/obj.target/kerberos/lib/kerberos.o
In file included from ../lib/kerberos.cc:1:0:
../lib/kerberos.h:5:27: fatal error: gssapi/gssapi.h: No such file or directory
 #include <gssapi/gssapi.h>
                           ^
compilation terminated.
kerberos.target.mk:94: recipe for target 'Release/obj.target/kerberos/lib/kerberos.o' failed
make: *** [Release/obj.target/kerberos/lib/kerberos.o] Error 1
make: Leaving directory '/usr/local/lib/node_modules/acl/node_modules/kerberos/build'
gyp ERR! build error 
gyp ERR! stack Error: `make` failed with exit code: 2
gyp ERR! stack     at ChildProcess.onExit (/usr/local/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:270:23)
gyp ERR! stack     at ChildProcess.emit (events.js:110:17)
gyp ERR! stack     at Process.ChildProcess._handle.onexit (child_process.js:1074:12)
gyp ERR! System Linux 3.16.0-4-amd64
gyp ERR! command "node" "/usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /usr/local/lib/node_modules/acl/node_modules/kerberos
gyp ERR! node -v v0.12.7
gyp ERR! node-gyp -v v3.0.1
gyp ERR! not ok 
bson@0.4.12 node_modules/acl/node_modules/mongodb/node_modules/mongodb-core/node_modules/bson -> node_modules/acl/node_modules/bson
core-util-is@1.0.1 node_modules/acl/node_modules/mongodb/node_modules/readable-stream/node_modules/core-util-is -> node_modules/acl/node_modules/core-util-is
es6-promise@2.1.1 node_modules/acl/node_modules/mongodb/node_modules/es6-promise -> node_modules/acl/node_modules/es6-promise
inherits@2.0.1 node_modules/acl/node_modules/mongodb/node_modules/readable-stream/node_modules/inherits -> node_modules/acl/node_modules/inherits
isarray@0.0.1 node_modules/acl/node_modules/mongodb/node_modules/readable-stream/node_modules/isarray -> node_modules/acl/node_modules/isarray
nan@2.0.9 node_modules/acl/node_modules/mongodb/node_modules/mongodb-core/node_modules/kerberos/node_modules/nan -> node_modules/acl/node_modules/nan
kerberos@0.0.14 node_modules/acl/node_modules/mongodb/node_modules/mongodb-core/node_modules/kerberos -> node_modules/acl/node_modules/kerberos
mongodb-core@1.2.12 node_modules/acl/node_modules/mongodb/node_modules/mongodb-core -> node_modules/acl/node_modules/mongodb-core
string_decoder@0.10.31 node_modules/acl/node_modules/mongodb/node_modules/readable-stream/node_modules/string_decoder -> node_modules/acl/node_modules/string_decoder
readable-stream@1.0.31 node_modules/acl/node_modules/mongodb/node_modules/readable-stream -> node_modules/acl/node_modules/readable-stream
/usr/local/lib
`-- acl@0.4.9 
ryardley commented 9 years ago

I can confirm I am getting this same error too. acl@0.4.9. Installing on Ubuntu 14.04.3 within vagrant.

sachiniiit commented 9 years ago

try with installing keberos. It worked for me sudo apt-get install libkrb5-dev

stepanh commented 9 years ago

thanks @sachiniiit that worked!

jbiffis commented 9 years ago

Worked X2 here. Thanks @sachiniiit

thicolares commented 9 years ago

thanks @sachiniiit . worked here as well.

rayjlim commented 9 years ago

worked for me too.

jonasborges commented 9 years ago

:+1: @sachiniiit !!

woolfi182 commented 9 years ago

thanks @sachiniiit . it's great

mursalat commented 9 years ago

@sachiniiit thanks, worked for me too

Pumych commented 9 years ago

Works great. Thank you.

davidcushing commented 9 years ago

@sachiniiit thank you for solving it - and sorry for not thanking you sooner!

iusting20 commented 9 years ago

@sachiniiit It worked, thanks a lot, been struggling with this for a while.

issmirnov commented 9 years ago

+3 @sachiniiit - Spent a fair bit of time recompiling node-gyp, exploring deps and more. Thanks!!

nabulaer commented 9 years ago

worked for me , thanks .

ArtemMaximum commented 8 years ago

not working on CentOS 6.7 any ideas?

JSONRice commented 8 years ago

@ArtemMaximum See: http://stackoverflow.com/questions/26768082/npm-install-mongoose-fails-kerberos-and-bson-errors

What worked for me was making node-gyp global:

sudo npm install -g node-gyp

Run as sudo. If you don't have root privileges then talk to your sysadmin and tell him to do it or add you to the sudo list (visudo).

After node-gyp installs run:

npm install;npm install --dev