Windows 8 : `node-gyp rebuild` Exit status 1 installing contextify as dependency of zombie

心已入冬 提交于 2019-12-05 18:55:53

If someone else is coming up on this: We tracked it down (debugging by hand..) to some node binding script that executes node.exe while creating the build script for msbuild.

the binding.gyp from contextify contains: 'include_dirs': ["<!(node -e \"require('nan')\")"],

Which produces the: Das System kann den angegebenen Pfad nicht finden (The System Cannot Find the Path Specified)
Even with this knowledge that somehow python cannot call the node.exe and find the require("nan") module we gave up on this. If anywone has more insights that we do, please share. I have sleepless nights because of this ;)

I had similar issue or I'd even say exactly the same! Finally (while running node-gyp rebuild / npm install) I've noticed a message an error msg stating "MSBUILD : error MSB4132: The tools version "2.0" is unrecognized. Available too ls versions are "4.0"."

Google gave me this as an answer = https://github.com/chjj/pty.js/issues/60 "Install a visual studio express 2013(desktop with c++ redist), this will help"

You can download it here: http://www.microsoft.com/en-gb/download/details.aspx?id=40787

cmd as admin -> npm install -> everything works just fine!:D

Hope that helps!

Cheers Greg

download visual studio express 2013 here: http://www.microsoft.com/en-us/download/details.aspx?id=43729

I was having the same problem and tried a number of solutions posted on here (installing various Microsoft VS distributions from different years), to no avail. I eventually got it working though. It's possible that a combination of them got them working for me other than these steps, but here's what I think was the solution:

  • Install Python 2.7. The easiest way to do this is to use Chocolatey, so all you have to do is type choco install python2
  • Install Visual Studio Express 2013 for Windows Desktop. Again with Chocolatey, you'd just type choco install visualstudioexpress2013windowsdesktop which will ensure you download the right one.

After installing these, update the environment variable for Python. Chocolatey will install it in C:\tools\python2. Finally, don't forget to close and reopen your command prompt.

I recommend going for a machine that has *nix. Use someone's in your office if you don't have one. I don't remember how I did I resolve when I had this error while building strongloop and the kinds. However, most of the red messages being shown on consoles were warnings, not all were errors !! Ignore and only take errors to fix.

Working with MS dependencies + python + X-bit architecture + node-gyp rebuild permutations & combinations will reduce confidence levels more than they pay.

This is an old question, but may this info help someone.

If you prefer only to install microsoft visual C++ 2013 dist, you can download the package provided by Microsoft at this link: MS Visual C++ 2013 dist

Best regards!

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!