node-gyp icon indicating copy to clipboard operation
node-gyp copied to clipboard

installing node-gyp on windows

Open mateoKaradza opened this issue 10 years ago • 5 comments

I see everyone is having issues with installing this package on windows. I experienced it myself, I tried many solution that were available online and none of them worked.

If you are on Windows 10, there is no need for you to install Microsoft's build tools. All you have to do is to install the package using 'Bash on Ubuntu on Windows' - the installation is flawless and fast.

Is this method worth making a pull request?

mateoKaradza avatar Aug 29 '16 07:08 mateoKaradza

I believe your suggestion is to use the Linux subsystem? That's not really a solution for people that need to interface with Windows natively.

bnoordhuis avatar Aug 29 '16 08:08 bnoordhuis

This helps unless you are on Windows 7: https://github.com/nodejs/node-gyp/wiki/Updating-npm's-bundled-node-gyp

What to do if one is on windows 7? No idea.

Skwarski avatar Jan 19 '17 08:01 Skwarski

I am using python 3.5 as default. but node-gyp require python 2.* only, Any idea?

tsogtbayar0821 avatar Apr 29 '17 03:04 tsogtbayar0821

Removing the dependency on python 2.* is a work in progress #193 For now you'll need to install python2.* as stated in the README If node-gyp still can't find python2 you can set an environment variable npm_config_python before you run npm i:

> set npm_config_python=[path to your python2 binary]
> npm i

refack avatar Apr 29 '17 03:04 refack

Thanks @refack 👍 It works well for me.

tsogtbayar0821 avatar Apr 29 '17 03:04 tsogtbayar0821