hokaccha / nodebrew

Node.js version manager
MIT License
1.06k stars 66 forks source link

node-gyp's path #18

Closed Jxck closed 11 years ago

Jxck commented 12 years ago

when installing node, npm installs node-gyp in global at installing process and add to path.

nodebrew has node-gyp at here

.nodebrew/node/v0.8.3/lib/node_modules/npm/bin/node-gyp-bin

but, path doesn't add.

so

$which node-gyp
node-gyp not found
hokaccha commented 12 years ago

Is this nodebrew's issue? I don't think so.

It should install by npm install -g node-gyp.

Jxck commented 12 years ago

It should install by npm install -g node-gyp.

in installing process, node does that in automatically. and node-gyp are fetched in local already. why we need to install twice?

hokaccha commented 12 years ago

why we need to install twice?

Because it is npm specific. npm installs dependence module in each directory.

You saying node-gyp is npm private dependencies.

https://github.com/isaacs/npm/blob/master/package.json#L56

These are the same problems.

hokaccha commented 11 years ago

I tried this.

$ wget http://nodejs.org/dist/v0.8.3/node-v0.8.3.tar.gz
$ tar zfx node-v0.8.3.tar.gz
$ ./configure --prefix=/path/to/dir
$ make && make install
$ ls /path/to/dir/bin
$ ls
./        ../       node*     node-waf* npm@

If node-gyp is installed automatically, it should exist in bin directory. but not exists.

And binary file was also the same.

$ wget http://nodejs.org/dist/v0.8.16/node-v0.8.16-darwin-x64.tar.gz
$ tar zfx node-v0.8.16-darwin-x64.tar.gz
$ ls node-v0.8.16-darwin-x64/bin 
./        ../       node*     node-waf* npm@