stf install fail ,please help me

Created on 21 Aug 2015  ·  6Comments  ·  Source: openstf/stf

hi:
i am interested in your program,and try to build the progrom,i follow the stuep,and install these dependencies,but an last i meet a problem,the tips is that:
jcdeMacBook-Pro:zeromq-4.1.2 jc$ sudo npm install -g stf
Password:

[email protected] install /usr/local/lib/node_modules/stf/node_modules/ws/node_modules/utf-8-validate
node-gyp rebuild

/usr/local/lib/node_modules/npm/bin/node-gyp-bin/node-gyp: line 3: node: command not found

[email protected] install /usr/local/lib/node_modules/stf/node_modules/ws/node_modules/bufferutil
node-gyp rebuild

/usr/local/lib/node_modules/npm/bin/node-gyp-bin/node-gyp: line 3: node: command not found
npm WARN optional dep failed, continuing [email protected]
npm WARN optional dep failed, continuing [email protected]

[email protected] install /usr/local/lib/node_modules/stf/node_modules/ldapjs/node_modules/dtrace-provider
node scripts/install.js

sh: node: command not found
npm WARN optional dep failed, continuing [email protected]

[email protected] install /usr/local/lib/node_modules/stf/node_modules/zmq
node-gyp rebuild

/usr/local/lib/node_modules/npm/bin/node-gyp-bin/node-gyp: line 3: node: command not found
npm ERR! Darwin 14.3.0
npm ERR! argv "node" "/usr/local/bin/npm" "install" "-g" "stf"
npm ERR! node v0.12.7
npm ERR! npm v2.11.3
npm ERR! file sh
npm ERR! code ELIFECYCLE
npm ERR! errno ENOENT
npm ERR! syscall spawn

npm ERR! [email protected] install: node-gyp rebuild
npm ERR! spawn ENOENT
npm ERR!
npm ERR! Failed at the [email protected] install script 'node-gyp rebuild'.
npm ERR! This is most likely a problem with the zmq package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! node-gyp rebuild
npm ERR! You can get their info via:
npm ERR! npm owner ls zmq
npm ERR! There is likely additional logging output above.

npm ERR! Please include the following file with any support request:
npm ERR! /soft/zeromq-4.1.2/npm-debug.log

pleae help me
“npm ERR! Failed at the [email protected] install script 'node-gyp rebuild'.
npm ERR! This is most likely a problem with the zmq package,
npm ERR! not with npm itself.” ,may be this is important

Most helpful comment

@sorccu @jonalmeida
thank you
i got
the problem is a permissions issue with node,
to use "sudo npm install --unsafe-perm --verbose -g stf " instand of "sudo npm install -g stf" ,the problem is solve

All 6 comments

error:/usr/local/lib/node_modules/npm/bin/node-gyp-bin/node-gyp: line 3: node: command not found
i open the file, :

!/usr/bin/env sh

if [ "x$npm_config_node_gyp" = "x" ]; then
node "dirname "$0"/../../node_modules/node-gyp/bin/node-gyp.js" "$@"
else
"$npm_config_node_gyp" "$@"
fi

i have install node ,and
jcdeMacBook-Pro:~ jc$ node -v
v0.12.7
jcdeMacBook-Pro:~ jc$

i am puzzled

Maybe your sudo is configured to ignore your PATH. Try running sudo node -v and see if it works or not. If not, you need to find a way to fix it.

@jc5055 This usually happens when there's a permissions issue with node and using the global flag. There are some other possibilities for it as well. See: https://github.com/nodejs/node-gyp/issues/132

@sorccu @jonalmeida
thank you
i got
the problem is a permissions issue with node,
to use "sudo npm install --unsafe-perm --verbose -g stf " instand of "sudo npm install -g stf" ,the problem is solve

npm install --save bcrypt
|

[email protected] install /home/tronwares/Escritorio/Oglit/Provedores-App/node_modules/bcrypt
node-gyp rebuild

gyp ERR! build error
gyp ERR! stack Error: not found: make
gyp ERR! stack at F (/usr/lib/node_modules/npm/node_modules/which/which.js:72:28)
gyp ERR! stack at E (/usr/lib/node_modules/npm/node_modules/which/which.js:75:29)
gyp ERR! stack at /usr/lib/node_modules/npm/node_modules/which/which.js:83:16
gyp ERR! stack at FSReqWrap.oncomplete (fs.js:95:15)
gyp ERR! System Linux 3.16.0-4-amd64
gyp ERR! command "node" "/usr/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /home/tronwares/Escritorio/Oglit/Provedores-App/node_modules/bcrypt
gyp ERR! node -v v0.12.7
gyp ERR! node-gyp -v v2.0.1
gyp ERR! not ok
npm ERR! Linux 3.16.0-4-amd64
npm ERR! argv "/usr/bin/node" "/usr/bin/npm" "install" "--save" "bcrypt"
npm ERR! node v0.12.7
npm ERR! npm v2.11.3
npm ERR! code ELIFECYCLE

npm ERR! [email protected] install: node-gyp rebuild
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] install script 'node-gyp rebuild'.
npm ERR! This is most likely a problem with the bcrypt package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! node-gyp rebuild
npm ERR! You can get their info via:
npm ERR! npm owner ls bcrypt
npm ERR! There is likely additional logging output above.

npm ERR! Please include the following file with any support request:
npm ERR! /home/tronwares/Escritorio/Oglit/Provedores-App/npm-debug.log

It's a bit late, but you can get around that problem by using nvm. Although I'm pretty sure you shouldn't need sudo with homebrew's node either... anyway it's an old issue now, but if it happens again, try running brew doctor to see if it can find something wrong with your installation. Note that you're practically NEVER supposed to use sudo with homebrew.

Was this page helpful?
0 / 5 - 0 ratings