Node-gyp refuses to build any native modules I've tried. I'm on Windows 7 64 bit (I'm trying to compile for x86 though, as I don't have the x64 SDK installed). Node-gyp says it's a bug which I need to report, so here I am:
E:\project\node-ffi>node-gyp configure
gyp info it worked if it ends with ok
gyp info using [email protected]
gyp info using [email protected] | win32 | ia32
gyp ERR! UNCAUGHT EXCEPTION
gyp ERR! stack Error: spawn ENOENT
gyp ERR! stack at errnoException (child_process.js:980:11)
gyp ERR! stack at Process.ChildProcess._handle.onexit (child_process.js:771:
34)
gyp ERR! System Windows_NT 6.1.7601
gyp ERR! command "node" "C:\\Users\\Gebruiker\\AppData\\Roaming\\npm\\node_modul
es\\node-gyp\\bin\\node-gyp.js" "configure"
gyp ERR! cwd E:\project\node-ffi
gyp ERR! node -v v0.10.12
gyp ERR! node-gyp -v v0.10.2
gyp ERR! This is a bug in `node-gyp`.
gyp ERR! Please file an Issue:
gyp ERR! <https://github.com/TooTallNate/node-gyp/issues>
Similar problem here, but Windows 8 and VS2012 installed. (sqlite3, ejdb, or any node-gyp library)
gyp info it worked if it ends with ok
gyp info using [email protected]
gyp info using [email protected] | win32 | x64
gyp ERR! configure error
gyp ERR! stack Error: spawn ENOENT
gyp ERR! stack at errnoException (child_process.js:980:11)
gyp ERR! stack at Process.ChildProcess._handle.onexit (child_process.js:771:34)
gyp ERR! System Windows_NT 6.2.9200
gyp ERR! command "node" "C:\\Users\\jhaber\\AppData\\Roaming\\npm\\node_modules\\node-gyp\\bin\\node-gyp.js" "configure"
gyp ERR! cwd c:\Users\jhaber\AppData\Roaming\npm-cache\sqlite3\2.1.10\package
gyp ERR! node -v v0.10.12
gyp ERR! node-gyp -v v0.10.4
gyp ERR! not ok
I too have the same error,please some one provide solution
Hi!
start the build with nodejs 0.8 - this will provide much more information about the error..
In my machine (I installed python manually later and I set PYTHON environment variable and python binary to the path) I removed the PYTHON variable from environment properties (set PYTHON=) and it's work correctly.
i also have windows 7 64 bits, when i try to install pg module, i have the same error
Spawn ENOENT
error at errnoException (child_process.js:980:11)
error at Process.ChildProcess._handle.onexit (child_process.js:771:34)
System Windows_NT 6.1..7600
node -v v0.10.12
npm -v 1.2.32
aditional ----
node-gyp -v 0.10.5
Python 2.7.5 (64-bit)
Microsoft Visual Studio C++ 2010 (64-bit)
Windows 7 64-bit SDK
Microsoft Visual Studio C++ 2012 for Windows Desktop
scunish, start with nodejs 0.8 and you see the problem...
hi b0c1 thank you for your response, what do you mean by start with node 0.8 im sorry i didnt undestood well,
do you mean install node version 0.8? and run from there?
i downgraded the version of node now the error is different,
1716 error [email protected] install: node-gyp rebuild
1716 error cmd "/c" "node-gyp rebuild" failed with 127
1717 error Failed at the [email protected] install script.
1717 error This is most likely a problem with the ref package,
1717 error not with npm itself.
1717 error Tell the author that this fails on your system:
1717 error node-gyp rebuild
1717 error You can get their info via:
1717 error npm owner ls ref
1717 error There is likely additional logging output above.
1718 error System Windows_NT 6.1.7600
1719 error command "C:\Program Filesnodejs\node.exe" "C:\Program Filesnodejsnode_modules\npmbin\npm-cli.js" "install" "pg"
1720 error cwd C:\Users\Desarrollo\Documents\Node Code
1721 error node -v v0.8.22
1722 error npm -v 1.2.14
1723 error code ELIFECYCLE
1724 verbose exit [ 1, true ]
Nope. I mean install nodejs 0.8 :) You using: "node -v v0.10.12" :)
What I do:
hi b0c1 thank you once more, my last comment was by using version 0.8.22 and threw that error, i switched to v 0.8.25 as u suggested and the new error is.
npm ERR! werid error 127
npm http 304 https://registry.npmjs.org/rmdir
npm ERR! not ok code 0
funny to read weird error
Ehh, funny, but maybe you can create an issue with the new data
thank you b0c1 good luck.
I was getting the same problem. Solved defining the env variables:
PYTHONPATH=C:\Pyhon
PYTHON=%PYTHONPATH%\python.exe
Worked like charm
I tried setting the Python path, but that didn't work.
Downgrading to Node v0.8.25 worked!
The command node-gyp configure succeeded.
However node-gyp build failed. I was still able to compile the project manually by opening the solution in Visual Studio, though.
I have the same preoblem,I use node for v0.10.12,and use Visual Studio2012,the command node-gyp configure has the above problem,but i can compile the manually by opening the solution in Visual Studio too.
having the same issue. node 0.10.15 npm 1.3.5
Guys, to solve that issue I did not change the version of node, I just changed the version of python to this one: Python 2.7.5 Windows X86-64 Installer
Here is the page to download it: http://www.python.org/getit/
Ok, from reading your discussion and my own expirements I can conduct the following solution:
works like a charm :D
Thanks,this problem has been resolved.In fact,that moment I had set the environment PYTHON,but make a howler.
Thanks so much.
------------------ 原始邮件 ------------------
发件人: "Rialgar";[email protected];
发送时间: 2013年10月9日(星期三) 上午10:54
收件人: "TooTallNate/node-gyp"[email protected];
抄送: "肖永"[email protected];
主题: Re: [node-gyp] Error: spawn ENOENT (#277)
Ok, from reading your discussion and my own expirements I can conduct the following solution:
Make Sure Your Python and node are both x86 (32Bit) or both x86-x64 (64Bit), a mix will throw this error
set the environment variable PYTHON to your python.exe, in my case I ran "set PYTHON=E:\Python27\python.exe" bevore running npm
works like a charm :D
—
Reply to this email directly or view it on GitHub.
I've solved this problem a moment ago.
I have struggled with this problem for 2 weeks. hum..
in windows 8
Thank you all.
Hey guys,
I wrote this gist after struggling with this all day yesterday and figured it might help someone.
https://gist.github.com/nullivex/7115612
I was able to get Canvas built a well as bson, bcrypt etc. I also wrapped together a lot of the information I found spread out beetween many docs.
Maybe this could be merged into the documenation for git.
Cheers hope this helps someone.
This started as an issue with Python being installed and on the path. Well known issue, though could use better error message when it occurs.
Closing this and tracking as https://github.com/TooTallNate/node-gyp/issues/365.
I would be careful by stating that this error occurs "only" with phyton not installed and not on the path. It cost me a couple of hours to discover (on W8.1, x64) that you need Python on your path as well as a separate ENV variable PYTHON=C:\Python\phyton.exe (or anything that matches the full path to your Python installation). However, with the latest versions of node and gyp as per now but when using an older (recommended?) version, namely 2.7.x of Python you may end up having to change the configure.js script:
See the discussion over here: https://github.com/TooTallNate/node-gyp/issues/166 ...
Because the configure script does find Python but with the lines above the configure script cannot determine the version and hence you'll end up with the infamous "Error: spawn ENOENT".
No matter what combination of Python/Node I try I still can not get 'requestify' to install on my Windows machine.
This issue is closed, but I don't see what the solution was?... The problem definately still exists.
This problem was coming up for me on our TeamCity box (Windows 2012 x64); I couldn't get it to build any native extensions. Here's the list of things I did to resolve the problem that I pieced together from several different threads:
Example TeamCity Command Line Task:
cd %teamcity.build.workingDir%
npm --msvs_version=2012 install
HTH
The below worked for me.
PYTHONPATH=C:\Pyhon
PYTHON=%PYTHONPATH%\python.exe
I also had to add the python in path variable just like path = %PYTHON%
Also, the python version supported is between 2.5 and 3 only.
For me, this was solved by installing Python 2.7.10 (previously had Python 3.5.2 which was referenced by path as py and python).
I'm running Windows 10, Node v5.0.0
For me this was solved by setting :
npm config set python C:\Python27python.exe
@JsDevHub Can you please also explain how to do that then?
In my case I was able to run the Gulp task in the Angular CLI, but was getting this issue in Visual Studio 2017. My solution was to change the order of my paths in Visual Studio.
Tools > Options > Projects and Solutions > Web Package Management > External Web Tools
once there, re-order your paths such that $(PATH) is in the list right after your node modules as such:
Hope that helps someone.
Most helpful comment
For me this was solved by setting :
npm config set python C:\Python27python.exe